#
d2904168 |
| 18-Sep-2023 |
Uwe Kleine-König <u.kleine-koenig@pengutronix.de> |
hwmon: (pc87427) Convert to platform remove callback returning void
The .remove() callback for a platform driver returns an int which makes many driver authors wrongly assume it's possible to do err
hwmon: (pc87427) Convert to platform remove callback returning void
The .remove() callback for a platform driver returns an int which makes many driver authors wrongly assume it's possible to do error handling by returning an error code. However the value returned is ignored (apart from emitting a warning) and this typically results in resource leaks. To improve here there is a quest to make the remove callback return void. In the first step of this quest all drivers are converted to .remove_new() which already returns void. Eventually after all drivers are converted, .remove_new() is renamed to .remove().
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Link: https://lore.kernel.org/r/20230918085951.1234172-14-u.kleine-koenig@pengutronix.de Signed-off-by: Guenter Roeck <linux@roeck-us.net>
show more ...
|
#
1802d0be |
| 27-May-2019 |
Thomas Gleixner <tglx@linutronix.de> |
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 174
Based on 1 normalized pattern(s):
this program is free software you can redistribute it and or modify it under the terms of th
treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 174
Based on 1 normalized pattern(s):
this program is free software you can redistribute it and or modify it under the terms of the gnu general public license version 2 as published by the free software foundation this program is distributed in the hope that it will be useful but without any warranty without even the implied warranty of merchantability or fitness for a particular purpose see the gnu general public license for more details
extracted by the scancode license scanner the SPDX license identifier
GPL-2.0-only
has been chosen to replace the boilerplate/reference in 655 file(s).
Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Allison Randal <allison@lohutok.net> Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org> Reviewed-by: Richard Fontana <rfontana@redhat.com> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190527070034.575739538@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
show more ...
|
#
755a9b0f |
| 04-Apr-2019 |
Guenter Roeck <linux@roeck-us.net> |
hwmon: (pc87427) Use request_muxed_region for Super-IO accesses
Super-IO accesses may fail on a system with no or unmapped LPC bus.
Also, other drivers may attempt to access the LPC bus at the same
hwmon: (pc87427) Use request_muxed_region for Super-IO accesses
Super-IO accesses may fail on a system with no or unmapped LPC bus.
Also, other drivers may attempt to access the LPC bus at the same time, resulting in undefined behavior.
Use request_muxed_region() to ensure that IO access on the requested address space is supported, and to ensure that access by multiple drivers is synchronized.
Fixes: ba224e2c4f0a7 ("hwmon: New PC87427 hardware monitoring driver") Reported-by: Kefeng Wang <wangkefeng.wang@huawei.com> Reported-by: John Garry <john.garry@huawei.com> Cc: John Garry <john.garry@huawei.com> Acked-by: John Garry <john.garry@huawei.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
show more ...
|
#
86b9f565 |
| 10-Dec-2018 |
Guenter Roeck <linux@roeck-us.net> |
hwmon: (pc87427) Use permission specific SENSOR[_DEVICE]_ATTR variants
Use SENSOR[_DEVICE]_ATTR[_2]_{RO,RW,WO} to simplify the source code, to improve readability, and to reduce the chance of incons
hwmon: (pc87427) Use permission specific SENSOR[_DEVICE]_ATTR variants
Use SENSOR[_DEVICE]_ATTR[_2]_{RO,RW,WO} to simplify the source code, to improve readability, and to reduce the chance of inconsistencies.
Also replace any remaining S_<PERMS> in the driver with octal values.
The conversion was done automatically with coccinelle. The semantic patches and the scripts used to generate this commit log are available at https://github.com/groeck/coccinelle-patches/hwmon/.
This patch does not introduce functional changes. It was verified by compiling the old and new files and comparing text and data sizes.
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
show more ...
|
#
a81b67da |
| 22-Dec-2016 |
Julia Lawall <Julia.Lawall@lip6.fr> |
hwmon: (pc87427) use permission-specific DEVICE_ATTR variants
Use DEVICE_ATTR_RO for read-only attributes. This simplifies the source code, improves readbility, and reduces the chance of inconsisten
hwmon: (pc87427) use permission-specific DEVICE_ATTR variants
Use DEVICE_ATTR_RO for read-only attributes. This simplifies the source code, improves readbility, and reduces the chance of inconsistencies.
The conversion was done automatically using coccinelle. It was validated by compiling both the old and the new source code and comparing its text, data, and bss size.
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> [groeck: Updated description] Signed-off-by: Guenter Roeck <linux@roeck-us.net>
show more ...
|
#
2a1ed077 |
| 20-Oct-2014 |
Wolfram Sang <wsa@the-dreams.de> |
hwmon: drop owner assignment from platform_drivers
A platform_driver does not need to set an owner, it will be populated by the driver core.
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
|
#
2f89b072 |
| 29-Apr-2014 |
Jingoo Han <jg1.han@samsung.com> |
hwmon: (pc87427) remove unnecessary OOM messages
The site-specific OOM messages are unnecessary, because they duplicate the MM subsystem generic OOM message.
Signed-off-by: Jingoo Han <jg1.han@sams
hwmon: (pc87427) remove unnecessary OOM messages
The site-specific OOM messages are unnecessary, because they duplicate the MM subsystem generic OOM message.
Signed-off-by: Jingoo Han <jg1.han@samsung.com> Acked-by: Jean Delvare <jdelvare@suse.de> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
show more ...
|
#
7c81c60f |
| 29-Jan-2014 |
Jean Delvare <khali@linux-fr.org> |
Update Jean Delvare's e-mail address
Signed-off-by: Jean Delvare <khali@linux-fr.org>
|
#
a8b3a3a5 |
| 30-Jul-2013 |
Jingoo Han <jg1.han@samsung.com> |
hwmon: use dev_get_platdata()
Use the wrapper function for retrieving the platform data instead of accessing dev->platform_data directly.
Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-
hwmon: use dev_get_platdata()
Use the wrapper function for retrieving the platform data instead of accessing dev->platform_data directly.
Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
show more ...
|
#
b55f3757 |
| 10-Jan-2013 |
Guenter Roeck <linux@roeck-us.net> |
hwmon: Fix checkpatch warning 'quoted string split across lines'
Cc: Corentin Labbe <corentin.labbe@geomatys.fr> Cc: Mark M. Hoffman <mhoffman@lightlink.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc
hwmon: Fix checkpatch warning 'quoted string split across lines'
Cc: Corentin Labbe <corentin.labbe@geomatys.fr> Cc: Mark M. Hoffman <mhoffman@lightlink.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Juerg Haefliger <juergh@gmail.com> Cc: Andreas Herrmann <herrmann.der.user@googlemail.com> Cc: Rudolf Marek <r.marek@assembler.cz> Cc: Jim Cromie <jim.cromie@gmail.com> Cc: Roger Lucas <vt8231@hiddenengine.co.uk> Cc: Marc Hulsman <m.hulsman@tudelft.nl> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
show more ...
|
#
281dfd0b |
| 19-Nov-2012 |
Bill Pemberton <wfp5p@virginia.edu> |
hwmon: remove use of __devexit
CONFIG_HOTPLUG is going away as an option so __devexit is no longer needed.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hans de Goede <hdegoede@redhat.com>
hwmon: remove use of __devexit
CONFIG_HOTPLUG is going away as an option so __devexit is no longer needed.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hans de Goede <hdegoede@redhat.com> Cc: Jean Delvare <khali@linux-fr.org> Cc: Alistair John Strachan <alistair@devzero.co.uk> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Juerg Haefliger <juergh@gmail.com> Cc: Andreas Herrmann <herrmann.der.user@googlemail.com> Cc: Clemens Ladisch <clemens@ladisch.de> Cc: Rudolf Marek <r.marek@assembler.cz> Cc: Jim Cromie <jim.cromie@gmail.com> Cc: "Mark M. Hoffman" <mhoffman@lightlink.com> Cc: Roger Lucas <vt8231@hiddenengine.co.uk> Acked-by: Guenter Roeck <linux@roeck-us.net> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
show more ...
|
#
6c931ae1 |
| 19-Nov-2012 |
Bill Pemberton <wfp5p@virginia.edu> |
hwmon: remove use of __devinit
CONFIG_HOTPLUG is going away as an option so __devinit is no longer needed.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hans de Goede <hdegoede@redhat.com>
hwmon: remove use of __devinit
CONFIG_HOTPLUG is going away as an option so __devinit is no longer needed.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hans de Goede <hdegoede@redhat.com> Cc: Jean Delvare <khali@linux-fr.org> Cc: Alistair John Strachan <alistair@devzero.co.uk> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Juerg Haefliger <juergh@gmail.com> Cc: Andreas Herrmann <herrmann.der.user@googlemail.com> Cc: Clemens Ladisch <clemens@ladisch.de> Cc: Rudolf Marek <r.marek@assembler.cz> Cc: Jim Cromie <jim.cromie@gmail.com> Cc: "Mark M. Hoffman" <mhoffman@lightlink.com> Cc: Roger Lucas <vt8231@hiddenengine.co.uk> Acked-by: Guenter Roeck <linux@roeck-us.net> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
show more ...
|
#
9e5e9b7a |
| 19-Nov-2012 |
Bill Pemberton <wfp5p@virginia.edu> |
hwmon: remove use of __devexit_p
CONFIG_HOTPLUG is going away as an option so __devexit_p is no longer needed.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hans de Goede <hdegoede@redhat.
hwmon: remove use of __devexit_p
CONFIG_HOTPLUG is going away as an option so __devexit_p is no longer needed.
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hans de Goede <hdegoede@redhat.com> Cc: Jean Delvare <khali@linux-fr.org> Cc: Alistair John Strachan <alistair@devzero.co.uk> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Juerg Haefliger <juergh@gmail.com> Cc: Andreas Herrmann <herrmann.der.user@googlemail.com> Cc: Clemens Ladisch <clemens@ladisch.de> Cc: Rudolf Marek <r.marek@assembler.cz> Cc: Jim Cromie <jim.cromie@gmail.com> Cc: "Mark M. Hoffman" <mhoffman@lightlink.com> Cc: Roger Lucas <vt8231@hiddenengine.co.uk> Acked-by: Guenter Roeck <linux@roeck-us.net> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
show more ...
|
#
5e0c8769 |
| 02-Jun-2012 |
Guenter Roeck <linux@roeck-us.net> |
hwmon: (pc87427) Convert to use devm_ functions
Convert to use devm_ functions to reduce code size and simplify the code.
Cc: Jean Delvare <khali@linux-fr.org> Signed-off-by: Guenter Roeck <linux@r
hwmon: (pc87427) Convert to use devm_ functions
Convert to use devm_ functions to reduce code size and simplify the code.
Cc: Jean Delvare <khali@linux-fr.org> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Acked-by: Jean Delvare <khali@linux-fr.org>
show more ...
|
#
36564efa |
| 19-Jan-2012 |
Guenter Roeck <linux@roeck-us.net> |
hwmon: (pc87427) Fix multi-line comments
Cc: Jean Delvare <khali@linux-fr.org> Signed-off-by: Guenter Roeck <linux@roeck-us.net> Acked-by: Jean Delvare <khali@linux-fr.org>
|
#
179c4fdb |
| 04-Jan-2012 |
Frans Meulenbroeks <fransmeulenbroeks@gmail.com> |
hwmon: replaced strict_str* with kstr*
replaced strict_strtol with kstrtol and replaced strict_strtuol with kstrtuol
This satisfies checkpatch -f Compile tested only: no warnings or errors given
S
hwmon: replaced strict_str* with kstr*
replaced strict_strtol with kstrtol and replaced strict_strtuol with kstrtuol
This satisfies checkpatch -f Compile tested only: no warnings or errors given
Signed-off-by: Frans Meulenbroeks <fransmeulenbroeks@gmail.com> Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
show more ...
|
#
5e24e0c3 |
| 12-Jan-2011 |
Joe Perches <joe@perches.com> |
hwmon: (pc87427) Use pr_fmt and pr_<level>
Added #define pr_fmt KBUILD_MODNAME ": " fmt Converted printks to pr_<level> Coalesced any long formats Removed prefixes from formats
Signed-off-by: Joe P
hwmon: (pc87427) Use pr_fmt and pr_<level>
Added #define pr_fmt KBUILD_MODNAME ": " fmt Converted printks to pr_<level> Coalesced any long formats Removed prefixes from formats
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Jean Delvare <khali@linux-fr.org>
show more ...
|
#
c6b87246 |
| 14-Aug-2010 |
Jean Delvare <khali@linux-fr.org> |
hwmon: (pc87427) Move sysfs file removal to a separate function
The sysfs file removal code is the same in the probe error path and in the remove function, so move it to a separate function to avoid
hwmon: (pc87427) Move sysfs file removal to a separate function
The sysfs file removal code is the same in the probe error path and in the remove function, so move it to a separate function to avoid code duplication.
Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
show more ...
|
#
008e5f33 |
| 14-Aug-2010 |
Jean Delvare <khali@linux-fr.org> |
hwmon: (pc87427) Add temperature monitoring support
Add support for the 6 temperature monitoring channels of the PC87427. Note that the sensors resolution can vary, and I couldn't find a way to figu
hwmon: (pc87427) Add temperature monitoring support
Add support for the 6 temperature monitoring channels of the PC87427. Note that the sensors resolution can vary, and I couldn't find a way to figure it out, so we might have to compensate in user-space.
Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
show more ...
|
#
9d32df19 |
| 14-Aug-2010 |
Jean Delvare <khali@linux-fr.org> |
hwmon: (pc87427) Add support for the second logical device
The second logical device contains the voltage and temperature registers. We have to extend the driver to support a second logical device b
hwmon: (pc87427) Add support for the second logical device
The second logical device contains the voltage and temperature registers. We have to extend the driver to support a second logical device before we can add support for these features.
Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
show more ...
|
#
328716bc |
| 14-Aug-2010 |
Jean Delvare <khali@linux-fr.org> |
hwmon: (pc87427) Add support for manual fan speed control
Add initial support for PWM outputs of the PC87427 Super-I/O chip. Only mode change and manual fan speed control are supported. Automatic mo
hwmon: (pc87427) Add support for manual fan speed control
Add initial support for PWM outputs of the PC87427 Super-I/O chip. Only mode change and manual fan speed control are supported. Automatic mode configuration isn't supported, and won't be until at least one board is known, which makes uses of the PWM outputs.
Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
show more ...
|
#
0d22d583 |
| 14-Aug-2010 |
Jean Delvare <khali@linux-fr.org> |
hwmon: (pc87427) Minor style cleanups
Follow the best practice of the day.
Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
|
#
4e7d99e1 |
| 14-Aug-2010 |
Jean Delvare <khali@linux-fr.org> |
hwmon: (pc87427) Handle disabled fan inputs properly
Most fan input pins of the PC87427 can have alternate functions. Update the driver to check the configuration register and only support fan input
hwmon: (pc87427) Handle disabled fan inputs properly
Most fan input pins of the PC87427 can have alternate functions. Update the driver to check the configuration register and only support fan inputs which are really used for fan monitoring.
Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: Guenter Roeck <guenter.roeck@ericsson.com>
show more ...
|
#
86855b0c |
| 15-Sep-2009 |
Julia Lawall <julia@diku.dk> |
hwmon: Use resource_size
Use the function resource_size, which reduces the chance of introducing off-by-one errors in calculating the resource size.
The semantic patch that makes this change is as
hwmon: Use resource_size
Use the function resource_size, which reduces the chance of introducing off-by-one errors in calculating the resource size.
The semantic patch that makes this change is as follows: (http://www.emn.fr/x-info/coccinelle/)
// <smpl> @@ struct resource *res; @@
- (res->end - res->start) + 1 + resource_size(res) // </smpl>
Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Jean Delvare <khali@linux-fr.org>
show more ...
|
#
6055fae8 |
| 15-Sep-2009 |
H Hartley Sweeten <hartleys@visionengravers.com> |
hwmon: Include <linux/io.h> instead of <asm/io.h>
Drivers should be including <linux/io.h> instead of <asm/io.h>.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Alistair John S
hwmon: Include <linux/io.h> instead of <asm/io.h>
Drivers should be including <linux/io.h> instead of <asm/io.h>.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Alistair John Strachan <alistair@devzero.co.uk> Cc: Nicolas Boichat <nicolas@boichat.ch> Cc: Juerg Haefliger <juergh@gmail.com> Cc: Frank Seidel <frank@f-seidel.de> Acked-by: Jim Cromie <jim.cromie@gmail.com> Cc: "Mark M. Hoffman" <mhoffman@lightlink.com> Cc: Roger Lucas <vt8231@hiddenengine.co.uk> Signed-off-by: Jean Delvare <khali@linux-fr.org>
show more ...
|