<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/base/bus.c, branch v2.6.19</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/drivers/base/bus.c?h=v2.6.19</id>
<link rel='self' href='https://git.amat.us/linux/atom/drivers/base/bus.c?h=v2.6.19'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2006-10-18T19:49:56Z</updated>
<entry>
<title>Driver core: bus: remove indentation level</title>
<updated>2006-10-18T19:49:56Z</updated>
<author>
<name>Jeff Garzik</name>
<email>jeff@garzik.org</email>
</author>
<published>2006-10-04T11:48:03Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=d9fd4d3b317a231e47f31d64d66c8cc7765d458f'/>
<id>urn:sha1:d9fd4d3b317a231e47f31d64d66c8cc7765d458f</id>
<content type='text'>
Before potentially fixing up these functions, this cosmetic change
reduces the indentation level to make the code easier to read and
maintain.

No functional changes at all.

Signed-off-by: Jeff Garzik &lt;jeff@garzik.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>Driver core: Don't ignore error returns from probing</title>
<updated>2006-10-18T19:49:55Z</updated>
<author>
<name>Alan Stern</name>
<email>stern@rowland.harvard.edu</email>
</author>
<published>2006-10-05T21:03:24Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=f70fa6296c2ec8f541f0a9b406ccc2d9d127d639'/>
<id>urn:sha1:f70fa6296c2ec8f541f0a9b406ccc2d9d127d639</id>
<content type='text'>
This patch (as797) fixes device_add() in the driver core.  It needs to
pay attention when the driver for a new device reports an error.

At the same time, since bus_remove_device() undoes the effects of both
bus_add_device() and bus_attach_device(), it needs to check whether
the bus_attach_device step failed.

Signed-off-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>driver core fixes: bus_add_device() cleanup on error</title>
<updated>2006-10-18T19:49:55Z</updated>
<author>
<name>Cornelia Huck</name>
<email>cornelia.huck@de.ibm.com</email>
</author>
<published>2006-09-22T09:37:08Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=513e7337adc32cdfbffecb99953e45a44e812c2d'/>
<id>urn:sha1:513e7337adc32cdfbffecb99953e45a44e812c2d</id>
<content type='text'>
Correct cleanup in the error path of bus_add_device().

Signed-off-by: Cornelia Huck &lt;cornelia.huck@de.ibm.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;


</content>
</entry>
<entry>
<title>driver core fixes: bus_add_attrs() retval check</title>
<updated>2006-10-18T19:49:55Z</updated>
<author>
<name>Cornelia Huck</name>
<email>cornelia.huck@de.ibm.com</email>
</author>
<published>2006-09-22T09:37:04Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=1bb6881acae1c4f11a6e86f04df32ba45e95031d'/>
<id>urn:sha1:1bb6881acae1c4f11a6e86f04df32ba45e95031d</id>
<content type='text'>
Check return value of bus_add_attrs() in bus_register().

Signed-off-by: Cornelia Huck &lt;cornelia.huck@de.ibm.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;


</content>
</entry>
<entry>
<title>Driver core: Remove unneeded routines from driver core</title>
<updated>2006-09-26T04:08:40Z</updated>
<author>
<name>Alan Stern</name>
<email>stern@rowland.harvard.edu</email>
</author>
<published>2006-09-18T20:24:28Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=81107bf531d2524afbcd61f3b4ad57a71295d591'/>
<id>urn:sha1:81107bf531d2524afbcd61f3b4ad57a71295d591</id>
<content type='text'>
This patch (as783) simplifies the driver core slightly by removing four
unnecessary _get and _put methods.

It is vital that when a driver is removed from its bus's klist of
registered drivers, or when a device is removed from a driver's klist
of bound devices, that the klist updates complete synchronously.
Otherwise the kernel might try binding an unregistered driver to a
newly-registered device, or adding a device to the klist for a new
driver before it has been removed from the old driver's klist.

Since the removals must be synchronous, they don't need to update any
reference counts.  Hence the _get and _put methods can be dispensed
with.

