The patch titled lockdep: annotate hostap netdev ->xmit_lock has been added to the -mm tree. Its filename is lockdep-annotate-hostap-netdev-xmit_lock.patch See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find out what to do about this ------------------------------------------------------ Subject: lockdep: annotate hostap netdev ->xmit_lock From: Arjan van de Ven <arjan@xxxxxxxxxxxxx> On Fri, 2006-06-30 at 15:45 -0700, Miles Lane wrote: > Okay, I rebuilt my kernel with your combo patch applied. > Then, I inserted my US Robotics USR2210 PCMCIA wifi card, > ran "pccardutil eject", popped out the card and then inserted > a Compaq iPaq wifi card. This triggered the following. > > [ INFO: possible circular locking dependency detected ] > ------------------------------------------------------- > syslogd/1886 is trying to acquire lock: > (&dev->queue_lock){-+..}, at: [<c11a50b5>] dev_queue_xmit+0x120/0x24b > > but task is already holding lock: > (&dev->_xmit_lock){-+..}, at: [<c11a5118>] dev_queue_xmit+0x183/0x24b > > which lock already depends on the new lock. ok this appears to be hostap playing games... it has 2 network devices for one piece of hardware and one calls the other via the networking layer; there is thankfully a natural ordering between the two, so just making the slave one a separate type ought to make this work. Signed-off-by: Ingo Molnar <mingo@xxxxxxx> Cc: Arjan van de Ven <arjan@xxxxxxxxxxxxxxx> Cc: "John W. Linville" <linville@xxxxxxxxxxxxx> Cc: Jeff Garzik <jeff@xxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxx> --- drivers/net/wireless/hostap/hostap_hw.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff -puN drivers/net/wireless/hostap/hostap_hw.c~lockdep-annotate-hostap-netdev-xmit_lock drivers/net/wireless/hostap/hostap_hw.c --- a/drivers/net/wireless/hostap/hostap_hw.c~lockdep-annotate-hostap-netdev-xmit_lock +++ a/drivers/net/wireless/hostap/hostap_hw.c @@ -3095,6 +3095,14 @@ static void prism2_clear_set_tim_queue(l } +/* + * HostAP uses two layers of net devices, where the inner + * layer gets called all the time from the outer layer. + * This is a natural nesting, which needs a split lock type. + */ +static struct lock_class_key hostap_netdev_xmit_lock_key; + + static struct net_device * prism2_init_local_data(struct prism2_helper_functions *funcs, int card_idx, struct device *sdev) @@ -3259,6 +3267,8 @@ while (0) SET_NETDEV_DEV(dev, sdev); if (ret >= 0) ret = register_netdevice(dev); + + lockdep_set_class(&dev->_xmit_lock, &hostap_netdev_xmit_lock_key); rtnl_unlock(); if (ret < 0) { printk(KERN_WARNING "%s: register netdevice failed!\n", _ Patches currently in -mm which might be from arjan@xxxxxxxxxxxxx are origin.patch add-___rodata-sections-to-asm-generic-sectionsh.patch s390-put-sys_call_table-into-rodata-section-and-write-protect-it.patch lockdep-console_init-after-local_irq_enable.patch lockdep-add-print_ip_sym.patch lockdep-s390-config_frame_pointer-support.patch lockdep-stacktrace-subsystem-s390-support.patch lockdep-irqtrace-subsystem-s390-support.patch lockdep-s390-turn-validator-off-in-machine-check-handler.patch lockdep-annotate-sunrpc-code.patch lockdep-annotate-sb-s_umount.patch lockdep-annotate-hostap-netdev-xmit_lock.patch lockdep-special-s390-print_symbol-version.patch bcm43xx-netlink-deadlock-fix.patch make-more-file_operation-structs-static.patch debug-shared-irqs.patch vdso-print-fatal-signals.patch vdso-improve-print_fatal_signals-support-by-adding-memory-maps.patch - To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html