mirror of
https://github.com/torvalds/linux.git
synced 2024-11-26 06:02:05 +00:00
netdev: Add missing __percpu qualifier to a cast
Add missing __percpu qualifier to a (void *) cast to fix dev.c:10863:45: warning: cast removes address space '__percpu' of expression sparse warning. Also remove now unneeded __force sparse directives. Found by GCC's named address space checks. There were no changes in the resulting object file. Signed-off-by: Uros Bizjak <ubizjak@gmail.com> Link: https://patch.msgid.link/20240814070748.943671-1-ubizjak@gmail.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
fcb1aa5163
commit
d440af37ba
@ -10868,7 +10868,7 @@ noinline void netdev_core_stats_inc(struct net_device *dev, u32 offset)
|
||||
return;
|
||||
}
|
||||
|
||||
field = (__force unsigned long __percpu *)((__force void *)p + offset);
|
||||
field = (unsigned long __percpu *)((void __percpu *)p + offset);
|
||||
this_cpu_inc(*field);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(netdev_core_stats_inc);
|
||||
|
Loading…
Reference in New Issue
Block a user