On 13 October 2016 at 09:51, Dan Carpenter <dan.carpenter@xxxxxxxxxx> wrote: > We should return -ENOMEM here, instead of success. > > Fixes: 475fb4e8b2f4 ('efi / ACPI: load SSTDs from EFI variables') > Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx> > > diff --git a/drivers/firmware/efi/efi.c b/drivers/firmware/efi/efi.c > index 1ac199c..a4944e2 100644 > --- a/drivers/firmware/efi/efi.c > +++ b/drivers/firmware/efi/efi.c > @@ -259,8 +259,10 @@ static __init int efivar_ssdt_load(void) > } > > data = kmalloc(size, GFP_KERNEL); > - if (!data) > + if (!data) { > + ret = -ENOMEM; > goto free_entry; > + } > > ret = efivar_entry_get(entry, NULL, &size, data); > if (ret) { > -- > To unsubscribe from this list: send the line "unsubscribe linux-efi" in > the body of a message to majordomo@xxxxxxxxxxxxxxx > More majordomo info at http://vger.kernel.org/majordomo-info.html Applied, thanks. -- To unsubscribe from this list: send the line "unsubscribe linux-efi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html