]> git.baikalelectronics.ru Git - kernel.git/commit
Revert "wireless: Use first phyX name available when registering phy devices."
authorJohannes Berg <johannes@sipsolutions.net>
Mon, 11 Oct 2010 18:46:52 +0000 (14:46 -0400)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 11 Oct 2010 18:46:52 +0000 (14:46 -0400)
commitc2f16d7b0eaccd189ae55bf7e5688ed1446c97d6
tree804b483a7aa2c2ad373fbe2e9b30844dea5c886c
parent0136ab6c42d3f702cf6a0e18d2c38f404d1a63e4
Revert "wireless: Use first phyX name available when registering phy devices."

This reverts commit 4a09b3762456462adab381586bc2c7ffce8fdf69.

The commit failed to take into account that allocated wireless devices
(wiphys) are not added into the device list upon allocation, but only
when they are registered. Therefore, it opened up a race between
allocating and registering a name, so that if two processes allocate and
register concurrently ("alloc, alloc, register, register" rather than
"alloc, register, alloc, register") the code will attempt to use the
same name twice.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/wireless/core.c