diff options
author | Arnd Bergmann <arnd@arndb.de> | 2021-05-08 00:07:56 +0200 |
---|---|---|
committer | Arnd Bergmann <arnd@arndb.de> | 2021-05-17 13:30:29 +0200 |
commit | e3e22076710632250cfaee853499f3de6e9be35d (patch) | |
tree | b94e7a4e2c077a2928d2b8fa2bddadb2c434f93e /include/asm-generic/uaccess.h | |
parent | 8f4e3d48bb50765ab27ae5bebed2595b20de80a1 (diff) | |
download | lwn-e3e22076710632250cfaee853499f3de6e9be35d.tar.gz lwn-e3e22076710632250cfaee853499f3de6e9be35d.zip |
netpoll: avoid put_unaligned() on single character
With a planned cleanup, using put_unaligned() on a single character
results in a harmless warning:
In file included from ./arch/x86/include/generated/asm/unaligned.h:1,
from include/linux/etherdevice.h:24,
from net/core/netpoll.c:18:
net/core/netpoll.c: In function 'netpoll_send_udp':
include/asm-generic/unaligned.h:23:9: error: 'packed' attribute ignored for field of type 'unsigned char' [-Werror=attributes]
net/core/netpoll.c:431:3: note: in expansion of macro 'put_unaligned'
431 | put_unaligned(0x60, (unsigned char *)ip6h);
| ^~~~~~~~~~~~~
include/asm-generic/unaligned.h:23:9: error: 'packed' attribute ignored for field of type 'unsigned char' [-Werror=attributes]
net/core/netpoll.c:459:3: note: in expansion of macro 'put_unaligned'
459 | put_unaligned(0x45, (unsigned char *)iph);
| ^~~~~~~~~~~~~
Replace this with an open-coded pointer dereference.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'include/asm-generic/uaccess.h')
0 files changed, 0 insertions, 0 deletions