linux-2.6
16 years agohwmon: (asb100) Various cleanups
Jean Delvare [Thu, 3 Jan 2008 22:15:49 +0000 (23:15 +0100)] 
hwmon: (asb100) Various cleanups

* Drop history, it's incomplete and doesn't belong there
* Drop unused version number
* Drop trailing spaces
* Coding style fixes
* Fold long lines
* Rename new_client to client
* Drop redundant initializations to 0

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Hans de Goede <j.w.r.degoede@hhs.nl>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: VRM is not written to registers
Jean Delvare [Sat, 1 Dec 2007 10:25:33 +0000 (11:25 +0100)] 
hwmon: VRM is not written to registers

What was true of reading the VRM value is also true of writing it: not
being a register value, it doesn't need hardware access, so we don't
need a reference to the i2c client. This allows for a minor code
cleanup. As gcc appears to be smart enough to simplify the generated
code by itself, this cleanup only affects the source code, the
generated binaries are unchanged.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (dme1737) fix Super-IO device ID override
Juerg Haefliger [Sat, 26 Jan 2008 16:54:24 +0000 (08:54 -0800)] 
hwmon: (dme1737) fix Super-IO device ID override

The dme1737 has a second place where the Super-IO device ID is
checked. This has been missed by Jean's initial patch that adds
support for user-controlled Super-IO device ID override. This patch
fixes this issue.

Signed-off-by: Juerg Haefliger <juergh at gmail.com>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (dme1737) fix divide-by-0
Juerg Haefliger [Mon, 28 Jan 2008 00:39:46 +0000 (16:39 -0800)] 
hwmon: (dme1737) fix divide-by-0

This patch fixes a possible divide-by-0 and a minor bug in the
FAN_FROM_REG macro (in TPC mode).

Signed-off-by: Juerg Haefliger <juergh at gmail.com>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (abituguru3) Add AUX4 fan input for Abit IP35 Pro
Sergey Vlasov [Tue, 15 Jan 2008 18:57:44 +0000 (21:57 +0300)] 
hwmon: (abituguru3) Add AUX4 fan input for Abit IP35 Pro

Abit IP35 Pro has 6 fan connectors (CPU, SYS and AUX1-4), but the
entry for AUX4 was missing from the table.

Signed-off-by: Sergey Vlasov <vsu@altlinux.ru>
Acked-by: Hans de Goede <j.w.r.degoede@hhs.nl>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: Add support for Texas Instruments/Burr-Brown ADS7828
Steve Hardy [Tue, 22 Jan 2008 23:00:02 +0000 (23:00 +0000)] 
hwmon: Add support for Texas Instruments/Burr-Brown ADS7828

Signed-off-by: Steve Hardy <steve@linuxrealtime.co.uk>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm9240) Add individual alarm files
Jean Delvare [Sun, 6 Jan 2008 14:49:19 +0000 (15:49 +0100)] 
hwmon: (adm9240) Add individual alarm files

The new libsensors needs these individual alarm files.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Tested-by: Grant Coady <gcoady.lk@gmail.com>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (lm77) Add individual alarm files
Jean Delvare [Thu, 3 Jan 2008 22:35:33 +0000 (23:35 +0100)] 
hwmon: (lm77) Add individual alarm files

The new libsensors needs this. As the old library never had support for
the lm77 driver, I even dropped the legacy "alarms" file.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Hans de Goede <j.w.r.degoede@hhs.nl>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: Discard useless I2C driver IDs
Jean Delvare [Thu, 3 Jan 2008 18:44:09 +0000 (19:44 +0100)] 
hwmon: Discard useless I2C driver IDs

Many I2C hwmon drivers define a driver ID but no other code references
these, meaning that they are useless. Discard them, along with a few
IDs which are defined but never used at all.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (lm85) Make the pwmN_enable files writable
Jean Delvare [Mon, 3 Dec 2007 22:28:42 +0000 (23:28 +0100)] 
hwmon: (lm85) Make the pwmN_enable files writable

Make the pwmN_enable files writable. This makes it possible to use
standard fan speed control tools (pwmconfig, fancontrol) with the lm85
driver.

I left the non-standard pwmN_auto_channels files in place, as they
give additional control for the automatic mode, and some users might
be used to them by now.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (lm85) Return standard values in pwmN_enable
Jean Delvare [Mon, 3 Dec 2007 22:23:21 +0000 (23:23 +0100)] 
hwmon: (lm85) Return standard values in pwmN_enable

The values returned by the lm85 driver in pwmN_enable sysfs files do
not match the standard. Fix that.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm1031) Add individual alarm and fault files
Jean Delvare [Sun, 2 Dec 2007 22:42:24 +0000 (23:42 +0100)] 
hwmon: (adm1031) Add individual alarm and fault files

The new libsensors needs these.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm1031) Get rid of macro-generated wrappers
Jean Delvare [Sun, 2 Dec 2007 22:39:38 +0000 (23:39 +0100)] 
hwmon: (adm1031) Get rid of macro-generated wrappers

Use the standard dynamic sysfs callbacks instead of macro-generated
wrappers. It makes the code more simple and the binary smaller (-8% on
my system.)

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm1031) Various cleanups
Jean Delvare [Sun, 2 Dec 2007 22:33:57 +0000 (23:33 +0100)] 
hwmon: (adm1031) Various cleanups

* Rename new_client to client
* Drop redundant initializations to 0
* Drop trailing space
* Other whitespace cleanups
* Split/fold a few long lines
* Constify static data
* Optimizations in set_fan_div()

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm1031) Fix register overwrite in set_fan_div()
Jean Delvare [Sun, 2 Dec 2007 22:32:42 +0000 (23:32 +0100)] 
hwmon: (adm1031) Fix register overwrite in set_fan_div()

