From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3F2E9345759; Wed, 3 Dec 2025 16:11:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764778282; cv=none; b=Qci3R0MNAU6T078EoNF23NpUq35U7KA53X4IDuC0+OGYf7S7q5O4XrSa+Z237PI4ed8kCZ6hdXqXjcpctmplIVDLgxTVHsFMOkeAl3V+9CcdoS/dSzGjSDmo7uXk+rmdmKv5kimoh09KXC0RwXoB7S0UZvs7d2BgfvmqCDt8Dik= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764778282; c=relaxed/simple; bh=Gyh56lI68DTvI19a3e+a5y1IomYz9mQNoQX43SlauvU=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=IV6b4/duJAzCTkMwG3wDw2I+IHOc+MEF/zwlcTDV8YB+g9PVBGzn3SuniFL4lOtfGy+oe6C3lzSEps8N7xUO+tL2+eQ5n+HvsWcACL6gDJfwB46Amf9eMj3Nhn1yw+V9Yx6xcv/kV9CpcJLMzs/CTFomminIqjAkcbha2yqp61I= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=XZXr8I3S; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="XZXr8I3S" Received: by smtp.kernel.org (Postfix) with ESMTPSA id A5CADC4CEF5; Wed, 3 Dec 2025 16:11:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1764778282; bh=Gyh56lI68DTvI19a3e+a5y1IomYz9mQNoQX43SlauvU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=XZXr8I3SeTT/X1jjuNc9uaYAFGByi6XqxQzB7CXF3y3GBQN7CKh8mvl9FDl9bhOgL vkHibvgPVOC1MC5oRZtqwCM2aQIwEZIrROmtcfB9g6hWo6+tGQ+lfjYruRgmfNa2DR EDrmjtaTY0p2sg/g5T7H7YWFDsnvcM1NmzHIbmpY= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Haotian Zhang , Srinivas Pandruvada , =?UTF-8?q?Ilpo=20J=C3=A4rvinen?= , Sasha Levin Subject: [PATCH 5.15 298/392] platform/x86/intel/speed_select_if: Convert PCIBIOS_* return codes to errnos Date: Wed, 3 Dec 2025 16:27:28 +0100 Message-ID: <20251203152425.134888358@linuxfoundation.org> X-Mailer: git-send-email 2.52.0 In-Reply-To: <20251203152414.082328008@linuxfoundation.org> References: <20251203152414.082328008@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 5.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Haotian Zhang [ Upstream commit d8bb447efc5622577994287dc77c684fa8840b30 ] isst_if_probe() uses pci_read_config_dword() that returns PCIBIOS_* codes. The return code is returned from the probe function as is but probe functions should return normal errnos. A proper implementation can be found in drivers/leds/leds-ss4200.c. Convert PCIBIOS_* return codes using pcibios_err_to_errno() into normal errno before returning. Fixes: d3a23584294c ("platform/x86: ISST: Add Intel Speed Select mmio interface") Signed-off-by: Haotian Zhang Acked-by: Srinivas Pandruvada Link: https://patch.msgid.link/20251117033354.132-1-vulab@iscas.ac.cn Reviewed-by: Ilpo Järvinen Signed-off-by: Ilpo Järvinen Signed-off-by: Sasha Levin --- drivers/platform/x86/intel/speed_select_if/isst_if_mmio.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/platform/x86/intel/speed_select_if/isst_if_mmio.c b/drivers/platform/x86/intel/speed_select_if/isst_if_mmio.c index ff49025ec0856..bb38e5f021a80 100644 --- a/drivers/platform/x86/intel/speed_select_if/isst_if_mmio.c +++ b/drivers/platform/x86/intel/speed_select_if/isst_if_mmio.c @@ -106,11 +106,11 @@ static int isst_if_probe(struct pci_dev *pdev, const struct pci_device_id *ent) ret = pci_read_config_dword(pdev, 0xD0, &mmio_base); if (ret) - return ret; + return pcibios_err_to_errno(ret); ret = pci_read_config_dword(pdev, 0xFC, &pcu_base); if (ret) - return ret; + return pcibios_err_to_errno(ret); pcu_base &= GENMASK(10, 0); base_addr = (u64)mmio_base << 23 | (u64) pcu_base << 12; -- 2.51.0