71 lines · plain
1Kernel driver mlxreg-fan2========================3 4Provides FAN control for the next Mellanox systems:5 6- QMB700, equipped with 40x200GbE InfiniBand ports;7- MSN3700, equipped with 32x200GbE or 16x400GbE Ethernet ports;8- MSN3410, equipped with 6x400GbE plus 48x50GbE Ethernet ports;9- MSN3800, equipped with 64x1000GbE Ethernet ports;10 11Author: Vadim Pasternak <vadimp@mellanox.com>12 13These are the Top of the Rack systems, equipped with Mellanox switch14board with Mellanox Quantum or Spectrume-2 devices.15FAN controller is implemented by the programmable device logic.16 17The default registers offsets set within the programmable device is as18following:19 20======================= ====21pwm1 0xe322fan1 (tacho1) 0xe423fan2 (tacho2) 0xe524fan3 (tacho3) 0xe625fan4 (tacho4) 0xe726fan5 (tacho5) 0xe827fan6 (tacho6) 0xe928fan7 (tacho7) 0xea29fan8 (tacho8) 0xeb30fan9 (tacho9) 0xec31fan10 (tacho10) 0xed32fan11 (tacho11) 0xee33fan12 (tacho12) 0xef34======================= ====35 36This setup can be re-programmed with other registers.37 38Description39-----------40 41The driver implements a simple interface for driving a fan connected to42a PWM output and tachometer inputs.43This driver obtains PWM and tachometers registers location according to44the system configuration and creates FAN/PWM hwmon objects and a cooling45device. PWM and tachometers are sensed through the on-board programmable46device, which exports its register map. This device could be attached to47any bus type, for which register mapping is supported.48Single instance is created with one PWM control, up to 12 tachometers and49one cooling device. It could be as many instances as programmable device50supports.51The driver exposes the fan to the user space through the hwmon's and52thermal's sysfs interfaces.53 54/sys files in hwmon subsystem55-----------------------------56 57================= == ===================================================58fan[1-12]_fault RO files for tachometers TACH1-TACH12 fault indication59fan[1-12]_input RO files for tachometers TACH1-TACH12 input (in RPM)60pwm1 RW file for fan[1-12] target duty cycle (0..255)61================= == ===================================================62 63/sys files in thermal subsystem64-------------------------------65 66================= == ====================================================67cur_state RW file for current cooling state of the cooling device68 (0..max_state)69max_state RO file for maximum cooling state of the cooling device70================= == ====================================================71