Don't rely on the register cache when setting a new fan clock divider.
For one thing, the cache might not have been initialized at all if the
driver has just been loaded. For another, the cached values may be old
and you never know what can happen in the driver's back.

Also invalidate the cache instead of trying to adjust the measured fan
speed: the whole point of changing the clock divider is to get a better
reading.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (it87) Delete pwmN_freq files on driver removal
Jean Delvare [Fri, 14 Dec 2007 13:41:53 +0000 (14:41 +0100)] 
hwmon: (it87) Delete pwmN_freq files on driver removal

In commit f8d0c19a93cea3a26a90f2462295e1e01a4cd250 I forgot to delete
the pwmN_freq files on driver removal, here's the fix.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Riku Voipio <riku.voipio@movial.fi>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (w83781d) Misc cleanups
Jean Delvare [Fri, 30 Nov 2007 22:52:44 +0000 (23:52 +0100)] 
hwmon: (w83781d) Misc cleanups

* Drop unused defines
* Drop unused driver ID
* Remove trailing whitespace

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (w83781d) Drop W83627HF support
Jean Delvare [Fri, 30 Nov 2007 22:51:24 +0000 (23:51 +0100)] 
hwmon: (w83781d) Drop W83627HF support

The W83627HF hardware monitoring features are supported by the
w83627hf driver for several years now. Support by the w83781d has
been advertised as deprecated 6 months ago, it's about time to see
it go.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm1026) Don't create files for missing inputs
Jean Delvare [Thu, 29 Nov 2007 22:47:54 +0000 (23:47 +0100)] 
hwmon: (adm1026) Don't create files for missing inputs

On the ADM1026, pins 27 and 28 can be used for two different functions:
either temp3, or in8+in9. We should only create the sysfs files for the
function that is configured, otherwise it is confusing for the user.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm1026) More cleanups (updated)
Jean Delvare [Sat, 1 Dec 2007 10:24:17 +0000 (11:24 +0100)] 
hwmon: (adm1026) More cleanups (updated)

Various cleanups:
* Drop an unused define.
* Drop unused struct member "type".
* Drop one useless instruction.
* Drop redundant initializations to 0.
* Rename new_client to client.
* Drop a useless cast.
* Minor code cleanup.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm1026) Whitespace cleanups
Jean Delvare [Thu, 29 Nov 2007 22:46:42 +0000 (23:46 +0100)] 
hwmon: (adm1026) Whitespace cleanups

Whitespace cleanups only:
* Trim trailing whitespace.
* Use tabs for indentation and alignment.
* Add missing space after commas.
* Remove extra spaces.

No functional change, binary is identical before and after this patch.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm1026) Add individual alarm files
Jean Delvare [Thu, 29 Nov 2007 22:45:22 +0000 (23:45 +0100)] 
hwmon: (adm1026) Add individual alarm files

The new libsensors needs these.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (it87) Add individual alarm files
Jean Delvare [Sun, 25 Nov 2007 15:16:41 +0000 (16:16 +0100)] 
hwmon: (it87) Add individual alarm files

The new libsensors needs this.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (it87) Discard a dead e-mail address
Jean Delvare [Sun, 25 Nov 2007 15:14:44 +0000 (16:14 +0100)] 
hwmon: (it87) Discard a dead e-mail address

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adt7470) Support per-sensor alarm files
Darrick J. Wong [Wed, 19 Dec 2007 22:11:25 +0000 (14:11 -0800)] 
hwmon: (adt7470) Support per-sensor alarm files

Remove the old alarms hack and replace it with per-sensor alarm files.

Signed-off-by: Darrick J. Wong <djwong@us.ibm.com>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (fschmd) Read voltage scaling factors from BIOS DMI
Hans de Goede [Thu, 20 Dec 2007 15:42:59 +0000 (16:42 +0100)] 
hwmon: (fschmd) Read voltage scaling factors from BIOS DMI

This patch adds support to the fschmd driver for reading the voltage scaling
factors from BIOS DMI tables, as specified in the Siemens datasheet.

Signed-off-by: Hans de Goede <j.w.r.degoede@hhs.nl>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: Let the user override the detected Super-I/O device ID
Jean Delvare [Thu, 6 Dec 2007 22:13:42 +0000 (23:13 +0100)] 
hwmon: Let the user override the detected Super-I/O device ID

While it is possible to force SMBus-based hardware monitoring chip
drivers to drive a not officially supported device, we do not have this
possibility for Super-I/O-based drivers. That's unfortunate because
sometimes newer chips are fully compatible and just forcing the driver
to load would work. Instead of that we have to tell the users to
recompile the kernel driver, which isn't an easy task for everyone.

So, I propose that we add a module parameter to all Super-I/O based
hardware monitoring drivers, letting advanced users force the driver
to load on their machine. The user has to provide the device ID of a
supposedly compatible device. This requires looking at the source code or
a datasheet, so I am confident that users can't randomly force a driver
without knowing what they are doing. Thus this should be relatively safe.

As you can see from the code, the implementation is pretty simple and
unintrusive.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Acked-by: Hans de Goede <j.w.r.degoede@hhs.nl>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (vt8231) Add missing "space"
Joe Perches [Tue, 20 Nov 2007 01:48:07 +0000 (17:48 -0800)] 
hwmon: (vt8231) Add missing "space"

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: Update the lm-sensors website address
Jean Delvare [Sun, 18 Nov 2007 22:46:10 +0000 (23:46 +0100)] 
hwmon: Update the lm-sensors website address

It's about time to reflect the move of the lm-sensors project to
lm-sensors.org.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (gl520sm) Add individual alarm and beep files
Jean Delvare [Sun, 4 Nov 2007 22:45:41 +0000 (23:45 +0100)] 
hwmon: (gl520sm) Add individual alarm and beep files

