Thread (27 messages) 27 messages, 6 authors, 2020-10-28

Re: [patch V2 12/13] usb: core: Replace in_interrupt() in comments

From: Alan Stern <stern@rowland.harvard.edu>
Date: 2020-10-19 16:28:44
Also in: linux-omap, linux-samsung-soc, linux-usb, lkml

On Mon, Oct 19, 2020 at 12:06:41PM +0200, Thomas Gleixner wrote:
From: Ahmed S. Darwish <redacted>

The usage of in_interrupt() in drivers is phased out for various reasons.

Various comments use !in_interrupt() to describe calling context for
functions which might sleep. That's wrong because the calling context has
to be preemptible task context, which is not what !in_interrupt()
describes.

Replace !in_interrupt() with more accurate plain text descriptions.

The comment for usb_hcd_poll_rh_status() is misleading as this function is
called from all kinds of contexts including preemptible task
context. Remove it as there is obviously no restriction.

Signed-off-by: Ahmed S. Darwish <redacted>
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Thomas Gleixner <redacted>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: linux-usb@vger.kernel.org
---
V2: Fixup the comments according to review (Alan)
---
 drivers/usb/core/buffer.c  |    6 ++++--
 drivers/usb/core/hcd-pci.c |    6 ++++--
 drivers/usb/core/hcd.c     |   26 +++++++++++++++++---------
 drivers/usb/core/hub.c     |    3 ++-
 drivers/usb/core/message.c |   35 ++++++++++++++++++++++-------------
 drivers/usb/core/usb.c     |    4 ++--
 6 files changed, 51 insertions(+), 29 deletions(-)
Acked-by: Alan Stern <stern@rowland.harvard.edu>

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help