android_kernel_sony_sdm845/samples
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Daniel T. Lee 69a24e72ed samples: pktgen: fix proc_cmd command result check logic
[ Upstream commit 3cad8f911575191fb3b81d8ed0e061e30f922223 ]

Currently, proc_cmd is used to dispatch command to 'pg_ctrl', 'pg_thread',
'pg_set'. proc_cmd is designed to check command result with grep the
"Result:", but this might fail since this string is only shown in
'pg_thread' and 'pg_set'.

This commit fixes this logic by grep-ing the "Result:" string only when
the command is not for 'pg_ctrl'.

For clarity of an execution flow, 'errexit' flag has been set.

To cleanup pktgen on exit, trap has been added for EXIT signal.

Signed-off-by: Daniel T. Lee <danieltimlee@gmail.com>
Acked-by: Jesper Dangaard Brouer <brouer@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-01-04 13:39:18 +01:00
..
auxdisplay
blackfin
bpf samples, bpf: fix to change the buffer size for read() 2019-07-21 09:05:51 +02:00
configfs
connector
hidraw
hw_breakpoint
kdb
kfifo
kobject
kprobes
livepatch
mei mei: samples: fix a signedness bug in amt_host_if_call() 2019-11-25 09:53:24 +01:00
mic/mpssd
pktgen samples: pktgen: fix proc_cmd command result check logic 2020-01-04 13:39:18 +01:00
rpmsg
seccomp
timers
trace_events Fix tracing sample code warning. 2017-11-08 10:08:33 +01:00
trace_printk
uhid
v4l
watchdog
Kconfig
Makefile