- 17 10月, 2008 40 次提交
-
-
由 Darrick J. Wong 提交于
Signed-off-by: NDarrick J. Wong <djwong@us.ibm.com> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Wolfgang Grandegger 提交于
This patch modifies the w83781d driver to use new style driver binding. Substantial code modifications are required to deal with the new interface, especially legacy device detection. [JD: largely edited to make the patch smaller and to get the driver to work again on ISA devices.] Signed-off-by: NWolfgang Grandegger <wg@grandegger.com> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Jean Delvare 提交于
Upcoming changes to the I2C part of the w83781d driver will cause ISA devices to no longer have a struct i2c_client at hand. So, we must stop (ab)using it now. Signed-off-by: NJean Delvare <khali@linux-fr.org> Cc: Wolfgang Grandegger <wg@grandegger.com>
-
由 Wolfgang Grandegger 提交于
Probing the ISA bus on systems without ISA bus may hang the system. This patch makes the ISA bus related code depend on the kernel configuration parameter CONFIG_ISA. It moves ISA bus related code into one #ifdef CONFIG_ISA ... #endif block and adds some helper function. Signed-off-by: NWolfgang Grandegger <wg@grandegger.com> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Jean Delvare 提交于
The W83781D and W83782D can be accessed either on the I2C bus or the ISA bus. We must not access the same chip through both interfaces. So far we were relying on the user passing the correct ignore parameter to skip the registration of the I2C interface as suggested by sensors-detect, but this is fragile: the user may load the w83781d driver without running sensors-detect, and the i2c bus numbers are not stable across reboots and hardware changes. So, better detect alias chips in the driver directly, and skip any I2C chip which is obviously an alias of the ISA chip. This is done by comparing the value of 26 selected registers. Signed-off-by: NJean Delvare <khali@linux-fr.org> Cc: Wolfgang Grandegger <wg@grandegger.com>
-
由 Jean Delvare 提交于
We can handle the beep enable bit as any other beep mask bit for slightly smaller code. Signed-off-by: NJean Delvare <khali@linux-fr.org> Cc: Wolfgang Grandegger <wg@grandegger.com>
-
由 Marc Hulsman 提交于
Add support to set target temperature and tolerance for thermal cruise mode. Signed-off-by: NMarc Hulsman <m.hulsman@tudelft.nl> Acked-by: NHans de Goede <j.w.r.degoede@hhs.nl> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Marc Hulsman 提交于
Add support for pwm_enable. Signed-off-by: NMarc Hulsman <m.hulsman@tudelft.nl> Acked-by: NHans de Goede <j.w.r.degoede@hhs.nl> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Marc Hulsman 提交于
Add PWM manual control. Signed-off-by: NMarc Hulsman <m.hulsman@tudelft.nl> Acked-by: NHans de Goede <j.w.r.degoede@hhs.nl> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Marc Hulsman 提交于
Pins fan/pwm 4-5 can be in use as GPIO. If that is the case, do not create their sysfs-interface. Signed-off-by: NMarc Hulsman <m.hulsman@tudelft.nl> Acked-by: NHans de Goede <j.w.r.degoede@hhs.nl> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Andrew Morton 提交于
Macros evaluating their arguments more than once are evil. Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Jean Delvare 提交于
The it87 driver doesn't follow the standard sensor type values as documented in Documentation/hwmon/sysfs-interface. It uses value 2 for thermistors instead of value 4. This causes "sensors" to tell the user that the chip is setup for a transistor while it is actually setup for a thermistor. Using value 4 for thermistors solves the problem. For compatibility reasons, we still accept value 2 but emit a warning message so that users update their configuration files. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NHans de Goede <hdegoede@redhat.com>
-
由 Jean Delvare 提交于
The new-style lm78 driver implements the optional detect() callback to cover the use cases of the legacy driver. Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Jean Delvare 提交于
Upcoming changes to the I2C part of the lm78 driver will cause ISA devices to no longer have a struct i2c_client at hand. So, we must stop (ab)using it now. Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Jean Delvare 提交于
The LM78 detection is relatively weak, and sometimes recent Winbond chips can be misdetected as an LM78. We have had repeated reports of this happening. We have an explicit check against this for the ISA access, do the same for I2C access now. Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Jean Delvare 提交于
The LM78 and LM79 can be accessed either on the I2C bus or the ISA bus. We must not access the same chip through both interfaces. So far we were relying on the user passing the correct ignore parameter to skip the registration of the I2C interface as suggested by sensors-detect, but this is fragile: the user may load the lm78 driver without running sensors-detect, and the i2c bus numbers are not stable across reboots and hardware changes. So, better detect alias chips in the driver directly, and skip any I2C chip which is obviously an alias of the ISA chip. This is done by comparing the value of 26 selected registers. Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Jean Delvare 提交于
Only request I/O ports 0x295-0x296 instead of the full I/O address range. This solves a conflict with PNP resources on a few motherboards. Also request the I/O ports in two parts (4 low ports, 4 high ports) during device detection, otherwise the PNP resource make the request (and thus the detection) fail. This is the exact same fix that was applied to driver w83781d in March 2008 to address the same problem: http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=2961cb22ef02850d90e7a12c28a14d74e327df8dSigned-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Jean Delvare 提交于
Label names ERROR1 and ERROR3 aren't exactly explicit. Change them for better names that indicate what we are up to. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NHerbert Poetzl <herbert@13thfloor.at>
-
由 Jean Delvare 提交于
Function RANGE_TO_REG can easily be simplified. Credits go to Herbert Poetzl for indirectly suggesting this to me. I tested that the new implementation returns the same result as the original implementation for all input values. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NHerbert Poetzl <herbert@13thfloor.at>
-
由 Jean Delvare 提交于
The new-style lm85 driver implements the optional detect() callback to cover the use cases of the legacy driver. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NHerbert Poetzl <herbert@13thfloor.at>
-
由 Jean Delvare 提交于
The Analog Devices and SMSC devices supported by the lm85 driver do not have the same PWM frequency table as the National Semiconductor devices. Add support for per-device frequency tables. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NHerbert Poetzl <herbert@13thfloor.at>
-
由 Jean Delvare 提交于
The LM85 and compatible chips only support 8 arbitrary PWM frequencies. The algorithm to pick one of them based on the user input is not optimum. Improve it to always pick the closest supported frequency. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NHerbert Poetzl <herbert@13thfloor.at>
-
由 Jean Delvare 提交于
Implement the standard PWM frequency interface: pwm[1-*]_freq in units of 1 Hz, instead of the non-standard pwm[1-*]_auto_pwm_freq in units of 0.1 Hz. The old naming was not only non-standard, it was also confusing, because it suggested that the frequency value only applied in automatic fan speed mode, which isn't true. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NHerbert Poetzl <herbert@13thfloor.at>
-
由 Jean Delvare 提交于
Rework the device detection to make it clearer and faster in the general case (when a known device is found.) Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NHerbert Poetzl <herbert@13thfloor.at>
-
由 Dmitry Torokhov 提交于
Simplify the IRQ handling routine of ams driver. Signed-off-by: NDmitry Torokhov <dtor@mail.ru> Signed-off-by: NJohannes Berg <johannes@sipsolutions.net> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Dmitry Torokhov 提交于
Use a separate mutex to serialize input device creation/removal, otheriwse we deadlock if we try to remove input device while it is being polled. Also do not take ams_info.lock when it is not needed. Signed-off-by: NDmitry Torokhov <dtor@mail.ru> Signed-off-by: NJohannes Berg <johannes@sipsolutions.net> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Dmitry Torokhov 提交于
We should not allow writes to the 'joystick' module parameters since writing there will not trigger creation of the input device. Disable writes since we provide alternative way of enabling input device via AMS device's sysfs attribute. Signed-off-by: NDmitry Torokhov <dtor@mail.ru> Acked-by: NJohannes Berg <johannes@sipsolutions.net> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Jean Delvare 提交于
The legacy i2c binding model is phasing out, so the ams driver needs to be converted to a new-style i2c driver. Here is a naive approach of this conversion. Basically it is moving the i2c device creation from the ams driver to the i2c-powermac driver. This should work, but I suspect we could come up with something cleaner by declaring the i2c device as part of the platform setup. This could be done later by someone more familiar with openfirmware-based platforms than I am myself. One nice thing brought by this conversion is that the ams driver should be loaded automatically on systems where is is needed (at least when the I2C interface to the chip is used) providing coldplug-aware user-space environment. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NJohannes Berg <johannes@sipsolutions.net> Cc: Stelian Pop <stelian@popies.net> Cc: Michael Hanselmann <linux-kernel@hansmi.ch> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-
由 Ben Hutchings 提交于
The lm87 driver normally assumes that firmware configured the chip correctly. Since this is not always the case, alllow platform code to set the channel register value via platform_data. All other configuration registers can be changed after driver initialisation. Signed-off-by: NBen Hutchings <bhutchings@solarflare.com> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Ben Hutchings 提交于
This means that if we have to start the monitor when probed, we also stop it on removal. Signed-off-by: NBen Hutchings <bhutchings@solarflare.com> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Ben Hutchings 提交于
lm87_init_client() conditionally sets the Start bit and clears the INT#_Clear bit in the Config 1 register. The condition should be that either of these bits needs changing, but currently it checks the (self-clearing) Initialization bit instead of INT#_Clear. Fix the condition and also ensure we never set the Initialization bit. Signed-off-by: NBen Hutchings <bhutchings@solarflare.com> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Jean Delvare 提交于
Degrade the "Unsupported chip" message from info to debug level. There's nothing wrong with this, so no need to bother the user. Also make the message slightly more descriptive. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NMartyn Welch <martyn.welch@gefanuc.com>
-
由 Ben Hutchings 提交于
These Maxim chips are similar to MAX6657 but use unsigned temperature values to allow for readings up to 145 degrees. Signed-off-by: NBen Hutchings <bhutchings@solarflare.com> Signed-off-by: NJean Delvare <khali@linux-fr.org>
-
由 Ben Hutchings 提交于
The encoding of temperatures varies between chips and modes. So do not use "temp1" or "temp2" in the names of the conversion functions, but specify the encoding. Signed-off-by: NBen Hutchings <bhutchings@solarflare.com> Signed-off-by: NJean Delvare <khali@linux-fr.org> Tested-by: NMartyn Welch <martyn.welch@gefanuc.com>
-
由 Nate Case 提交于
Support ADT7461 in extended temperature range mode, which will change the range of readings from 0..127 to -64..191 degC. Adjust the register conversion functions accordingly. Signed-off-by: NNate Case <ncase@xes-inc.com> Signed-off-by: NJean Delvare <khali@linux-fr.org> Tested-by: NMartyn Welch <martyn.welch@gefanuc.com>
-
由 Nate Case 提交于
Use static functions instead of the TEMPx_FROM_REG* and TEMPx_TO_REG* macros. This will ensure type safety and eliminate any side effects from arguments passed in since the macros referenced 'val' multiple times. This change should not affect functionality. Signed-off-by: NNate Case <ncase@xes-inc.com> Signed-off-by: NJean Delvare <khali@linux-fr.org> Tested-by: NMartyn Welch <martyn.welch@gefanuc.com>
-
由 Jean Delvare 提交于
Update the links to the datasheet of some of the devices supported by the lm90 driver. Also remove the links from the driver itself, so that we don't have to update them twice each time they change. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NMartyn Welch <martyn.welch@gefanuc.com>
-
由 Jean Delvare 提交于
The Maxim chips supported by the lm90 driver have 8-bit high and low remote limit values, not 11-bit as the other chips have. So stop reading from and writing to registers that do not exist on these chips. Also round the limit values set by the user properly. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NMartyn Welch <martyn.welch@gefanuc.com>
-
由 Jean Delvare 提交于
The Maxim MAX6657, MAX6658 and MAX6659 have extra resolution bits for the local temperature measurement. Let the lm90 driver read them and export them to user-space. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NMartyn Welch <martyn.welch@gefanuc.com>
-
由 Jean Delvare 提交于
Move the code which aggregates two 8-bit register values into a 16-bit value to a separate function. We'll need to do it a second time soon and I don't want to duplicate the code. Signed-off-by: NJean Delvare <khali@linux-fr.org> Acked-by: NMartyn Welch <martyn.welch@gefanuc.com>
-