diff options
author | Heiner Kallweit <hkallweit1@gmail.com> | 2023-05-28 20:39:59 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2023-06-01 08:22:26 +0300 |
commit | 748b442800e877a93a4fa1256418d0b66bdc55ce (patch) | |
tree | 0c3246915cc1ce2ee558ecd1130e171e22e87a59 /net/core/dev.c | |
parent | 60cbd38bb0ad9e4395fba9c6994f258f1d6cad51 (diff) | |
download | linux-748b442800e877a93a4fa1256418d0b66bdc55ce.tar.xz |
net: don't set sw irq coalescing defaults in case of PREEMPT_RT
If PREEMPT_RT is set, then assume that the user focuses on minimum
latency. Therefore don't set sw irq coalescing defaults.
This affects the defaults only, users can override these settings
via sysfs.
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Link: https://lore.kernel.org/r/f9439c7f-c92c-4c2c-703e-110f96d841b7@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/core/dev.c')
-rw-r--r-- | net/core/dev.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/net/core/dev.c b/net/core/dev.c index 3393c2f3dbe8..99d99b247bc9 100644 --- a/net/core/dev.c +++ b/net/core/dev.c @@ -10571,8 +10571,10 @@ void netdev_sw_irq_coalesce_default_on(struct net_device *dev) { WARN_ON(dev->reg_state == NETREG_REGISTERED); - dev->gro_flush_timeout = 20000; - dev->napi_defer_hard_irqs = 1; + if (!IS_ENABLED(CONFIG_PREEMPT_RT)) { + dev->gro_flush_timeout = 20000; + dev->napi_defer_hard_irqs = 1; + } } EXPORT_SYMBOL_GPL(netdev_sw_irq_coalesce_default_on); |