usb: otg: notifier: switch to atomic notifier
most of our notifications, will be called from IRQ context, so an atomic notifier suits the job better. Signed-off-by: Felipe Balbi <balbi@ti.com>
This commit is contained in:
parent
002eda1348
commit
cccad6d4b1
5 changed files with 14 additions and 14 deletions
|
@ -75,7 +75,7 @@ struct otg_transceiver {
|
|||
void __iomem *io_priv;
|
||||
|
||||
/* for notification of usb_xceiv_events */
|
||||
struct blocking_notifier_head notifier;
|
||||
struct atomic_notifier_head notifier;
|
||||
|
||||
/* to pass extra port status to the root hub */
|
||||
u16 port_status;
|
||||
|
@ -235,13 +235,13 @@ otg_start_srp(struct otg_transceiver *otg)
|
|||
static inline int
|
||||
otg_register_notifier(struct otg_transceiver *otg, struct notifier_block *nb)
|
||||
{
|
||||
return blocking_notifier_chain_register(&otg->notifier, nb);
|
||||
return atomic_notifier_chain_register(&otg->notifier, nb);
|
||||
}
|
||||
|
||||
static inline void
|
||||
otg_unregister_notifier(struct otg_transceiver *otg, struct notifier_block *nb)
|
||||
{
|
||||
blocking_notifier_chain_unregister(&otg->notifier, nb);
|
||||
atomic_notifier_chain_unregister(&otg->notifier, nb);
|
||||
}
|
||||
|
||||
/* for OTG controller drivers (and maybe other stuff) */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue