]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
efibc: Replace variable set function in notifier call
authorTian Baofeng <baofeng.tian@intel.com>
Wed, 12 Jun 2019 08:18:10 +0000 (16:18 +0800)
committerArd Biesheuvel <ard.biesheuvel@linaro.org>
Sat, 22 Jun 2019 08:24:57 +0000 (10:24 +0200)
commit975a6166a8584ee4a1b8bd93098e49dc101d7171
tree6b5ca29fb7964d29128a8d476317c27a61462e52
parent919aef44d73d5d0c04213cb1bc31149cc074e65e
efibc: Replace variable set function in notifier call

Replace the variable set function from "efivar_entry_set" to
"efivar_entry_set_safe" in efibc panic notifier.
In safe function parameter "block" will set to false
and will call "efivar_entry_set_nonblocking"to set efi variables.
efivar_entry_set_nonblocking is guaranteed to
not block and is suitable for calling from crash/panic handlers.
In UEFI android platform, when warm reset happens,
with this change, efibc will not block the reboot process.
Otherwise, set variable will call queue work and send to other offlined
cpus then cause another panic, finally will cause reboot failure.

Signed-off-by: Tian Baofeng <baofeng.tian@intel.com>
Signed-off-by: Luo XinanX <xinanx.luo@intel.com>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
drivers/firmware/efi/efibc.c