libsensors 3.0 needs these.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (gl520sm) De-macro the sysfs callbacks
Jean Delvare [Sun, 4 Nov 2007 22:45:14 +0000 (23:45 +0100)] 
hwmon: (gl520sm) De-macro the sysfs callbacks

Use standard dynamic sysfs callbacks instead of macro-generated
wrappers. This makes the code more readable, and the binary smaller
(by about 11%).

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (gl520sm) Put register addresses in arrays
Jean Delvare [Sun, 4 Nov 2007 22:44:52 +0000 (23:44 +0100)] 
hwmon: (gl520sm) Put register addresses in arrays

This allows for some code refactoring, making the binary slightly
smaller. This is also required to use dynamic sysfs callbacks for
voltage and temperature files.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (gl520sm) Various cleanups
Jean Delvare [Sun, 4 Nov 2007 22:44:23 +0000 (23:44 +0100)] 
hwmon: (gl520sm) Various cleanups

* Drop trailing spaces
* Drop unused driver ID
* Drop stray backslashes in macros
* Rename new_client to client
* Drop redundant initializations to 0

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (lm90) Use generic i2c reads during detection
Jean Delvare [Sun, 25 Nov 2007 20:58:21 +0000 (21:58 +0100)] 
hwmon: (lm90) Use generic i2c reads during detection

As indirectly reported by Olof Johansson, the lm90 driver uses a
custom i2c read function even during detection, at which point we
don't know yet what device we're talking with. It would make more
sense to only use the generic i2c read function at this point, so
that we don't log irrelevant errors on misdetection.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (gl518sm) Fix the reported fan speed
Jean Delvare [Tue, 23 Oct 2007 12:02:24 +0000 (14:02 +0200)] 
hwmon: (gl518sm) Fix the reported fan speed

The fan speeds reported by the gl518sm driver are twice as much as they
should. It's currently reporting the number of pulses per minute, not
rotations per minute, while typical fans emit two pulses per rotation.
This explains why all reports with this driver had very high speed
values (between 9000 to 12000 RPM). Odd that nobody ever actually
complained about this bug.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (gl518sm) Report error on invalid fan div value
Jean Delvare [Mon, 22 Oct 2007 15:47:58 +0000 (17:47 +0200)] 
hwmon: (gl518sm) Report error on invalid fan div value

If the user attempts to write a fan clock divider not supported by
the chip, an error should be returned.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (gl518sm) Add individual alarm and beep files
Jean Delvare [Mon, 22 Oct 2007 15:47:16 +0000 (17:47 +0200)] 
hwmon: (gl518sm) Add individual alarm and beep files

The new libsensors needs these.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (gl518sm) Refactor fan functions
Jean Delvare [Mon, 22 Oct 2007 15:46:42 +0000 (17:46 +0200)] 
hwmon: (gl518sm) Refactor fan functions

This makes the code more readable and the binary smaller (by 5% or so).

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (gl518sm) Don't create sysfs files for missing features
Jean Delvare [Mon, 22 Oct 2007 15:46:17 +0000 (17:46 +0200)] 
hwmon: (gl518sm) Don't create sysfs files for missing features

The early revisions of the GL518SM do not report voltage values for
the first 3 voltage channels. We should not create sysfs attributes
for these missing features.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (gl518sm) Various cleanups
Jean Delvare [Mon, 22 Oct 2007 15:45:08 +0000 (17:45 +0200)] 
hwmon: (gl518sm) Various cleanups

* Drop history, it doesn't belong there
* Drop unused struct member
* Drop bogus struct member comment
* Drop unused driver ID
* Rename new_client to client
* Drop redundant initializations to 0
* Drop useless cast
* Drop trailing space
* Fix comment
* Drop duplicate comment

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (fschmd) Discard non-ASCII characters
Jean Delvare [Sat, 24 Nov 2007 22:45:09 +0000 (17:45 -0500)] 
hwmon: (fschmd) Discard non-ASCII characters

Somehow non-ASCII characters managed to sneak into the fschmd driver.
Kick them out.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Hans de Goede <j.w.r.degoede@hhs.nl>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm1025) Various cleanups
Jean Delvare [Wed, 10 Oct 2007 19:14:11 +0000 (21:14 +0200)] 
hwmon: (adm1025) Various cleanups

* Whitespace cleanups
* Constify scaling constants
* Fold long lines
* Drop redundant initializations to 0
* Rename new_client to just client
* Use sysfs_create_group()
* Drop a useless comment

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm1025) Add individual alarm files
Jean Delvare [Wed, 10 Oct 2007 19:11:52 +0000 (21:11 +0200)] 
hwmon: (adm1025) Add individual alarm files

The future libsensors needs these individual alarm and fault files.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adm1025) Use dynamic sysfs callbacks
Jean Delvare [Wed, 10 Oct 2007 19:11:01 +0000 (21:11 +0200)] 
hwmon: (adm1025) Use dynamic sysfs callbacks

This lets us get rid of macro-generated functions and shrinks the
driver size by about 30%.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (lm87) Add support for the Analog Devices ADM1024
Jean Delvare [Tue, 9 Oct 2007 13:22:22 +0000 (15:22 +0200)] 
hwmon: (lm87) Add support for the Analog Devices ADM1024

It happens that the Analog Devices ADM1024 is fully compatible with
the National Semiconductor LM87, so support for the former can easily
be added to the lm87 driver.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: Add support for Winbond W83L786NG/NR
Kevin Lo [Fri, 23 Nov 2007 01:31:52 +0000 (09:31 +0800)] 
hwmon: Add support for Winbond W83L786NG/NR

