<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/net/wireless/p54, branch linux-4.4.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.4.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.4.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2020-01-23T07:18:35Z</updated>
<entry>
<title>p54usb: Fix race between disconnect and firmware loading</title>
<updated>2020-01-23T07:18:35Z</updated>
<author>
<name>Alan Stern</name>
</author>
<published>2019-05-20T14:44:21Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e2c48c1e6ef5e806b68ca685216dda05e5267be2'/>
<id>urn:sha1:e2c48c1e6ef5e806b68ca685216dda05e5267be2</id>
<content type='text'>
commit 6e41e2257f1094acc37618bf6c856115374c6922 upstream.

The syzbot fuzzer found a bug in the p54 USB wireless driver.  The
issue involves a race between disconnect and the firmware-loader
callback routine, and it has several aspects.

One big problem is that when the firmware can't be loaded, the
callback routine tries to unbind the driver from the USB _device_ (by
calling device_release_driver) instead of from the USB _interface_ to
which it is actually bound (by calling usb_driver_release_interface).

The race involves access to the private data structure.  The driver's
disconnect handler waits for a completion that is signalled by the
firmware-loader callback routine.  As soon as the completion is
signalled, you have to assume that the private data structure may have
been deallocated by the disconnect handler -- even if the firmware was
loaded without errors.  However, the callback routine does access the
private data several times after that point.

Another problem is that, in order to ensure that the USB device
structure hasn't been freed when the callback routine runs, the driver
takes a reference to it.  This isn't good enough any more, because now
that the callback routine calls usb_driver_release_interface, it has
to ensure that the interface structure hasn't been freed.

Finally, the driver takes an unnecessary reference to the USB device
structure in the probe function and drops the reference in the
disconnect handler.  This extra reference doesn't accomplish anything,
because the USB core already guarantees that a device structure won't
be deallocated while a driver is still bound to any of its interfaces.

