From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 C04193C10AB; Tue, 21 Jul 2026 22:47:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784674036; cv=none; b=RskjoCuQEE7Zjgijz2xm2+kHGoRhJISelHqYAHZvbk67Q83rM1OmM+B5eotVhJSCY/LBvqlYXKVAIMw76jfPYL4v4aDaopx4HszhQ/e3HZyc1BdXyDRnS12oFVktSX6SqWF2TwbOanH4yUf/FO0gn97pmiHCR8cG7B6MqpiKfhU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784674036; c=relaxed/simple; bh=IwRIZ5VdPT5hr6+8XWAs6EwVm3dOq87Qe2hMZ5xKNZ4=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=nSvlwMkMqrU28oRblQjRIfEQi1Q6XWHs/DYBLczjN0uQnkmpoN4HPCVy9umATXURfh5Tr5ew1SRQKP6uMhYWeaqnFnsCQeOAW+AkdQOLWIo9wNHoOXWVcJKueVW7F+qJrbOz82C4NGJTTb/e/IA6PbboOIsKqQ2a4PoilNtz5LA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=NPSnuqDG; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="NPSnuqDG" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2E6D81F000E9; Tue, 21 Jul 2026 22:47:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1784674035; bh=e7C2oJvmgHXIYrYG+nr2vfgGqjTKX8uYrc9lmX1EpNY=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=NPSnuqDGjLA0RyDYDgiyrFbmL8OPTkr3e7jMz4b+5S79cmXRLPhS1BKWFHVW1rkQ6 vJg4E2nyWIzfyprx6pUzMDcF/VUPz27xrH0H1i/hPVnFI6DdBrBf9RHa0IB/RVbTyT yfBBMwsJ/c1ihxKI9zLB/4T2IY1hAX+8iOsKf66w= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Ijae Kim , Myeonghun Pak , Niklas Cassel , Linus Walleij , Damien Le Moal , Sasha Levin Subject: [PATCH 5.10 388/699] ata: sata_gemini: unwind clocks on IDE pinctrl errors Date: Tue, 21 Jul 2026 17:22:27 +0200 Message-ID: <20260721152404.443687418@linuxfoundation.org> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260721152355.667394603@linuxfoundation.org> References: <20260721152355.667394603@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-Transfer-Encoding: 8bit 5.10-stable review patch. If anyone has any objections, please let me know. ------------------ From: Myeonghun Pak [ Upstream commit c0ace4130e813acbabdfaa28d4e94a849c2ffdd7 ] gemini_sata_bridge_init() prepares and enables both SATA PCLKs, then disables them again while keeping the clocks prepared for later bridge start and stop operations. If gemini_setup_ide_pins() fails after that, gemini_sata_probe() returns directly and skips the existing out_unprep_clk unwind path. Route the IDE pinctrl failure through out_unprep_clk so the clocks prepared by gemini_sata_bridge_init() are unprepared before probe fails. Fixes: d872ced29d5f ("ata: sata_gemini: Introduce explicit IDE pin control") Co-developed-by: Ijae Kim Signed-off-by: Ijae Kim Signed-off-by: Myeonghun Pak Reviewed-by: Niklas Cassel Reviewed-by: Linus Walleij Signed-off-by: Damien Le Moal Signed-off-by: Sasha Levin --- drivers/ata/sata_gemini.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/ata/sata_gemini.c b/drivers/ata/sata_gemini.c index 1564472fd5d509..5b7ffbc2e174c6 100644 --- a/drivers/ata/sata_gemini.c +++ b/drivers/ata/sata_gemini.c @@ -391,7 +391,7 @@ static int gemini_sata_probe(struct platform_device *pdev) if (sg->ide_pins) { ret = gemini_setup_ide_pins(dev); if (ret) - return ret; + goto out_unprep_clk; } dev_info(dev, "set up the Gemini IDE/SATA nexus\n"); -- 2.53.0