<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/hwmon/fschmd.c, branch linux-3.2.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.2.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.2.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2011-01-12T20:55:11Z</updated>
<entry>
<title>hwmon: (fschmd) Drop useless mutex</title>
<updated>2011-01-12T20:55:11Z</updated>
<author>
<name>Jean Delvare</name>
</author>
<published>2011-01-12T20:55:11Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=1b7243e8f51157103dcca33236163a191c8afd01'/>
<id>urn:sha1:1b7243e8f51157103dcca33236163a191c8afd01</id>
<content type='text'>
As discussed one year ago, the WDIOC_GETSUPPORT ioctl only needs a
mutex because it operates on a static variable. There is no good
reason to keep this variable static, so let's just make it non-static
and drop the now useless mutex altogether.

See the discussion at:
http://marc.info/?l=lm-sensors&amp;m=125563869402323&amp;w=2

Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
Cc: Hans de Goede &lt;hdegoede@redhat.com&gt;
Acked-by: Guenter Roeck &lt;guenter.roeck@ericsson.com&gt;
Acked-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Acked-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
</content>
</entry>
<entry>
<title>drivers: autoconvert trivial BKL users to private mutex</title>
<updated>2010-10-05T13:01:04Z</updated>
<author>
<name>Arnd Bergmann</name>
</author>
<published>2010-06-02T12:28:52Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=613655fa39ff6957754fa8ceb8559980920eb8ee'/>
<id>urn:sha1:613655fa39ff6957754fa8ceb8559980920eb8ee</id>
<content type='text'>
All these files use the big kernel lock in a trivial
way to serialize their private file operations,
typically resulting from an earlier semi-automatic
pushdown from VFS.

None of these drivers appears to want to lock against
other code, and they all use the BKL as the top-level
lock in their file operations, meaning that there
is no lock-order inversion problem.

Consequently, we can remove the BKL completely,
replacing it with a per-file mutex in every case.
Using a scripted approach means we can avoid
typos.

These drivers do not seem to be under active
maintainance from my brief investigation. Apologies
to those maintainers that I have missed.

file=$1
name=$2
if grep -q lock_kernel ${file} ; then
    if grep -q 'include.*linux.mutex.h' ${file} ; then
            sed -i '/include.*&lt;linux\/smp_lock.h&gt;/d' ${file}
    else
            sed -i 's/include.*&lt;linux\/smp_lock.h&gt;.*$/include &lt;linux\/mutex.h&gt;/g' ${file}
    fi
    sed -i ${file} \
        -e "/^#include.*linux.mutex.h/,$ {
                1,/^\(static\|int\|long\)/ {
                     /^\(static\|int\|long\)/istatic DEFINE_MUTEX(${name}_mutex);

} }"  \
    -e "s/\(un\)*lock_kernel\&gt;[ ]*()/mutex_\1lock(\&amp;${name}_mutex)/g" \
    -e '/[      ]*cycle_kernel_lock();/d'
else
    sed -i -e '/include.*\&lt;smp_lock.h\&gt;/d' ${file}  \
                -e '/cycle_kernel_lock()/d'
fi

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
</content>
</entry>
<entry>
<title>drivers: Push down BKL into various drivers</title>
<updated>2010-05-17T03:27:41Z</updated>
<author>
<name>Arnd Bergmann</name>
</author>
<published>2010-04-26T22:24:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=55929332c92e5d34d65a8f784604c92677ea3e15'/>
<id>urn:sha1:55929332c92e5d34d65a8f784604c92677ea3e15</id>
<content type='text'>
These are the last remaining device drivers using
the -&gt;ioctl file operation in the drivers directory
(except from v4l drivers).

[fweisbec: drop i8k pushdown as it has been done from
procfs pushdown branch already]

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Frederic Weisbecker &lt;fweisbec@gmail.com&gt;
</content>
</entry>
<entry>
<title>hwmon: Fix off-by-one kind values</title>
<updated>2010-03-05T21:17:26Z</updated>
<author>
<name>Jean Delvare</name>
</author>
<published>2010-03-05T21:17:26Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=dc71afe5ac7e8d049bb991330518e4c898a7d92e'/>
<id>urn:sha1:dc71afe5ac7e8d049bb991330518e4c898a7d92e</id>
<content type='text'>
Recent changes on the I2C front have left off-by-one array indexes in
3 hwmon drivers. Fix them.

Faulty commit:
e5e9f44c2 i2c: Drop I2C_CLIENT_INSMOD_2 to 8

