lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 2 Jan 2014 14:47:44 -0800
From:	Linus Torvalds <torvalds@...ux-foundation.org>
To:	David Miller <davem@...emloft.net>
Cc:	Samuel Ortiz <samuel@...tiz.org>,
	Network Development <netdev@...r.kernel.org>
Subject: Re: IrDA woes..

On Thu, Jan 2, 2014 at 2:41 PM, David Miller <davem@...emloft.net> wrote:
>
> Yes, something like the following untested patch.

I did that initially too, but that doesn't work, because the code
inside the skb_queue_walk() loop ends up calling irlap_send_i_frame()
which calls irlap_queue_xmit(), which does dev_queue_xmit().

Which will do a bh_disable/bh_enable() (as part of spin_[un]lock_bh(), iirc).

So you can't use "spin_lock_irqsave()", because it doesn't nest around
a softirq-disable.

You could use spin_lock_bh(), but if it's true that it's all in a
softirq context, I think it should be safe to just do "spin_lock()".
Afaik, there is nothing that actually does anything in real hardirq
context in there. I *think* all the network _rcv() functions are
called from softirqs, right?

             Linus
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