diff options
author | Matt Fleming <[email protected]> | 2013-04-26 10:10:55 +0100 |
---|---|---|
committer | Linus Torvalds <[email protected]> | 2013-04-26 08:02:03 -0700 |
commit | f464246d85d5a5c0fdbf5838b8c58ef59bd82fcc (patch) | |
tree | e0788b40695dcaa64ef2baa2367639dcdb3f4fc5 /tools/perf/util/scripting-engines/trace-event-python.c | |
parent | 37b7f3c76595e23257f61bd80b223de8658617ee (diff) |
efivars: only check for duplicates on the registered list
variable_is_present() accesses '__efivars' directly, but when called via
gsmi_init() Michel reports observing the following crash,
BUG: unable to handle kernel NULL pointer dereference at (null)
IP: variable_is_present+0x55/0x170
Call Trace:
register_efivars+0x106/0x370
gsmi_init+0x2ad/0x3da
do_one_initcall+0x3f/0x170
The reason for the crash is that '__efivars' hasn't been initialised nor
has it been registered with register_efivars() by the time the google
EFI SMI driver runs. The gsmi code uses its own struct efivars, and
therefore, a different variable list. Fix the above crash by passing
the registered struct efivars to variable_is_present(), so that we
traverse the correct list.
Reported-by: Michel Lespinasse <[email protected]>
Tested-by: Michel Lespinasse <[email protected]>
Cc: Mike Waychison <[email protected]>
Cc: Matthew Garrett <[email protected]>
Cc: Seiji Aguchi <[email protected]>
Signed-off-by: Matt Fleming <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-python.c')
0 files changed, 0 insertions, 0 deletions