0e7ce3752e
In order to select between the in-tree and OOT drivers for the single driver, a cmdline parameter out-of-tree-drivers need be used. The cmdline parameter out-of-tree-drivers will be set driver names that these drivers will be used as the out of tree drivers. For example "out-of-tree-drivers=ice,i40e,iavf", the OOT drivers ice, i40e, iavf will be loaded by "insmod" command before udevd is started, and that ensures that the OOT drivers will be loaded rather than the in-tree drivers. The default drivers will be the in-tree drivers if there is not out-of-tree-drivers in the cmdline parameters or they are not set correct. 1. Switch the single driver as the following step. a) ice * switch the ice driver to the OOT version out-of-tree-drivers=ice * switch the ice driver to the in-tree version remove ice from out-of-tree-drivers or set any value except ice b) i40e * switch the i40e driver to the OOT version out-of-tree-drivers=i40e * switch the i40e driver to the in-tree version remove i40e from out-of-tree-drivers or set any value except i40e c) iavf * switch the iavf driver to the OOT version out-of-tree-drivers=iavf * switch the iavf driver to the in-tree version remove iavf from out-of-tree-drivers or set any value except iavf 2. Switch the bundle driver as the following step. * switch the bundle drivers to the OOT version. out-of-tree-drivers=ice,iavf,i40e * switch the bundle drivers to the in-tree version out-of-tree-drivers= or remove out-of-tree-drivers from the boot commandline. or out-of-tree-drivers=aaa,bb,xx(any value except ice,i40e,iavf) 3. Switch any two ones. * switch ice and iavf to the OOT version. out-of-tree-drivers=ice,iavf * switch i40e and iavf to the OOT version. out-of-tree-drivers=i40e,iavf * switch to the in-tree version. just remove driver name from out-of-tree-drivers or set any value except ice, iavf and i40e. Verification: Switch drivers between the OOT and in-tree drivers. - switch to the OOT drivers 1. Add cmdline parameter out-of-tree-drivers=ice,iavf,i40e 2. reboot can switch to the OOT drivers for ice, iavf and i40e. - switch to the in-tree drivers 1. Remove cmdline parameter out-of-tree-drivers 2. reboot can switch to the in-tree drivers for ice, iavf and i40e. - switch to the OOT ice driver(for iavf and i40e is same with ice) 1. Add cmdline parameter out-of-tree-drivers=ice 2. reboot can switch to the OOT driver for ice - switch to the OOT drivers for ice and iavf (for the combination of the other two drivers are same with this one. ) 1. Add cmdline parameter out-of-tree-drivers=ice,iavf 2. reboot can switch to the OOT drivers for ice, iavf. - Set the cmdline parameter out-of-tree-drivers=ice,iavf,aaa It can switch to the OOT driver for ice and iavf. Story: 2011056 Task: 50002 Change-Id: I927b0754d132796141caa2036bf626da527068ee Signed-off-by: Jiping Ma <jiping.ma2@windriver.com> (cherry picked from commit 8a0d36a154a9e41286ed61b3da4cb4c4f6f9b225)