Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  1) Kernel driver gl518sm
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  2) =====================
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  3) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  4) Supported chips:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  5) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  6)   * Genesys Logic GL518SM release 0x00
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  7) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  8)     Prefix: 'gl518sm'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  9) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10)     Addresses scanned: I2C 0x2c and 0x2d
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12)   * Genesys Logic GL518SM release 0x80
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14)     Prefix: 'gl518sm'
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16)     Addresses scanned: I2C 0x2c and 0x2d
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18)     Datasheet: http://www.genesyslogic.com/
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) Authors:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21)        - Frodo Looijaard <frodol@dds.nl>,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22)        - Kyösti Mälkki <kmalkki@cc.hut.fi>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23)        - Hong-Gunn Chew <hglinux@gunnet.org>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24)        - Jean Delvare <jdelvare@suse.de>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) Description
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) -----------
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) .. important::
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31)    For the revision 0x00 chip, the in0, in1, and in2  values (+5V, +3V,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32)    and +12V) CANNOT be read. This is a limitation of the chip, not the driver.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) This driver supports the Genesys Logic GL518SM chip. There are at least
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) two revision of this chip, which we call revision 0x00 and 0x80. Revision
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) 0x80 chips support the reading of all voltages and revision 0x00 only
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) for VIN3.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) The GL518SM implements one temperature sensor, two fan rotation speed
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) sensors, and four voltage sensors. It can report alarms through the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) computer speakers.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) Temperatures are measured in degrees Celsius. An alarm goes off while the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) temperature is above the over temperature limit, and has not yet dropped
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45) below the hysteresis limit. The alarm always reflects the current
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46) situation. Measurements are guaranteed between -10 degrees and +110
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) degrees, with a accuracy of +/-3 degrees.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 49) Rotation speeds are reported in RPM (rotations per minute). An alarm is
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 50) triggered if the rotation speed has dropped below a programmable limit. In
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 51) case when you have selected to turn fan1 off, no fan1 alarm is triggered.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 52) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 53) Fan readings can be divided by a programmable divider (1, 2, 4 or 8) to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 54) give the readings more range or accuracy.  Not all RPM values can
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 55) accurately be represented, so some rounding is done. With a divider
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 56) of 2, the lowest representable value is around 1900 RPM.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 57) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 58) Voltage sensors (also known as VIN sensors) report their values in volts.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 59) An alarm is triggered if the voltage has crossed a programmable minimum or
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 60) maximum limit. Note that minimum in this case always means 'closest to
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 61) zero'; this is important for negative voltage measurements. The VDD input
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 62) measures voltages between 0.000 and 5.865 volt, with a resolution of 0.023
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 63) volt. The other inputs measure voltages between 0.000 and 4.845 volt, with
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 64) a resolution of 0.019 volt. Note that revision 0x00 chips do not support
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 65) reading the current voltage of any input except for VIN3; limit setting and
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 66) alarms work fine, though.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 67) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 68) When an alarm is triggered, you can be warned by a beeping signal through your
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 69) computer speaker. It is possible to enable all beeping globally, or only the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 70) beeping for some alarms.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 71) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 72) If an alarm triggers, it will remain triggered until the hardware register
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 73) is read at least once (except for temperature alarms). This means that the
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 74) cause for the alarm may already have disappeared! Note that in the current
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 75) implementation, all hardware registers are read whenever any data is read
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 76) (unless it is less than 1.5 seconds since the last update). This means that
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 77) you can easily miss once-only alarms.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 78) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 79) The GL518SM only updates its values each 1.5 seconds; reading it more often
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 80) will do no harm, but will return 'old' values.