Signed-off-by: Kevin Lo <kevlo@kevlo.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (adt7470) Replace power-of-two test
Robert P. J. Day [Tue, 6 Nov 2007 08:21:42 +0000 (03:21 -0500)] 
hwmon: (adt7470) Replace power-of-two test

Since <linux/log2.h> already supplies a power-of-two test, there's no
point in having this source file redefine it again.

Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (w83793) remove duplicated defines
Nicolas Kaiser [Wed, 7 Nov 2007 12:28:59 +0000 (13:28 +0100)] 
hwmon: (w83793) remove duplicated defines

Remove duplicated defines.

Signed-off-by: Nicolas Kaiser <nikai@nikai.net>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agohwmon: (lm78/w83781d) Probe fewer I2C addresses
Jean Delvare [Sun, 7 Oct 2007 10:25:46 +0000 (12:25 +0200)] 
hwmon: (lm78/w83781d) Probe fewer I2C addresses

We've never seen any device supported by the lm78 or w83781d driver at
addresses 0x20-0x27, so let's stop probing these addresses. Extra probes cost
time, and have potential for confusing or misdetecting other I2C devices.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agodmi: Let drivers walk the DMI table
Jean Delvare [Sat, 3 Nov 2007 16:29:20 +0000 (17:29 +0100)] 
dmi: Let drivers walk the DMI table

Let drivers walk the DMI table for their own needs. Some drivers need
data stored in OEM-specific DMI records for proper operation.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
16 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/shaggy...
Linus Torvalds [Thu, 7 Feb 2008 21:21:02 +0000 (13:21 -0800)] 
Merge branch 'for-linus' of git://git./linux/kernel/git/shaggy/jfs-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/shaggy/jfs-2.6:
  BKL-removal: Implement a compat_ioctl handler for JFS
  BKL-removal: Use unlocked_ioctl for jfs

16 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
Linus Torvalds [Thu, 7 Feb 2008 20:57:44 +0000 (12:57 -0800)] 
Merge branch 'for-linus' of git://git./linux/kernel/git/dtor/input

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (34 commits)
  Input: i8042 - non-x86 build fix
  Input: pxa27x_keypad - also enable on PXA3xx
  Input: pxa27x_keypad - add debounce_interval to the keypad platform data
  Input: pxa27x_keypad - use device resources for I/O memory mapping and IRQ
  Input: pxa27x_keypad - enable rotary encoders and direct keys
  Input: pxa27x_keypad - introduce pxa27x_keypad_config()
  Input: pxa27x_keypad - introduce driver structure and use KEY() to define matrix keys
  Input: pxa27x_keypad - remove pin configuration from the driver
  Input: pxa27x_keypad - rename the driver (was pxa27x_keyboard)
  Input: constify function pointer tables (seq_operations)
  Input: i8042 - add Fujitsu-Siemens Amilo Pro 2010 to nomux list
  Input: i8042 - enable DMI quirks on x86-64
  Input: i8042 - add Dritek quirk for Acer Aspire 9110
  Input: add input event to APM event bridge
  Input: mousedev - use BIT_MASK instead of BIT
  Input: remove duplicate includes
  Input: remove cdev from input_dev structure
  Input: remove duplicated headers in drivers/char/keyboard.c
  Input: i8042 - add Dritek keyboard extension quirk
  Input: add Tosa keyboard driver
  ...

16 years agoMerge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mfashe...
Linus Torvalds [Thu, 7 Feb 2008 20:46:35 +0000 (12:46 -0800)] 
Merge branch 'upstream-linus' of git://git./linux/kernel/git/mfasheh/ocfs2

* 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mfasheh/ocfs2:
  ocfs2: Negotiate locking protocol versions.

16 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-2.6
Linus Torvalds [Thu, 7 Feb 2008 20:45:28 +0000 (12:45 -0800)] 
Merge git://git./linux/kernel/git/gregkh/driver-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-2.6:
  sysfs: remove BUG_ON() from sysfs_remove_group()
  Driver core: Revert "Fix Firmware class name collision"
  Block: Fix whole_disk attribute bug

16 years agoBKL-removal: Implement a compat_ioctl handler for JFS
Andi Kleen [Sun, 27 Jan 2008 23:02:02 +0000 (17:02 -0600)] 
BKL-removal: Implement a compat_ioctl handler for JFS

The ioctls were already compatible except for the actual values so this
was fairly easy to do.

Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Dave Kleikamp <shaggy@linux.vnet.ibm.com>
16 years agoi915: Fix GR register array size off-by-one bug
Jesse Barnes [Thu, 7 Feb 2008 19:15:20 +0000 (11:15 -0800)] 
i915: Fix GR register array size off-by-one bug

Make sure we have enough room for all the GR registers or we'll end up
clobbering the AR index register (which should actually be harmless
unless the BIOS is making an assumption about it).

Noticed-by: Jens Axboe <jens.axboe@oracle.com>
Signed-off-by: Jesse Barnes <jesse.barnes@intel.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoBKL-removal: Use unlocked_ioctl for jfs
Andi Kleen [Sun, 27 Jan 2008 22:58:51 +0000 (16:58 -0600)] 
BKL-removal: Use unlocked_ioctl for jfs

Convert jfs_ioctl over to not use the BKL. The only potential race
I could see was with two ioctls in parallel changing the flags
and losing the updates. Use the i_mutex to protect against this.

Signed-off-by: Andi Kleen <ak@suse.de>
Signed-off-by: Dave Kleikamp <shaggy@linux.vnet.ibm.com>
16 years agosysfs: remove BUG_ON() from sysfs_remove_group()
Greg Kroah-Hartman [Thu, 7 Feb 2008 16:58:54 +0000 (11:58 -0500)] 
sysfs: remove BUG_ON() from sysfs_remove_group()

It's possible that the caller of sysfs_remove_group messed up and passed in an attribute group that was not really registered to this kobject.  But don't panic for such a foolish error, spit out a warning about what happened, and continue on our way safely.

