From patchwork Mon Feb 6 13:00:04 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: tip-bot2 for Thomas Gleixner X-Patchwork-Id: 53224 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp2223210wrn; Mon, 6 Feb 2023 05:06:44 -0800 (PST) X-Google-Smtp-Source: AK7set9ubj7NftIVVNHH4NczkB8ILeC7lT8Pe9K7q8SK79vVL9aLg6xZeaAuHQLjH2xUky+TEvtJ X-Received: by 2002:a05:6a20:4421:b0:bf:58d1:ce83 with SMTP id ce33-20020a056a20442100b000bf58d1ce83mr14374514pzb.2.1675688804337; Mon, 06 Feb 2023 05:06:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1675688804; cv=none; d=google.com; s=arc-20160816; b=kxQa1glp6T6fAxbiu1zoy1IRkwxnpO3w+Qw81DbZvVToxJ/XZsVg0lHfpndGhDcsyF PpVboTJrGuu/2B3p4Ct3ojSBn/cyM8VRhhM13KyoBiDsXKJNUFXVX2Nz1kjoo4XrwNnf YD672xPq/U5tqdPfBIxjz6Z5o3upupp8ihRKnayE+LYcvEbzeeoryU4DU6Rgu5siXbC5 A3MDmVqvvFh8uaIxn6YCiZ7/EQCADHUIbI3A5GUkfDxhqfN2oFXCuBxe/vQO3FmSIXVI 0GvU+V+AGUmQimivlWlR5srVQf6NR9gyw7HeORLZm0kXPSbuy6UoC9szSpwz9qZ5oFKh iVQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=2LLZAH/u09eNQOaEpRXMUws4XchHC3Bq1ostiMn75cs=; b=0Fk+ry2xNCOmf5siCKsBPEjWvWwOT/FEgxwB2WdkjRIWVqfddsPr2fFUoLA6dcECM7 GZcOf+ST0/T4ETFVJlnrDpQ6mypvQ+O8E43WiaOKjn70H3IE2+0blMFb+snwDZtOZoiK fOpdSa77P5nIL1rKiPcdIxyZei441bHelxck3/K2yZh2UV2VbdzqRTBekVndZTq8S9Ev FfLx9xF3o3jrS5c6enSPSQXfGE3JYzXvvgIPuLaTTW5HaqjlxqT5qxN6WPSl5H3aabzV ZVINd4LhPGYrL546BFJCb2qmnQfAKzcIeYzAq0FJIoXythsjEUYc6/z66JCnj8HRGAV/ EmMA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=t5oVurtL; dkim=neutral (no key) header.i=@linutronix.de header.b=HbF5oBgV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u69-20020a638548000000b004fac1169a7esi6283208pgd.284.2023.02.06.05.06.21; Mon, 06 Feb 2023 05:06:44 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=t5oVurtL; dkim=neutral (no key) header.i=@linutronix.de header.b=HbF5oBgV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230207AbjBFNAL (ORCPT + 99 others); Mon, 6 Feb 2023 08:00:11 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42384 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229791AbjBFNAK (ORCPT ); Mon, 6 Feb 2023 08:00:10 -0500 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1408122DDF; Mon, 6 Feb 2023 05:00:09 -0800 (PST) Date: Mon, 06 Feb 2023 13:00:04 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1675688406; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=2LLZAH/u09eNQOaEpRXMUws4XchHC3Bq1ostiMn75cs=; b=t5oVurtL+rhT4CgLKzW0iYff7rRmL9x+xi4nCulN1KMrvv9GWhevLMAJmbhD70a/XoybkN Y3zEGFLXsFAlVIbqT1rP47/XDJPhACJmthGuWY+C8u51XGOZw7MnzIEdKutzJgUJtlZzQi kM8j3Zj5pM7GDaR4d4O0TBI4dEQUlROPWSG9IF8NH7fM5xjbpY7KE7Ca0Y2BodX6ZHOKip JJwU51kjT8q86usRnmP7HU8WgpGPIFFhXzDVv9+klP5MsYPh59+YA7ppvx3ya5kyurbNqC N6wvXWWq2b5SCIV26Zmnx5ubSzdcyk6cKwZPAhFs3QUggNCoCKK/EyIMsG4HPw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1675688406; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=2LLZAH/u09eNQOaEpRXMUws4XchHC3Bq1ostiMn75cs=; b=HbF5oBgVChCvs9ugwJqeIb7I2wYAQrFh2p8tBFq/gXtRwTrJ4/JsnPYvxEwW7YF7/0f7mA PfQNayke0rRcKZBA== From: "tip-bot2 for Borislav Petkov (AMD)" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: x86/microcode] x86/microcode/core: Return an error only when necessary Cc: "Borislav Petkov (AMD)" , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20230130161709.11615-5-bp@alien8.de> References: <20230130161709.11615-5-bp@alien8.de> MIME-Version: 1.0 Message-ID: <167568840420.4906.17934418820483240527.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1756465556339695528?= X-GMAIL-MSGID: =?utf-8?q?1757087063265913069?= The following commit has been merged into the x86/microcode branch of tip: Commit-ID: f33e0c893b22bf94d7985f1f2aa3872237560c74 Gitweb: https://git.kernel.org/tip/f33e0c893b22bf94d7985f1f2aa3872237560c74 Author: Borislav Petkov (AMD) AuthorDate: Mon, 30 Jan 2023 13:48:04 +01:00 Committer: Borislav Petkov (AMD) CommitterDate: Mon, 06 Feb 2023 13:41:31 +01:00 x86/microcode/core: Return an error only when necessary Return an error from the late loading function which is run on each CPU only when an error has actually been encountered during the update. Signed-off-by: Borislav Petkov (AMD) Link: https://lore.kernel.org/r/20230130161709.11615-5-bp@alien8.de --- arch/x86/kernel/cpu/microcode/core.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/x86/kernel/cpu/microcode/core.c b/arch/x86/kernel/cpu/microcode/core.c index ddc0958..7a329e5 100644 --- a/arch/x86/kernel/cpu/microcode/core.c +++ b/arch/x86/kernel/cpu/microcode/core.c @@ -409,10 +409,10 @@ static int __reload_late(void *info) goto wait_for_siblings; if (err >= UCODE_NFOUND) { - if (err == UCODE_ERROR) + if (err == UCODE_ERROR) { pr_warn("Error reloading microcode on CPU %d\n", cpu); - - ret = -1; + ret = -1; + } } wait_for_siblings: