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 7746E1714A8; Thu, 15 Aug 2024 13:43:13 +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=1723729393; cv=none; b=PlZyxV0cfC0yEYnFzDX+U02bfBVDVg7gJxmxJ48kHp/t25TrM99MuiDIgbeB6kNzVdfS3A6ak8K3GsvKCffEq5/9rPfsOcF5fFPyFaj4ZuYsoM7AJCtaAazGNfMvJk6dQ9BVT70CmOlGwG0W9AadDgtXMp5QWLn8jYubfnWPWPk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723729393; c=relaxed/simple; bh=TMCGIifXMvqhriBaLB5gC3OgfRUzWIzAOPPt1mgGQ8c=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=lQNQEZXJUkpwi775f7xIFsmtxQrtiL1khLB6jg64HlhEBWN6hoG7mgQuWLF1LuL4JHlPEp8rlT6l6kKfYgvlyJJJQ89hX9vu43pETGnBbya2qADswmJDt9CxMofIMchh+N5USBl6UEWaSQtmLHl5gFZKn9dOcufyE53U51/x2EM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=N52luds4; 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="N52luds4" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E05C3C32786; Thu, 15 Aug 2024 13:43:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1723729393; bh=TMCGIifXMvqhriBaLB5gC3OgfRUzWIzAOPPt1mgGQ8c=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=N52luds45jwfrimGgOZEcVyWzu2PlPUanwWiackAGrhDlc67uI2MCPG6ub1JPiaWF EwLeqj8Gizwn3tchaFOu1h/7L3jAYS4cjsY98xk4GNTMYBsTxRTv6ubllpHHmFBoCQ MeimFDswUz1G24EP9WV9pQxy1zCwUWKCQWoB4EDc= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Douglas Anderson , Dmitry Baryshkov , Linus Walleij , Neil Armstrong , Sasha Levin Subject: [PATCH 5.15 083/484] drm/panel: boe-tv101wum-nl6: If prepare fails, disable GPIO before regulators Date: Thu, 15 Aug 2024 15:19:01 +0200 Message-ID: <20240815131944.494573189@linuxfoundation.org> X-Mailer: git-send-email 2.46.0 In-Reply-To: <20240815131941.255804951@linuxfoundation.org> References: <20240815131941.255804951@linuxfoundation.org> User-Agent: quilt/0.67 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 5.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Douglas Anderson [ Upstream commit 587c48f622374e5d47b1d515c6006a4df4dee882 ] The enable GPIO should clearly be set low before turning off regulators. That matches both the inverse order that things were enabled and also the order in unprepare(). Fixes: a869b9db7adf ("drm/panel: support for boe tv101wum-nl6 wuxga dsi video mode panel") Signed-off-by: Douglas Anderson Reviewed-by: Dmitry Baryshkov Reviewed-by: Linus Walleij Link: https://lore.kernel.org/r/20240517143643.2.Ieac346cd0f1606948ba39ceea06b55359fe972b6@changeid Signed-off-by: Neil Armstrong Link: https://patchwork.freedesktop.org/patch/msgid/20240517143643.2.Ieac346cd0f1606948ba39ceea06b55359fe972b6@changeid Signed-off-by: Sasha Levin --- drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c index 9e518213a54ff..c448be3d01d16 100644 --- a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c +++ b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c @@ -574,13 +574,13 @@ static int boe_panel_prepare(struct drm_panel *panel) return 0; poweroff: + gpiod_set_value(boe->enable_gpio, 0); regulator_disable(boe->avee); poweroffavdd: regulator_disable(boe->avdd); poweroff1v8: usleep_range(5000, 7000); regulator_disable(boe->pp1800); - gpiod_set_value(boe->enable_gpio, 0); return ret; } -- 2.43.0