Cc: Roland Dreier <rdreier@cisco.com>
Cc: Tejun Heo <htejun@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
16 years agoDriver core: Revert "Fix Firmware class name collision"
Michael E Brown [Tue, 29 Jan 2008 21:35:01 +0000 (15:35 -0600)] 
Driver core: Revert "Fix Firmware class name collision"

This reverts commit 109f0e93b6b728f03c1eb4af02bc25d71b646c59.

The original patch breaks BIOS updates on all Dell machines. The path to
the firmware file for the dell_rbu driver changes, which breaks all of
the userspace tools which rely on it.

Note that this patch re-introduces a problem with i2c name collision
that was previously fixed by this patch.

Signed-off-by: Michael E Brown <michael_e_brown@dell.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
16 years agoBlock: Fix whole_disk attribute bug
Greg Kroah-Hartman [Thu, 7 Feb 2008 07:33:39 +0000 (23:33 -0800)] 
Block: Fix whole_disk attribute bug

The "whole_disk" attribute was not properly converted in the block
device conversion earlier, and if the file is read, bad things can
happen.  This patch fixes this, making the attribute an empty one,
preserving the original functionality.

Many thanks to David Miller for finding this, and pointing me in the
proper place within the block code to look.

Acked-by: David S. Miller <davem@davemloft.net>
Cc: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
16 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6
Linus Torvalds [Thu, 7 Feb 2008 18:21:26 +0000 (10:21 -0800)] 
Merge git://git./linux/kernel/git/davem/sparc-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6:
  [SPARC32]: Use regsets in arch_ptrace().
  [SPARC64]: Use regsets in arch_ptrace().
  [SPARC32]: Use regsets for ELF core dumping.
  [SPARC64]: Use regsets for ELF core dumping.
  [SPARC64]: Remove unintentional ptrace debugging messages.
  [SPARC]: Move over to arch_ptrace().
  [SPARC]: Remove PTRACE_SUN* handling.
  [SPARC]: Kill DEBUG_PTRACE code.
  [SPARC32]: Add user regset support.
  [SPARC64]: Add user regsets.
  [SPARC64]: Fix booting on non-zero cpu.

16 years agoMerge git://git.infradead.org/mtd-2.6
Linus Torvalds [Thu, 7 Feb 2008 18:20:31 +0000 (10:20 -0800)] 
Merge git://git.infradead.org/mtd-2.6

* git://git.infradead.org/mtd-2.6: (120 commits)
  [MTD] Fix mtdoops.c compilation
  [MTD] [NOR] fix startup lock when using multiple nor flash chips
  [MTD] [DOC200x] eccbuf is statically defined and always evaluate to true
  [MTD] Fix maps/physmap.c compilation with CONFIG_PM
  [MTD] onenand: Add panic_write function to the onenand driver
  [MTD] mtdoops: Use the panic_write function when present
  [MTD] Add mtd panic_write function pointer
  [MTD] [NAND] Freescale enhanced Local Bus Controller FCM NAND support.
  [MTD] physmap.c: Add support for multiple resources
  [MTD] [NAND] Fix misparenthesization introduced by commit 78b65179...
  [MTD] [NAND] Fix Blackfin NFC ECC calculating bug with page size 512 bytes
  [MTD] [NAND] Remove wrong operation in PM function of the BF54x NFC driver
  [MTD] [NAND] Remove unused variable in plat_nand_remove
  [MTD] Unlocking all Intel flash that is locked on power up.
  [MTD] [NAND] at91_nand: Make mtdparts option can override board info
  [MTD] mtdoops: Various minor cleanups
  [MTD] mtdoops: Ensure sequential write to the buffer
  [MTD] mtdoops: Perform write operations in a workqueue
  [MTD] mtdoops: Add further error return code checking
  [MTD] [NOR] Test devtype, not definition in flash_probe(), drivers/mtd/devices/lart.c
  ...

16 years agoMerge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux...
Linus Torvalds [Thu, 7 Feb 2008 17:45:58 +0000 (09:45 -0800)] 
Merge branch 'release' of git://git./linux/kernel/git/lenb/linux-acpi-2.6

* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6: (112 commits)
  ACPI: fix build warning
  Revert "cpuidle: build fix for non-x86"
  ACPI: update intrd DSDT override console messages
  ACPI: update DSDT override documentation
  ACPI: Add "acpi_no_initrd_override" kernel parameter
  ACPI: its a directory not a folder....
  ACPI: misc cleanups
  ACPI: add missing prink prefix strings
  ACPI: cleanup acpi.h
  ACPICA: fix CONFIG_ACPI_DEBUG_FUNC_TRACE build
  ACPI: video: Ignore ACPI video devices that aren't present in hardware
  ACPI: video: reset brightness on resume
  ACPI: video: call ACPI notifier chain for ACPI video notifications
  ACPI: create notifier chain to get hotkey events to graphics driver
  ACPI: video: delete unused display switch on hotkey event code
  ACPI: video: create "brightness_switch_enabled" modparam
  cpuidle: Add a poll_idle method
  ACPI: cpuidle: Support C1 idle time accounting
  ACPI: enable MWAIT for C1 idle
  ACPI: idle: Fix acpi_safe_halt usages and interrupt enabling/disabling
  ...

16 years agoMerge branch 'for-linus' of git://git.o-hand.com/linux-rpurdie-backlight
Linus Torvalds [Thu, 7 Feb 2008 17:45:37 +0000 (09:45 -0800)] 
Merge branch 'for-linus' of git://git.o-hand.com/linux-rpurdie-backlight

* 'for-linus' of git://git.o-hand.com/linux-rpurdie-backlight:
  backlight: Add OMAP1 PWL backlight driver
  backlight: Avoid unecessary driver callbacks