To fix these problems, this patch makes the following changes:

	Call usb_driver_release_interface() rather than
	device_release_driver().

	Don't signal the completion until after the important
	information has been copied out of the private data structure,
	and don't refer to the private data at all thereafter.

	Lock udev (the interface's parent) before unbinding the driver
	instead of locking udev-&gt;parent.

	During the firmware loading process, take a reference to the
	USB interface instead of the USB device.

	Don't take an unnecessary reference to the device during probe
	(and then don't drop it during disconnect).

Signed-off-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Reported-and-tested-by: syzbot+200d4bb11b23d929335f@syzkaller.appspotmail.com
Acked-by: Christian Lamparter &lt;chunkeey@gmail.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
[bwh: Backported to 4.4: adjust filename]
Signed-off-by: Ben Hutchings &lt;ben.hutchings@codethink.co.uk&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>p54: memset(0) whole array</title>
<updated>2017-09-02T05:06:51Z</updated>
<author>
<name>Jiri Slaby</name>
</author>
<published>2016-10-14T09:23:09Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=389328ea1379e14e8bd8678af96d7a83bc1514e5'/>
<id>urn:sha1:389328ea1379e14e8bd8678af96d7a83bc1514e5</id>
<content type='text'>
commit 6f17581788206444cbbcdbc107498f85e9765e3d upstream.

gcc 7 complains:
drivers/net/wireless/intersil/p54/fwio.c: In function 'p54_scan':
drivers/net/wireless/intersil/p54/fwio.c:491:4: warning: 'memset' used with length equal to number of elements without multiplication by element size [-Wmemset-elt-size]

Fix that by passing the correct size to memset.

Signed-off-by: Jiri Slaby &lt;jslaby@suse.cz&gt;
Cc: Christian Lamparter &lt;chunkeey@googlemail.com&gt;
Cc: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Acked-by: Christian Lamparter &lt;chunkeey@googlemail.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>spi: Drop owner assignment from spi_drivers</title>
<updated>2015-10-28T01:30:17Z</updated>
<author>
<name>Andrew F. Davis</name>
</author>
<published>2015-10-23T13:59:11Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3821a065f5672c430a088ae68b4da2a2d2b34106'/>
<id>urn:sha1:3821a065f5672c430a088ae68b4da2a2d2b34106</id>
<content type='text'>
An spi_driver does not need to set an owner, it will be populated by the
driver core.

Signed-off-by: Andrew F. Davis &lt;afd@ti.com&gt;
Acked-by: Jonathan Cameron &lt;jic23@kernel.org&gt;
Signed-off-by: Mark Brown &lt;broonie@kernel.org&gt;
</content>
</entry>
<entry>
<title>mac80211: convert HW flags to unsigned long bitmap</title>
<updated>2015-06-10T14:05:36Z</updated>
<author>
<name>Johannes Berg</name>
</author>
<published>2015-06-02T19:39:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=30686bf7f5b3c30831761e188a6e3cb33580fa48'/>
<id>urn:sha1:30686bf7f5b3c30831761e188a6e3cb33580fa48</id>
<content type='text'>
As we're running out of hardware capability flags pretty quickly,
convert them to use the regular test_bit() style unsigned long
bitmaps.

This introduces a number of helper functions/macros to set and to
test the bits, along with new debugfs code.

The occurrences of an explicit __clear_bit() are intentional, the
drivers were never supposed to change their supported bits on the
fly. We should investigate changing this to be a per-frame flag.

Signed-off-by: Johannes Berg &lt;johannes.berg@intel.com&gt;
</content>
</entry>
<entry>
<title>mac80211: make LED trigger names const</title>
<updated>2015-05-05T12:21:55Z</updated>
<author>
<name>Johannes Berg</name>
</author>
<published>2015-04-23T10:09:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f5c4ae07992ca64d8628a11439c184baf5595e4b'/>
<id>urn:sha1:f5c4ae07992ca64d8628a11439c184baf5595e4b</id>
<content type='text'>
This is just a code cleanup, make the LED trigger names const
as they're not expected to be modified by drivers.

Signed-off-by: Johannes Berg &lt;johannes.berg@intel.com&gt;
</content>
</entry>
<entry>
<title>mac80211: remove support for IFF_PROMISC</title>
<updated>2015-04-24T09:14:13Z</updated>
<author>
<name>Johannes Berg</name>
</author>
<published>2015-04-22T12:40:58Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=df1404650ccbfeb76a84f301f22316be0d00a864'/>
<id>urn:sha1:df1404650ccbfeb76a84f301f22316be0d00a864</id>
<content type='text'>
This support is essentially useless as typically networks are encrypted,
frames will be filtered by hardware, and rate scaling will be done with
the intended recipient in mind. For real monitoring of the network, the
monitor mode support should be used instead.

Removing it removes a lot of corner cases.

Signed-off-by: Johannes Berg &lt;johannes.berg@intel.com&gt;
</content>
</entry>
<entry>
<title>wireless: Use eth_&lt;foo&gt;_addr instead of memset</title>
<updated>2015-03-03T22:01:36Z</updated>
<author>
<name>Joe Perches</name>
</author>
<published>2015-03-03T03:54:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=93803b3385c653bc6fd391c0de00ef811b3dadc0'/>
<id>urn:sha1:93803b3385c653bc6fd391c0de00ef811b3dadc0</id>
<content type='text'>
Use the built-in function instead of memset.

Miscellanea:

Add #include &lt;linux/etherdevice.h&gt; where appropriate
Use ETH_ALEN instead of 6

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>p54pci: add handling of signal case</title>
<updated>2015-01-23T19:37:04Z</updated>
<author>
<name>Nicholas Mc Guire</name>
</author>
<published>2015-01-20T05:26:17Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=961d1bbecf33de0321cc59f0ea16dd517ecbf3fb'/>
<id>urn:sha1:961d1bbecf33de0321cc59f0ea16dd517ecbf3fb</id>
<content type='text'>
if(!wait_for_completion_interruptible_timeout(...))
only handles the timeout case - this patch adds handling the
signal case the same as timeout.

Signed-off-by: Nicholas Mc Guire &lt;der.herr@hofr.at&gt;
Acked-by: Christian Lamparter &lt;chunkeey@googlemail.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
</content>
</entry>
<entry>
<title>p54: add handling of the signal case</title>
<updated>2015-01-23T19:33:42Z</updated>
<author>
<name>Nicholas Mc Guire</name>
</author>
<published>2015-01-20T05:25:43Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5b4c6b4f0b2778351c5bef74888a5fbdfbdd0ef5'/>
<id>urn:sha1:5b4c6b4f0b2778351c5bef74888a5fbdfbdd0ef5</id>
<content type='text'>
if(!wait_for_completion_interruptible_timeout(...))
only handles the timeout case - this patch adds handling the
signal case the same as timeout.

Signed-off-by: Nicholas Mc Guire &lt;der.herr@hofr.at&gt;
Acked-by: Christian Lamparter &lt;chunkeey@googlemail.com&gt;
Signed-off-by: Kalle Valo &lt;kvalo@codeaurora.org&gt;
</content>
</entry>
<entry>
<title>cfg80211: remove "channel" from survey names</title>
<updated>2015-01-08T14:27:52Z</updated>
<author>
<name>Johannes Berg</name>
</author>
<published>2014-11-14T15:35:34Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=4ed20bebf51578229a1986efcf46344075ec8447'/>
<id>urn:sha1:4ed20bebf51578229a1986efcf46344075ec8447</id>
<content type='text'>
All of the survey data is (currently) per channel anyway,
so having the word "channel" in the name does nothing. In
the next patch I'll introduce global data to the survey,
where the word "channel" is actually confusing.

Signed-off-by: Johannes Berg &lt;johannes.berg@intel.com&gt;
</content>
</entry>
</feed>
