Why I did it
Old fan drv will be build fail under kernel 5.10. It get below error message.
/sonic/platform/broadcom/sonic-platform-modules-accton/as7312-54xs/modules/accton_as7312_54x_fan.c:483:5: error: implicit declarat ion of function 'set_fs'; did you mean 'sget_fc'? [-Werror=implicit-function-declaration]
set_fs(KERNEL_DS);
^~~~~~
sget_fc
How I did it
These code is old design and they are not needed currently. So remove them.
Signed-off-by: Jostar Yang <jostar_yang@accton.com>
Accton util applies lsmod to check if drivers are installed.
But lsmod may return error on startup and skip module installation.
Signed-off-by: Brandon Chuang <brandon_chuang@edge-core.com>
Fix 259 alerts reported by the LGTM tool:
- 245 for Unused import
- 7 for Testing equality to None
- 5 for Duplicate key in dict literal
- 1 for Module is imported more than once
- 1 for Unused local variable
1. undefine led_classdev_register as it is defined in leds.h
2. header file location change
a. linux/i2c/pmbus.h -> linux/pmbus.h
b. linux/i2c-mux-gpio.h -> linux/platform_data/i2c-mux-gpio.h
c. linux/i2c/pca954x.h -> linux/platform_data/pca954x.h
* Add driver and util for peripherals of as7312-54xs, most are copied from as7312-54s.
Signed-off-by: roy_lee <roy_lee@accton.com>
* Add default port speed and index from 1.
Signed-off-by: roy_lee <roy_lee@accton.com>
* Update i2c addr of psus.
Add system logging for monitor.
Signed-off-by: roy_lee <roy_lee@accton.com>
* Correct syntax of module_dirs.
Signed-off-by: roy_lee <roy_lee@accton.com>
* Validate sfputil after tested.
Signed-off-by: roy_lee <roy_lee@accton.com>
* Correct the index of eeprom mapping.
Signed-off-by: roy_lee <roy_lee@accton.com>