1
0
Fork 0
alistair23-linux/tools
David Ahern 4054ab64e2 tools/accounting/getdelays.c: fix netlink attribute length
A recent change to the netlink code: 6e237d099f ("netlink: Relax attr
validation for fixed length types") logs a warning when programs send
messages with invalid attributes (e.g., wrong length for a u32).  Yafang
reported this error message for tools/accounting/getdelays.c.

send_cmd() is wrongly adding 1 to the attribute length.  As noted in
include/uapi/linux/netlink.h nla_len should be NLA_HDRLEN + payload
length, so drop the +1.

Fixes: 9e06d3f9f6 ("per task delay accounting taskstats interface: documentation fix")
Reported-by: Yafang Shao <laoar.shao@gmail.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Tested-by: Yafang Shao <laoar.shao@gmail.com>
Cc: Johannes Berg <johannes@sipsolutions.net>
Cc: Shailabh Nagar <nagar@watson.ibm.com>
Cc: <stable@vger.kernel.org>
Link: http://lkml.kernel.org/r/20200327173111.63922-1-dsahern@kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2020-04-02 09:35:25 -07:00
..
accounting tools/accounting/getdelays.c: fix netlink attribute length 2020-04-02 09:35:25 -07:00
arch x86/insn: Add Control-flow Enforcement (CET) instructions to the opcode map 2020-03-26 12:21:40 +01:00
bootconfig bootconfig: Add append value operator support 2020-02-21 09:59:39 -05:00
bpf bpftool: Add struct_ops support 2020-03-20 15:51:35 +01:00
build bpftool: Only build bpftool-prog-profile if supported by clang 2020-03-13 00:08:33 +01:00
cgroup iocost: Fix iocost_monitor.py due to helper type mismatch 2020-01-17 11:54:35 -08:00
debugging
edid tools/edid: Move EDID data sets from Documentation/ 2020-02-19 04:10:32 -07:00
firewire
firmware
gpio tools: gpio: Correctly add make dependencies for gpio_utils 2019-11-13 13:46:04 +01:00
hv Tools: hv: Reopen the devices if read() or write() returns errors 2020-01-26 22:10:10 -05:00
iio tools: iio: Correctly add make dependency for iio_utils 2019-11-10 17:11:06 +00:00
include Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next 2020-03-31 17:29:33 -07:00
io_uring
kvm/kvm_stat tools/kvm_stat: Fix kvm_exit filter name 2020-01-23 09:51:06 +01:00
laptop
leds
lib Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next 2020-03-31 17:29:33 -07:00
memory-model tools/memory-model/Documentation: Add plain accesses and data races to explanation.txt 2019-10-05 11:59:44 -07:00
nfsd
objtool Merge branch 'locking-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2020-03-30 16:17:15 -07:00
pci tools: PCI: Fix fd leakage 2019-10-29 12:04:18 +00:00
pcmcia
perf Merge branch 'x86-misc-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2020-03-31 11:30:45 -07:00
power platform-drivers-x86 for v5.7-1 2020-03-31 16:43:40 -07:00
scripts Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-03-25 18:58:11 -07:00
spi spi: spidev_test: Remove the whole "include" directory when make clean 2020-02-13 13:17:59 +00:00
testing Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next 2020-03-31 17:29:33 -07:00
thermal/tmon
time
usb usbip: Fix unsafe unaligned pointer usage 2020-01-09 16:44:26 +01:00
virtio tools/virtio: xen stub 2019-10-13 09:38:27 -04:00
vm tools/vm/slabinfo: fix sanity checks enabling 2020-01-31 10:30:38 -08:00
wmi
Makefile tools: bootconfig: Add bootconfig command 2020-01-13 13:19:39 -05:00