From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757313AbbJ2PlK (ORCPT ); Thu, 29 Oct 2015 11:41:10 -0400 Received: from metis.ext.4.pengutronix.de ([92.198.50.35]:47152 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751432AbbJ2PlI (ORCPT ); Thu, 29 Oct 2015 11:41:08 -0400 Message-ID: <1446133259.3274.52.camel@pengutronix.de> Subject: Re: [PATCH v2] pwm-backlight: fix the panel power sequence From: Philipp Zabel To: YH Huang Cc: Thierry Reding , Jingoo Han , Lee Jones , Matthias Brugger , linux-pwm@vger.kernel.org, linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org, Tomi Valkeinen , linux-mediatek@lists.infradead.org, Sascha Hauer , yingjoe.chen@mediatek.com, Jean-Christophe Plagniol-Villard , linux-arm-kernel@lists.infradead.org Date: Thu, 29 Oct 2015 16:40:59 +0100 In-Reply-To: <1445526750.27586.8.camel@mtksdaap41> References: <1444987060-48202-1-git-send-email-yh.huang@mediatek.com> <1444988219.3541.3.camel@pengutronix.de> <1445526750.27586.8.camel@mtksdaap41> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.12.9-1+b1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-SA-Exim-Connect-IP: 2001:67c:670:100:96de:80ff:fec2:9969 X-SA-Exim-Mail-From: p.zabel@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi YH, Am Donnerstag, den 22.10.2015, 23:12 +0800 schrieb YH Huang: > In the case of the panel disabled by the bootloader, > your patch still has the following code and always enables the backlight > in the probe function. > pb->enable_gpio = devm_gpiod_get_optional(&pdev->dev, "enable", > - GPIOD_OUT_HIGH); You are right. > What do you think if I remove these two lines in my patch? > if (pb->enable_gpio) > gpiod_direction_output(pb->enable_gpio, 0); That won't work if the gpio is still configured as input. How about I add the GPIOD_ASIS change to my patch you remove that and the above from yours? best regards Philipp