<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/base/sys.c, branch v2.6.28</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v2.6.28</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v2.6.28'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2008-10-29T22:03:49Z</updated>
<entry>
<title>sysfs: Fix return values for sysdev_store_{ulong,int}</title>
<updated>2008-10-29T22:03:49Z</updated>
<author>
<name>Andi Kleen</name>
<email>andi@firstfloor.org</email>
</author>
<published>2008-10-13T10:03:03Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=4e318d7c6c9dd5cdae48bcf61558bbc0c09b12ac'/>
<id>urn:sha1:4e318d7c6c9dd5cdae48bcf61558bbc0c09b12ac</id>
<content type='text'>
SYSFS: Fix return values for sysdev_store_{ulong,int}

Always return the full size instead of the consumed
length of the string in sysdev_store_{ulong,int}

This avoids EINVAL errors in some echo versions.

Signed-off-by: Andi Kleen &lt;ak@linux.intel.com&gt;
Cc: stable &lt;stable@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>driver core: drivers/base/sys.c: update comments</title>
<updated>2008-10-29T22:03:49Z</updated>
<author>
<name>Qinghuang Feng</name>
<email>s3c24xx@gmail.com</email>
</author>
<published>2008-10-13T10:05:04Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=65151365ad59af00e229d0fe33b4f1f9350c685f'/>
<id>urn:sha1:65151365ad59af00e229d0fe33b4f1f9350c685f</id>
<content type='text'>
There are no functions named sys_device_shutdown or sys_device_suspend
in the kernel.
They should be fixed to sysdev_shutdown and sysdev_suspend respectively.

Signed-off-by: Qinghuang Feng &lt;qhfeng.kernel@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>Use WARN() in drivers/base/</title>
<updated>2008-07-26T19:00:07Z</updated>
<author>
<name>Arjan van de Ven</name>
<email>arjan@linux.intel.com</email>
</author>
<published>2008-07-26T02:45:39Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=f810a5cf28a818db96333cd23646f0227ec015b4'/>
<id>urn:sha1:f810a5cf28a818db96333cd23646f0227ec015b4</id>
<content type='text'>
Use WARN() instead of a printk+WARN_ON() pair; this way the message
becomes part of the warning section for better reporting/collection.

Signed-off-by: Arjan van de Ven &lt;arjan@linux.intel.com&gt;
Cc: Greg KH &lt;greg@kroah.com&gt;
Cc: Kay Sievers &lt;kay.sievers@vrfy.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>sysdev: Add utility functions for simple int/ulong variable sysdev attributes</title>
<updated>2008-07-22T04:55:02Z</updated>
<author>
<name>Andi Kleen</name>
<email>andi@firstfloor.org</email>
</author>
<published>2008-07-01T16:48:42Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=9800794ac11d4646384b3a310dfd1fe2eed577bf'/>
<id>urn:sha1:9800794ac11d4646384b3a310dfd1fe2eed577bf</id>
<content type='text'>
This adds a new sysdev_ext_attribute that stores a pointer to the variable
it manages and some utility functions/macro to easily use them.

Previously all users wrote custom macros to generate show/store
functions for each variable, with this it is possible to avoid
that in many cases.

Signed-off-by: Andi Kleen &lt;ak@linux.intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>sysdev: Pass the attribute to the low level sysdev show/store function</title>
<updated>2008-07-22T04:55:02Z</updated>
<author>
<name>Andi Kleen</name>
<email>andi@firstfloor.org</email>
</author>
<published>2008-07-01T16:48:41Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=4a0b2b4dbe1335b8b9886ba3dc85a145d5d938ed'/>
<id>urn:sha1:4a0b2b4dbe1335b8b9886ba3dc85a145d5d938ed</id>
<content type='text'>
This allow to dynamically generate attributes and share show/store
functions between attributes. Right now most attributes are generated
by special macros and lots of duplicated code. With the attribute
passed it's instead possible to attach some data to the attribute
and then use that in shared low level functions to do different things.

I need this for the dynamically generated bank attributes in the x86
machine check code, but it'll allow some further cleanups.

I converted all users in tree to the new show/store prototype. It's a single
huge patch to avoid unbisectable sections.

Runtime tested: x86-32, x86-64
Compiled only: ia64, powerpc
Not compile tested/only grep converted: sh, arm, avr32