Signed-off-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>Driver core: Fix potential deadlock in driver core</title>
<updated>2006-09-26T04:08:40Z</updated>
<author>
<name>Alan Stern</name>
<email>stern@rowland.harvard.edu</email>
</author>
<published>2006-09-18T20:22:34Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=f2eaae197f4590c4d96f31b09b0ee9067421a95c'/>
<id>urn:sha1:f2eaae197f4590c4d96f31b09b0ee9067421a95c</id>
<content type='text'>
There is a potential deadlock in the driver core.  It boils down to
the fact that bus_remove_device() calls klist_remove() instead of
klist_del(), thereby waiting until the reference count of the
klist_node in the bus's klist of devices drops to 0.  The refcount
can't reach 0 so long as a modprobe process is trying to bind a new
driver to the device being removed, by calling __driver_attach().  The
problem is that __driver_attach() tries to acquire the device's
parent's semaphore, but the caller of bus_remove_device() is quite
likely to own that semaphore already.

It isn't sufficient just to replace klist_remove() with klist_del().
Doing so runs the risk that the device would remain on the bus's klist
of devices for some time, and so could be bound to another driver even
after it was unregistered.  What's needed is a new way to distinguish
whether or not a device is registered, based on a criterion other than
whether its klist_node is linked into the bus's klist of devices.  That
way driver binding can fail when the device is unregistered, even if
it is still linked into the klist.

This patch (as782) implements the solution, by adding a new bitflag to
indiate when a struct device is registered, by testing the flag before
allowing a driver to bind a device, and by changing the definition of
the device_is_registered() inline.

Signed-off-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>drivers/base: check errors</title>
<updated>2006-09-26T04:08:39Z</updated>
<author>
<name>Andrew Morton</name>
<email>akpm@osdl.org</email>
</author>
<published>2006-08-15T05:43:20Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=f86db396ff455ed586751d21816a1ebd431264e5'/>
<id>urn:sha1:f86db396ff455ed586751d21816a1ebd431264e5</id>
<content type='text'>
Add lots of return-value checking.

&lt;pcornelia.huck@de.ibm.com&gt;: fix bus_rescan_devices()]
Cc: "Randy.Dunlap" &lt;rdunlap@xenotime.net&gt;
Signed-off-by: Cornelia Huck &lt;cornelia.huck@de.ibm.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@osdl.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>Driver core: fixed add_bind_files() definition</title>
<updated>2006-09-26T04:08:39Z</updated>
<author>
<name>Yoichi Yuasa</name>
<email>yoichi_yuasa@tripeaks.co.jp</email>
</author>
<published>2006-07-14T16:30:11Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=35acfdd7253025e8441883fd8f879f5240844f95'/>
<id>urn:sha1:35acfdd7253025e8441883fd8f879f5240844f95</id>
<content type='text'>
When CONFIG_HOTPLUG is n, add_bind_files() definition is wrong.
This patch has fixed it.

Signed-off-by: Yoichi Yuasa &lt;yoichi_yuasa@tripeaks.co.jp&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>[PATCH] Driver core: bus.c cleanups</title>
<updated>2006-07-12T23:09:08Z</updated>
<author>
<name>Adrian Bunk</name>
<email>bunk@stusta.de</email>
</author>
<published>2006-06-26T20:26:56Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=7e4ef085ea4b00cfc34e854edf448c729de8a0a5'/>
<id>urn:sha1:7e4ef085ea4b00cfc34e854edf448c729de8a0a5</id>
<content type='text'>
This patch contains the following cleanups:
- make the needlessly global bus_subsys static
- #if 0 the unused find_bus()

Signed-off-by: Adrian Bunk &lt;bunk@stusta.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
<entry>
<title>Remove obsolete #include &lt;linux/config.h&gt;</title>
<updated>2006-06-30T17:25:36Z</updated>
<author>
<name>Jörn Engel</name>
<email>joern@wohnheim.fh-wedel.de</email>
</author>
<published>2006-06-30T17:25:36Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=6ab3d5624e172c553004ecc862bfeac16d9d68b7'/>
<id>urn:sha1:6ab3d5624e172c553004ecc862bfeac16d9d68b7</id>
<content type='text'>
Signed-off-by: Jörn Engel &lt;joern@wohnheim.fh-wedel.de&gt;
Signed-off-by: Adrian Bunk &lt;bunk@stusta.de&gt;
</content>
</entry>
</feed>