16 years agoMerge branch 'for-linus' of git://git.o-hand.com/linux-rpurdie-leds
Linus Torvalds [Thu, 7 Feb 2008 17:45:14 +0000 (09:45 -0800)] 
Merge branch 'for-linus' of git://git.o-hand.com/linux-rpurdie-leds

* 'for-linus' of git://git.o-hand.com/linux-rpurdie-leds:
  leds: Add HP Jornada 6xx driver
  leds: Remove the now uneeded ixp4xx driver
  leds: Add power LED to the wrap driver
  leds: Fix led-gpio active_low default brightness
  leds: hw acceleration for Clevo mail LED driver
  leds: Add support for hardware accelerated LED flashing
  leds: Standardise LED naming scheme
  leds: Add clevo notebook LED driver

16 years agom68k: kill page walker compile warning
Geert Uytterhoeven [Thu, 7 Feb 2008 08:10:37 +0000 (09:10 +0100)] 
m68k: kill page walker compile warning

The recently introduced page walker (walk_page_range()) calls pgd_offset with a
const struct mm_struct pointer, causing the following compile warning on m68k:

    mm/pagewalk.c:111: warning: passing argument 1 of 'pgd_offset' discards qualifiers from pointer target type

Make the `mm' parameter of the inline function pgd_offset() const to shut it
up.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoMerge branch 'drm-patches' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied...
Linus Torvalds [Thu, 7 Feb 2008 17:07:16 +0000 (09:07 -0800)] 
Merge branch 'drm-patches' of git://git./linux/kernel/git/airlied/drm-2.6

* 'drm-patches' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6: (22 commits)
  drm: add initial r500 drm support
  radeon: setup the ring buffer fetcher to be less agressive.
  drm: fixup some of the ioctl function exit paths
  drm: the drm really should call pci_set_master..
  i915: Add chipset id for Intel Integrated Graphics Device
  drm: cleanup DRM_DEBUG() parameters
  drm/i915: add support for E7221 chipset
  drm: don't cast a pointer to pointer of list_head
  mga_dma: return 'err' not just zero from mga_do_cleanup_dma()
  drm: add _DRM_DRIVER flag, and re-order unload.
  drm: enable udev node creation
  drm: Make DRM_IOCTL_GET_CLIENT return EINVAL when it can't find client #idx.
  drm: move drm_mem_init to proper place in startup sequence
  drm: call driver load function after initialising AGP
  drm: Fix ioc32 compat layer
  drm: fd.o bug #11895: Only add the AGP base to map offset if the caller didn't.
  i915: add suspend/resume support
  drm: update DRM sysfs support
  drm: Initialize the AGP structure's base address at init rather than enable.
  drm: move two function extern into the correct block
  ...

16 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davej/cpufreq
Linus Torvalds [Thu, 7 Feb 2008 17:03:00 +0000 (09:03 -0800)] 
Merge git://git./linux/kernel/git/davej/cpufreq

* git://git.kernel.org/pub/scm/linux/kernel/git/davej/cpufreq:
  [CPUFREQ] Add missing printk levels to e_powersaver
  [CPUFREQ] Fix sparse warning in powernow-k8
  [CPUFREQ] Support Model D parts and newer in e_powersaver
  [CPUFREQ] Powernow-k8: Update to support the latest Turion processors
  [CPUFREQ] fix configuration help message
  [CPUFREQ] powernow-k8 print pstate instead of fid/did for family 10h
  [CPUFREQ] Eliminate cpufreq_userspace scaling_setspeed deadlock
  [CPUFREQ] gx-suspmod.c: use boot_cpu_data instead of current_cpu_data
  [CPUFREQ] fix incorrect comment on show_available_freqs() in freq_table.c
  [CPUFREQ] drivers/cpufreq: Add missing "space"
  [CPUFREQ] arch/x86: Add missing "space"
  [CPUFREQ] Remove pointless Kconfig dependancy

16 years agoMerge branch 'for-2.6.25' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus...
Linus Torvalds [Thu, 7 Feb 2008 17:02:26 +0000 (09:02 -0800)] 
Merge branch 'for-2.6.25' of git://git./linux/kernel/git/paulus/powerpc

* 'for-2.6.25' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (69 commits)
  [POWERPC] Add SPE registers to core dumps
  [POWERPC] Use regset code for compat PTRACE_*REGS* calls
  [POWERPC] Use generic compat_sys_ptrace
  [POWERPC] Use generic compat_ptrace_request
  [POWERPC] Use generic ptrace peekdata/pokedata
  [POWERPC] Use regset code for PTRACE_*REGS* requests
  [POWERPC] Switch to generic compat_binfmt_elf code
  [POWERPC] Switch to using user_regset-based core dumps
  [POWERPC] Add user_regset compat support
  [POWERPC] Add user_regset_view definitions
  [POWERPC] Use user_regset accessors for GPRs
  [POWERPC] ptrace accessors for special regs MSR and TRAP
  [POWERPC] Use user_regset accessors for SPE regs
  [POWERPC] Use user_regset accessors for altivec regs
  [POWERPC] Use user_regset accessors for FP regs
  [POWERPC] mpc52xx: fix compile error introduce when rebasing patch
  [POWERPC] 4xx: PCIe indirect DCR spinlock fix.
  [POWERPC] Add missing native dcr dcr_ind_lock spinlock
  [POWERPC] 4xx: Fix offset value on Warp board
  [POWERPC] 4xx: Add 440EPx Sequoia ehci dts entry
  ...

16 years agoChar: mxser, add support for CP-114UL
Jiri Slaby [Thu, 7 Feb 2008 08:16:51 +0000 (00:16 -0800)] 
Char: mxser, add support for CP-114UL

Add new card (0x1393:0x1143) support added in 1.11 original driver, also
allow rate change in set_serial_info ioctl (as per 1.11 too).

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Reviewed-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: mxser, remove it
Jiri Slaby [Thu, 7 Feb 2008 08:16:46 +0000 (00:16 -0800)] 
Char: mxser, remove it

(Old) mxser is obsoleted by mxser_new and scheduled for removal on Dec 2007.
Remove it by renaming mxser_new to mxser.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Reviewed-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: mxser, ioctl cleanup
Jiri Slaby [Thu, 7 Feb 2008 08:16:45 +0000 (00:16 -0800)] 
Char: mxser, ioctl cleanup

- remove dead MOXA_GET_CONF (always returned -ENXIO)
- remove useless MOXA_GET_CUMAJOR (unused)
- use get/put_user instead of copy_from/to_user for simple types
- cleanup TIOCMIWAIT -- return -ERESTARTSYS on signal, move condition into
  separate function

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Reviewed-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: mxser, simplify mxser_get_serial_info
Jiri Slaby [Thu, 7 Feb 2008 08:16:44 +0000 (00:16 -0800)] 
Char: mxser, simplify mxser_get_serial_info

Initialize temp structure directly with proper values without first zeroing
it and setting later as suggested by Jan.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Jan Engelhardt <jengelh@computergmbh.de>
Reviewed-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: mxser, reorder mxser_cardinfo fields
Jiri Slaby [Thu, 7 Feb 2008 08:16:43 +0000 (00:16 -0800)] 
Char: mxser, reorder mxser_cardinfo fields

Reorder fields to save some memory and code on 64bit due to alignment as
suggested by Jan.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Jan Engelhardt <jengelh@computergmbh.de>
Reviewed-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: mxser, 0 to NULL in pointer
Jiri Slaby [Thu, 7 Feb 2008 08:16:43 +0000 (00:16 -0800)] 
Char: mxser, 0 to NULL in pointer

Don't test a pointer against 0. Use NULL instead.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Reviewed-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: mxser, remove special baudrate processing
Jiri Slaby [Thu, 7 Feb 2008 08:16:42 +0000 (00:16 -0800)] 
Char: mxser, remove special baudrate processing

Let the special baudrate processing on the tty layer.  Also remove
set/get_special_rate ioctls introduced in commit
f64c84a1668930d1ca2b7dbaa92146c2139cb508, since it is no longer needed.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Reviewed-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agomxser/mxser_new: first pass over termios reporting for the mxser cards
Alan Cox [Thu, 7 Feb 2008 08:16:41 +0000 (00:16 -0800)] 
mxser/mxser_new: first pass over termios reporting for the mxser cards

Signed-off-by: Alan Cox <alan@redhat.com>
Cc: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: riscom8, remove wakeup and hangup bottomhalves
Jiri Slaby [Thu, 7 Feb 2008 08:16:41 +0000 (00:16 -0800)] 
Char: riscom8, remove wakeup and hangup bottomhalves

Both of them may be called directly from the code, don't add special code
and variables and schedule a work for them.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: serial167, remove bottomhalf
Jiri Slaby [Thu, 7 Feb 2008 08:16:40 +0000 (00:16 -0800)] 
Char: serial167, remove bottomhalf

- Cy_EVENT_OPEN_WAKEUP is simple wake_up
- Cy_EVENT_HANGUP is wake_up + tty_hangup, which schedules its own work
- Cy_EVENT_WRITE_WAKEUP is tty_wakeup which may be called directly too

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: stallion, remove bottomhalf
Jiri Slaby [Thu, 7 Feb 2008 08:16:39 +0000 (00:16 -0800)] 
Char: stallion, remove bottomhalf

- tty_hangup schedules a bottomhalf itself, tty_wakeup doesn't need it
- call the CD code (part of work handler previously) directly from the code
  (it wakes somebody up or calls tty_hangup at worse)

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: specialix, remove bottomhalves
Jiri Slaby [Thu, 7 Feb 2008 08:16:39 +0000 (00:16 -0800)] 
Char: specialix, remove bottomhalves

- tqueue is used only for tty_wakeup, call it directly from the code
- tqueue_hangup for tty_hangup, it schedules its own work, use it directly
  too

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: istallion, remove hangup bottomhalf
Jiri Slaby [Thu, 7 Feb 2008 08:16:38 +0000 (00:16 -0800)] 
Char: istallion, remove hangup bottomhalf

tty_hangup schedules a work for hangup itself, no need to do it in the driver.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: esp, remove hangup and wakeup bottomhalves
Jiri Slaby [Thu, 7 Feb 2008 08:16:37 +0000 (00:16 -0800)] 
Char: esp, remove hangup and wakeup bottomhalves

There is no need to schedule a bottomhalf for either of them. One is fast
and the another schedules a bottomhalf itself.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: riscom8, change rc_init_drivers prototype
Jiri Slaby [Thu, 7 Feb 2008 08:16:36 +0000 (00:16 -0800)] 
Char: riscom8, change rc_init_drivers prototype

Let compiler decide if the rc_init_drivers function will be inlined and
mark it as __init, because it's called only from __init function.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: stallion, fix compiler warnings
Jiri Slaby [Thu, 7 Feb 2008 08:16:36 +0000 (00:16 -0800)] 
Char: stallion, fix compiler warnings

Don't emit warnings on 64 bit platforms from min(). sizeof() on those
is not uint, neither 2 pointers difference, cast it to uint by min_t in
both cases.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: mxser_new, ioaddresses are ulong
Jiri Slaby [Thu, 7 Feb 2008 08:16:35 +0000 (00:16 -0800)] 
Char: mxser_new, ioaddresses are ulong

To not pass ulong address as int parameter, switch it to ulong.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: char/serial, remove SERIAL_TYPE_NORMAL redefines
Jiri Slaby [Thu, 7 Feb 2008 08:16:34 +0000 (00:16 -0800)] 
Char: char/serial, remove SERIAL_TYPE_NORMAL redefines

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: rocket, remove useless macros
Jiri Slaby [Thu, 7 Feb 2008 08:16:33 +0000 (00:16 -0800)] 
Char: rocket, remove useless macros

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Acked-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: rocket, printk cleanup
Jiri Slaby [Thu, 7 Feb 2008 08:16:33 +0000 (00:16 -0800)] 
Char: rocket, printk cleanup

- add KERN_ level to each print
- change some levels appropriately
- add \n at the ends where missing
- change two complex printks into dev_info, where the original info is
  printed automatically

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoChar: rocket, switch long delay to sleep
Jiri Slaby [Thu, 7 Feb 2008 08:16:32 +0000 (00:16 -0800)] 
Char: rocket, switch long delay to sleep

Don't busy wait for whole 1s when registering some rocket modems. Sleep
instead since we are not in atomic.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoi8k: Inspiron E1705 fix
Frank Sorenson [Thu, 7 Feb 2008 08:16:31 +0000 (00:16 -0800)] 
i8k: Inspiron E1705 fix

Needs the following in order to work correctly on my Inspiron E1705:

Add DMI Product name to i8k for Dell MP061 hardware (Inspiron 9400/E1705)

Signed-off-by: Frank Sorenson <frank@tuxrocks.com>
Cc: Bradley Smith <bradjsmith@btinternet.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoI8K: add i8k driver to the x86_64 Kconfig
Bradley Smith [Thu, 7 Feb 2008 08:16:30 +0000 (00:16 -0800)] 
I8K: add i8k driver to the x86_64 Kconfig

Adds i8k driver to the x86_64 Kconfig.

Signed-off-by: Bradley Smith <bradjsmith@btinternet.com>
Cc: Frank Sorenson <frank@tuxrocks.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoI8K: allow i8k driver to be built on x86_64 systems
Bradley Smith [Thu, 7 Feb 2008 08:16:27 +0000 (00:16 -0800)] 
I8K: allow i8k driver to be built on x86_64 systems

Adds #if clause and additional inline assembly so that the driver
builds on x86_64 systems.

Signed-off-by: Bradley Smith <bradjsmith@btinternet.com>
Cc: Frank Sorenson <frank@tuxrocks.com>
Cc: Jeff Garzik <jeff@garzik.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoAdd cmpxchg_local to xtensa
Mathieu Desnoyers [Thu, 7 Feb 2008 08:16:26 +0000 (00:16 -0800)] 
Add cmpxchg_local to xtensa

Use the architecture specific __cmpxchg_u32 for 32 bits cmpxchg)_local. Else,
use the new generic cmpxchg_local (disables interrupt).

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: Chris Zankel <chris@zankel.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoAdd cmpxchg_local to v850
Mathieu Desnoyers [Thu, 7 Feb 2008 08:16:26 +0000 (00:16 -0800)] 
Add cmpxchg_local to v850

Use the new generic cmpxchg_local (disables interrupt). Also use the generic
cmpxchg as fallback if SMP is not set.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: Miles Bader <miles.bader@necel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoAdd cmpxchg_local to sparc64
Mathieu Desnoyers [Thu, 7 Feb 2008 08:16:25 +0000 (00:16 -0800)] 
Add cmpxchg_local to sparc64

Use cmpxchg_u32 and cmpxchg_u64 for cmpxchg_local and cmpxchg64_local. For other
type sizes, use the new generic cmpxchg_local (disables interrupt).

Change:
Since the header depends on local_irqsave/local_irqrestore, it must be
included after their declaration.

Actually, being below the
#include <linux/irqflags.h> should be enough, and on sparc64 it is
included at the beginning of system.h.

So it makes sense to move it up for sparc64.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoAdd cmpxchg_local to sparc, move __cmpxchg to system.h
Mathieu Desnoyers [Thu, 7 Feb 2008 08:16:24 +0000 (00:16 -0800)] 
Add cmpxchg_local to sparc, move __cmpxchg to system.h

Move cmpxchg and add cmpxchg_local to system.h.
Use the new generic cmpxchg_local (disables interrupt).

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: William Lee Irwin III <wli@holomorphy.com>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoAdd cmpxchg_local to s390
Mathieu Desnoyers [Thu, 7 Feb 2008 08:16:24 +0000 (00:16 -0800)] 
Add cmpxchg_local to s390

Use the standard __cmpxchg for every type that can be updated atomically.
Use the new generic cmpxchg_local (disables interrupt) for other types.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoAdd cmpxchg_local to ppc
Gunnar Larisch [Thu, 7 Feb 2008 08:16:22 +0000 (00:16 -0800)] 
Add cmpxchg_local to ppc

Add a local processor version of cmpxchg for ppc.

Implements __cmpxchg_u32_local and uses it for 32 bits cmpxchg_local.
It uses the non NMI safe cmpxchg_local_generic for 1, 2 and 8 bytes
cmpxchg_local.

Signed-off-by: Gunnar Larisch <gl@denx.de>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Kumar Gala <galak@gate.crashing.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoAdd cmpxchg_local to parisc
Mathieu Desnoyers [Thu, 7 Feb 2008 08:16:21 +0000 (00:16 -0800)] 
Add cmpxchg_local to parisc

Use the new generic cmpxchg_local (disables interrupt). Also use the generic
cmpxchg as fallback if SMP is not set.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: Kyle McMartin <kyle@mcmartin.ca>
Cc: Grant Grundler <grundler@parisc-linux.org>
Cc: Matthew Wilcox <willy@debian.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>