diff options
author | 2022-06-07 11:26:25 +0800 | |
---|---|---|
committer | 2022-06-21 21:42:50 +0200 | |
commit | 77515ebaf01920e2db49e04672ef669a7c2907f2 (patch) | |
tree | 2143168823d91232da4576a38f112a0cca51aefe /tools/perf/scripts/python/export-to-postgresql.py | |
parent | spi: Use device_find_any_child() instead of custom approach (diff) | |
download | linux-dev-77515ebaf01920e2db49e04672ef669a7c2907f2.tar.xz linux-dev-77515ebaf01920e2db49e04672ef669a7c2907f2.zip |
devcoredump: remove the useless gfp_t parameter in dev_coredumpv and dev_coredumpm
The dev_coredumpv() and dev_coredumpm() could not be used in atomic
context, because they call kvasprintf_const() and kstrdup() with
GFP_KERNEL parameter. The process is shown below:
dev_coredumpv(.., gfp_t gfp)
dev_coredumpm(.., gfp_t gfp)
dev_set_name
kobject_set_name_vargs
kvasprintf_const(GFP_KERNEL, ...); //may sleep
kstrdup(s, GFP_KERNEL); //may sleep
This patch removes gfp_t parameter of dev_coredumpv() and dev_coredumpm()
and changes the gfp_t parameter of kzalloc() in dev_coredumpm() to
GFP_KERNEL in order to show they could not be used in atomic context.
Fixes: 833c95456a70 ("device coredump: add new device coredump class")
Reviewed-by: Brian Norris <briannorris@chromium.org>
Reviewed-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Duoming Zhou <duoming@zju.edu.cn>
Link: https://lore.kernel.org/r/df72af3b1862bac7d8e793d1f3931857d3779dfd.1654569290.git.duoming@zju.edu.cn
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions