]> git.baikalelectronics.ru Git - kernel.git/commit
efi/libstub: Fix path separator regression
authorPhilipp Fent <fent@in.tum.de>
Mon, 15 Jun 2020 11:51:09 +0000 (13:51 +0200)
committerArd Biesheuvel <ardb@kernel.org>
Mon, 15 Jun 2020 17:43:59 +0000 (19:43 +0200)
commit7b164c11cdbaf47ee0043824bcb16b3648994798
tree5384800a7e5f3ea1db5c8e5505742a8a6011dda2
parentefb085e9739a441292d4383371d8c514fc67ea3f
efi/libstub: Fix path separator regression

Commit 44deaccf3177 ("efi/libstub: Rewrite file I/O routine") introduced a
regression that made a couple of (badly configured) systems fail to
boot [1]: Until 5.6, we silently accepted Unix-style file separators in
EFI paths, which might violate the EFI standard, but are an easy to make
mistake. This fix restores the pre-5.7 behaviour.

[1] https://bbs.archlinux.org/viewtopic.php?id=256273

Fixes: 44deaccf3177 ("efi/libstub: Rewrite file I/O routine")
Signed-off-by: Philipp Fent <fent@in.tum.de>
Link: https://lore.kernel.org/r/20200615115109.7823-1-fent@in.tum.de
[ardb: rewrite as chained if/else statements]
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
drivers/firmware/efi/libstub/file.c