################################################################
Notes:

1. Use the compatibility query tool http://support.huawei.com/onlinetoolweb/ftca/en to obtain the compatibility between the server and OS compatibility & components and OS, 
   and then use the driver mapping table to query the mapping relationship.
   
2. If the source code driver installation involves compilation dependency and package dependencies, set up the compilation environment to install the dependencies and then install the driver, such as gcc, make, tcl, and tk.
   Reference documentation: https://forum.huawei.com/enterprise/en/installing-the-software-compilation-environment-via-yum-yast2/thread/411263-895#pid2335931
   
3. Huawei self-developed MLNX board cards upgrade the MLNX driver will not upgrade the FW synchronously,FW needs to be upgraded separately.

4. The MLNX driver needs to be installed after the dependent packages are installed. The list of dependent packages is as follows:

	1). RHEL/OEL/CentOS: yum install perl pciutils python gcc-gfortran libxml2-python tcsh libnl.i686 libnl expat glib2 tcl libstdc++ bc tk gtk2 atk cairo numactl pkgconfig ethtool lsof
	
	2). SLES12: zypper install pkg-config expat libstdc++6 libglib-2_0-0 lib- gtk-2_0-0 tcl libcairo2 tcsh python bc pciutils libatk-1_0-0 tk python-libxml2 lsof libnl3-200 ethtool lsof
	
	3). SLES15: 
		
		python ethtool libatk-1_0-0 python2-libxml2-python tcsh lib- stdc++6-devel-gcc7 libgtk-2_0-0 tcl libopenssl1_1 libnl3-200 make libcairo2 expat libmnl0 insservcompat pciutils lsof \
		lib- glib-2_0-0 pkg-config tk
	
	4). Ubuntu/Debian: 
	
		apt-get install perl dpkg autotools-dev autoconf libtool auto- make1.10 automake m4 dkms debhelper tcl tcl8.4 chrpath swig graphviz tcl-dev tcl8.4-dev tk-dev tk8.4-dev bison flex \
		dpatch zlib1g-dev curl libcurl4-gnutls-dev python-libxml2 libvirt-bin libvirt0 libnl-dev libglib2.0-dev libgfortran3 automake m4 pkg-config libnuma logrotate ethtool lsof

    5).CentOS 7.6:yum install perl pciutils python gcc-gfortran libxml2-python tcsh libnl.i686 libnl expat glib2 tcl libstdc++ bc tk gtk2 atk cairo numactl pkgconfig ethtool lsof python-devel redhat-rpm-config rpm-build gcc kernel-devel-4.14.0-115.el7a.0.1.aarch64 libtool

4. RAID、MLNX board cards driver need restarting OS to take effect, rmmod and modprobe driver operation will affect the server's task. 
If there is a task running on current machine, please stop the task and make sure machine is separated from server cluster.

5. Please use the user with administrator rights for driver maintenance.

################################################################

1. Load the ISO or img driver file during OS installation.

1.1 image file Loading method :
    *.iso --- using the Virtual CD/DVD
    *.img --- using the Virtual Floppy

1.2 Application Description
	1) The RAID driver needs to be loaded when the OS is installed on the hard disk of the RAID controller card.
	2) SAN Boot Start the OS to load the FC card driver.
	
1.3 Guide to Loading Image Files
	For details, see the operating system installation guide.
	https://forum.huawei.com/enterprise/en/huawei-server-os-installation-guides-summary/thread/407583-895
	
RAID-B80121-openEuler22.03-hiraid-1.0.1.2-aarch64.iso
---1880 B80121 driver

################################################################

2. After the OS is installed, install the driver file in onboard_driver_XXX.iso.

2.1 Use the driver installation script to automatically install the driver.

	driver.cfg
	---Configuration file for automatically installing the driver
	install.bat
	---Script for automatically installing the driver.
	
	Perform the following steps to install the driver automatically:   		
	1)Use the virtual DVD-ROM drive of the BMC to mount the onboard_driver_xxx.iso:
	2)mount /dev/sr0 /mnt       // Mount the CD-ROM drive to the destination file
    3)mkdir /root/driver/	    // Create a new "driver" directory under /root
	4)cp -vr  /mnt/*  /root/driver/		//Copy all files to the directory of your choice(create a new "driver" directory under /root)
	5)cd /root/driver
	6)chmod +x install.sh
	7)./install.sh		
	//Execute the automatic script. The description is as follows: 
	1) Enter 2 to query and enter 1 to install.
	2) After the driver is installed, determine whether to restart the OS for the new driver to take effect based on the automatic installation of the notes information.
	   //Please execute the reboot command on the OS. Do not force the OS to restart and force power off by iBMC.

	Note:
	1. The MLNX card with the name starting with SP, SM, or MZ is not automatically upgraded when the driver is upgraded.
	2. The MLNX PCIe card with the name starting with "MCX" will automatically upgrade the firmware of the driver when the driver is upgraded.
	3. When the MCX4121A-ACAT_C12 card is used to upgrade the driver, the matching firmware is not automatically upgraded.
	
	result.txt
	---Automatic installation result record file
	Note: FileName is the driver name, which is used as an example. Replace it with the actual driver package.
	1) "File":"FileName","Result":"success","ErrorInfo":"NA"
		---The driver is successfully installed.
	2) "File":"FileName","Result":"fail","ErrorInfo":"fail_log"
		---Failed to install the driver. fail_log is an error message.
	3) "File":"FileName","Result":"success","ErrorInfo":"The driver version has been updated to the target version and there is no need to upgrade the driver."
		---The current driver version is the same as the target version. You do not need to install the driver.
	4) "File":"FileName","Result":"success","ErrorInfo":"unknown file."
		---Driver files that are not supported by automation
	5) "File":"FileName","Result":"success","ErrorInfo":"can not find the installation of driver FileName."
		---Automatic support, but the FileName name file does not exist.

2.2 onboard_driver_xxx.iso driver file list and manual driver installation guide:

RAID-B80121-openEuler22.03-hiraid-1.0.1.2-aarch64.rpm
---1880 B80121 driver
#Note: Please replace the xxx.rpm with the archived package name for the actual driver installation.
#Upgrade installation:
1. rpm -Uvh xxx.rpm
2. Execute reboot under OS
#Downgrade Installation:
1. rpm -Uvh xxx.rpm --oldpackage
2. Execute reboot under OS
