aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/caif
diff options
context:
space:
mode:
authorSebastian Andrzej Siewior2020-09-29 22:25:12 +0200
committerDavid S. Miller2020-09-29 14:02:53 -0700
commitc11171a413385c1a72291cdb4a7435cb189762ab (patch)
treea1b9fe2cc3b3be8d09776f160f92113df5a683b2 /drivers/net/caif
parentf2bf88c4afc8c5ab92b40af24819933e57d0968c (diff)
net: Add netif_rx_any_context()
Quite some drivers make conditional decisions based on in_interrupt() to invoke either netif_rx() or netif_rx_ni(). Conditionals based on in_interrupt() or other variants of preempt count checks in drivers should not exist for various reasons and Linus clearly requested to either split the code pathes or pass an argument to the common functions which provides the context. This is obviously the correct solution, but for some of the affected drivers this needs a major rewrite due to their convoluted structure. As in_interrupt() usage in drivers needs to be phased out, provide netif_rx_any_context() as a stop gap for these drivers. This confines the in_interrupt() conditional to core code which in turn allows to remove the access to this check for driver code and provides one central place to do further modifications once the driver maze is cleaned up. Suggested-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/caif')
0 files changed, 0 insertions, 0 deletions