From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933650AbdDEKk3 (ORCPT ); Wed, 5 Apr 2017 06:40:29 -0400 Received: from terminus.zytor.com ([65.50.211.136]:57147 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932958AbdDEKk1 (ORCPT ); Wed, 5 Apr 2017 06:40:27 -0400 Date: Wed, 5 Apr 2017 03:35:53 -0700 From: tip-bot for Evgeny Kalugin Message-ID: Cc: matt@codeblueprint.co.uk, ard.biesheuvel@linaro.org, peterz@infradead.org, mingo@kernel.org, linux-kernel@vger.kernel.org, evgeny.kalugin@intel.com, hpa@zytor.com, torvalds@linux-foundation.org, tglx@linutronix.de Reply-To: peterz@infradead.org, matt@codeblueprint.co.uk, ard.biesheuvel@linaro.org, mingo@kernel.org, linux-kernel@vger.kernel.org, evgeny.kalugin@intel.com, torvalds@linux-foundation.org, tglx@linutronix.de, hpa@zytor.com In-Reply-To: <20170404160245.27812-9-ard.biesheuvel@linaro.org> References: <20170404160245.27812-9-ard.biesheuvel@linaro.org> To: linux-tip-commits@vger.kernel.org Subject: [tip:efi/core] efi/pstore: Return error code (if any) from efi_pstore_write() Git-Commit-ID: fee929ba1c9386e524ed3abcc6d5f9b64381f959 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: fee929ba1c9386e524ed3abcc6d5f9b64381f959 Gitweb: http://git.kernel.org/tip/fee929ba1c9386e524ed3abcc6d5f9b64381f959 Author: Evgeny Kalugin AuthorDate: Tue, 4 Apr 2017 17:02:42 +0100 Committer: Ingo Molnar CommitDate: Wed, 5 Apr 2017 12:27:25 +0200 efi/pstore: Return error code (if any) from efi_pstore_write() For some reason return value from actual variable setting was ignored. With this change error code get transferred upwards through call stack. Signed-off-by: Evgeny Kalugin Signed-off-by: Ard Biesheuvel Cc: Linus Torvalds Cc: Matt Fleming Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/20170404160245.27812-9-ard.biesheuvel@linaro.org Signed-off-by: Ingo Molnar --- drivers/firmware/efi/efi-pstore.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/firmware/efi/efi-pstore.c b/drivers/firmware/efi/efi-pstore.c index f402ba2..6b5acef 100644 --- a/drivers/firmware/efi/efi-pstore.c +++ b/drivers/firmware/efi/efi-pstore.c @@ -274,9 +274,9 @@ static int efi_pstore_write(enum pstore_type_id type, for (i = 0; i < DUMP_NAME_LEN; i++) efi_name[i] = name[i]; - efivar_entry_set_safe(efi_name, vendor, PSTORE_EFI_ATTRIBUTES, - !pstore_cannot_block_path(reason), - size, psi->buf); + ret = efivar_entry_set_safe(efi_name, vendor, PSTORE_EFI_ATTRIBUTES, + !pstore_cannot_block_path(reason), + size, psi->buf); if (reason == KMSG_DUMP_OOPS) efivar_run_worker();