Reported-by: Dan Carpenter &lt;error27@gmail.com&gt;
Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
Cc: Hans de Goede &lt;hdegoede@redhat.com&gt;
Cc: Andre Prendel &lt;andre.prendel@gmx.de&gt;
Cc: stable@kernel.org
</content>
</entry>
<entry>
<title>hwmon: (fschmd) Fix a memleak on multiple opens of /dev/watchdog</title>
<updated>2010-01-25T14:00:50Z</updated>
<author>
<name>Hans de Goede</name>
</author>
<published>2010-01-25T14:00:50Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c453615f77aa51593c1c9c9031b4278797d3fd19'/>
<id>urn:sha1:c453615f77aa51593c1c9c9031b4278797d3fd19</id>
<content type='text'>
When /dev/watchdog gets opened a second time we return -EBUSY, but
we already have got a kref then, so we end up leaking our data struct.

Signed-off-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
Cc: stable@kernel.org
</content>
</entry>
<entry>
<title>i2c: Drop I2C_CLIENT_INSMOD_2 to 8</title>
<updated>2009-12-14T20:17:27Z</updated>
<author>
<name>Jean Delvare</name>
</author>
<published>2009-12-14T20:17:27Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e5e9f44c246fbafe723e579e9fe887677beb40e4'/>
<id>urn:sha1:e5e9f44c246fbafe723e579e9fe887677beb40e4</id>
<content type='text'>
These macros simply declare an enum, so drivers might as well declare
it themselves. This puts an end to the arbitrary limit of 8 chip types
per i2c driver.

Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
Tested-by: Wolfram Sang &lt;w.sang@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>i2c: Get rid of struct i2c_client_address_data</title>
<updated>2009-12-14T20:17:25Z</updated>
<author>
<name>Jean Delvare</name>
</author>
<published>2009-12-14T20:17:25Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c3813d6af177fab19e322f3114b1f64fbcf08d71'/>
<id>urn:sha1:c3813d6af177fab19e322f3114b1f64fbcf08d71</id>
<content type='text'>
Struct i2c_client_address_data only contains one field at this point,
which makes its usefulness questionable. Get rid of it and pass simple
address lists around instead.

Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
Tested-by: Wolfram Sang &lt;w.sang@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>i2c: Drop the kind parameter from detect callbacks</title>
<updated>2009-12-14T20:17:23Z</updated>
<author>
<name>Jean Delvare</name>
</author>
<published>2009-12-14T20:17:23Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=310ec79210d754afe51e2e4a983e846b60179abd'/>
<id>urn:sha1:310ec79210d754afe51e2e4a983e846b60179abd</id>
<content type='text'>
The "kind" parameter always has value -1, and nobody is using it any
longer, so we can remove it.

Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
Tested-by: Wolfram Sang &lt;w.sang@pengutronix.de&gt;
</content>
</entry>
<entry>
<title>hwmon: Clean up detect functions</title>
<updated>2009-12-09T19:35:57Z</updated>
<author>
<name>Jean Delvare</name>
</author>
<published>2009-12-09T19:35:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=52df6440a29123eed912183fe785bbe174ef14b9'/>
<id>urn:sha1:52df6440a29123eed912183fe785bbe174ef14b9</id>
<content type='text'>
As kind is now hard-coded to -1, there is room for code clean-ups.

Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
Acked-by: Corentin Labbe &lt;corentin.labbe@geomatys.fr&gt;
Cc: "Mark M. Hoffman" &lt;mhoffman@lightlink.com&gt;
Cc: Juerg Haefliger &lt;juergh@gmail.com&gt;
Cc: Riku Voipio &lt;riku.voipio@iki.fi&gt;
Acked-by: "Hans J. Koch" &lt;hjk@linutronix.de&gt;
Cc: Rudolf Marek &lt;r.marek@assembler.cz&gt;
</content>
</entry>
<entry>
<title>hwmon: (fschmd) Fix check on unsigned in watchdog_write()</title>
<updated>2009-10-24T11:28:45Z</updated>
<author>
<name>Roel Kluin</name>
</author>
<published>2009-10-24T11:28:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c7702c31340f84cfd5e5df22293578b7ae1e9370'/>
<id>urn:sha1:c7702c31340f84cfd5e5df22293578b7ae1e9370</id>
<content type='text'>
If unsigned the watchdog_trigger() return value will not be
checked correctly.

Signed-off-by: Roel Kluin &lt;roel.kluin@gmail.com&gt;
Acked-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Cc: Hans de Goede &lt;hdegoede@redhat.com&gt;
Signed-off-by: Jean Delvare &lt;khali@linux-fr.org&gt;
</content>
</entry>
</feed>