Signed-off-by: Andi Kleen &lt;ak@linux.intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>sysdev: fix debugging statements in registration code.</title>
<updated>2008-07-22T04:54:56Z</updated>
<author>
<name>Ben Dooks</name>
<email>ben-linux@fluff.org</email>
</author>
<published>2008-06-12T18:00:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=838ea8e8dbfc8d907c7a55bbad507a44c1b81d57'/>
<id>urn:sha1:838ea8e8dbfc8d907c7a55bbad507a44c1b81d57</id>
<content type='text'>
The systdev_class_register() and sysdev_register() functions have
pr_debug() statements which are enabled when the user selects the
driver core debug. Both of these routines do not produce the
correct output, as they make assumptions about data which has not
been initialised.

In sysdev_class_register() the code uses the kobject_name(&amp;cls-&gt;kset.kobj)
at the start of the function, but this is not setup until later in the
same call. Change this to use cls-&gt;name which is passed in from the caller.

The sysdev_register() function tries to get the name of the sysdev by
kobject_name(&amp;sysdev-&gt;kobj), but that isn't setup until later in the same
function so change this message to use the name of the sysdev's class and
add another message once the name is initialised.

Signed-off-by: Ben Dooks &lt;ben-linux@fluff.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>Fix bogus warning in sysdev_driver_register()</title>
<updated>2008-05-06T20:22:42Z</updated>
<author>
<name>OGAWA Hirofumi</name>
<email>hirofumi@mail.parknet.co.jp</email>
</author>
<published>2008-05-06T19:02:53Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=db176c6ed8974fae94328ad5ac9e70b094ff22fd'/>
<id>urn:sha1:db176c6ed8974fae94328ad5ac9e70b094ff22fd</id>
<content type='text'>
        if ((drv-&gt;entry.next != drv-&gt;entry.prev) ||
            (drv-&gt;entry.next != NULL)) {

warns list_empty(&amp;drv-&gt;entry).

Signed-off-by: OGAWA Hirofumi &lt;hirofumi@mail.parknet.co.jp&gt;
Cc: Greg KH &lt;gregkh@suse.de&gt;
Cc: Len Brown &lt;lenb@kernel.org&gt;
[ Version 2 totally redone based on suggestions from Linus &amp; Greg ]
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>driver core: replace remaining __FUNCTION__ occurrences</title>
<updated>2008-04-20T02:10:29Z</updated>
<author>
<name>Harvey Harrison</name>
<email>harvey.harrison@gmail.com</email>
</author>
<published>2008-03-05T00:41:05Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=2b3a302a09735276e13421db56c20045a48eb06d'/>
<id>urn:sha1:2b3a302a09735276e13421db56c20045a48eb06d</id>
<content type='text'>
__FUNCTION__ is gcc-specific, use __func__

Signed-off-by: Harvey Harrison &lt;harvey.harrison@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>sysdev: detect multiple driver registrations</title>
<updated>2008-04-20T02:10:24Z</updated>
<author>
<name>Ben Dooks</name>
<email>ben@fluff.org</email>
</author>
<published>2008-03-04T23:09:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=da009f39f85a3ee9deeb10f0f05ddd4efdd67020'/>
<id>urn:sha1:da009f39f85a3ee9deeb10f0f05ddd4efdd67020</id>
<content type='text'>
I've just found how easy it is to accidentally register a sysdev_driver for
two different classes.  When this happens, bad things happen as the
sysdev_driver structure keeps has the list entry for the driver
registration.

The following patch makes a WARN_ON() if this happens, although I think
BUG_ON or returning -EAGAIN could also be valid responses to this.

Signed-off-by: Ben Dooks &lt;ben@fluff.org&gt;
Cc: Kay Sievers &lt;kay.sievers@vrfy.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>sysdev: fix problem with sysdev_class being re-registered</title>
<updated>2008-03-10T23:33:32Z</updated>
<author>
<name>Greg Kroah-Hartman</name>
<email>gregkh@suse.de</email>
</author>
<published>2008-03-08T22:07:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ef79df263062fd04fe9db4ee1b9f014a87a8e924'/>
<id>urn:sha1:ef79df263062fd04fe9db4ee1b9f014a87a8e924</id>
<content type='text'>
We need to initialize the kobject for a sysdev_class as it could have
been recycled (stupid static kobjects...)

We also do the same thing in case sysdev devices are being
re-registered.

Thanks to Balaji Rao &lt;balajirrao@gmail.com&gt; for pointing out the
problem.

Signed-off-by: Balaji Rao &lt;balajirrao@gmail.com&gt;
Tested-by: Mikael Pettersson &lt;mikpe@it.uu.se&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
</feed>
