From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.2 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 54EEEC433F5 for ; Tue, 21 Sep 2021 17:32:19 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 3A76060F24 for ; Tue, 21 Sep 2021 17:32:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230386AbhIURd0 (ORCPT ); Tue, 21 Sep 2021 13:33:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50708 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230442AbhIURdD (ORCPT ); Tue, 21 Sep 2021 13:33:03 -0400 Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C55D9C061574; Tue, 21 Sep 2021 10:31:33 -0700 (PDT) Received: from [IPv6:::1] (p578adb1c.dip0.t-ipconnect.de [87.138.219.28]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 77B4F832AD; Tue, 21 Sep 2021 19:31:28 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1632245489; bh=e+yPbo4fafWFxb6MVPrE7e9eDwpFOH2agg9WR2G9PLk=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=AlEDMZm4EdAkkgDdttyNxp5kAZ+Q57nOZbBsHYjeRADT28QaHSFtV6AytjRu3crly KSfcOUuMPo2EV8U7nPJOmJHYWvHSqneQOZWlLyat7CjGFyVuZj9z8Mnt77DkvNMaDT C8KSD9ueULP4oGjlVr5zc2QP2UV/q5ZCkabAWauyRo8y09q51zu+4AnGDT5xZndoHu jD5IzMPxTrujqdq2jxV0sZgLkFldwWbSdGc24ofFGeoF9P8X1h0wamfGR8R8PVrPUV 6bdse02Gz/D4x3ssiBr5tfEzFdz8SKADvKoGJhGJF3XY4kHX6aZ38hl+x3+MJSoGuS l/BUXhJspBrig== Subject: Re: [PATCH V2] video: backlight: Drop maximum brightness override for brightness zero To: Lee Jones Cc: dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, =?UTF-8?Q?Noralf_Tr=c3=b8nnes?= , Daniel Thompson , stable@vger.kernel.org, Meghana Madhyastha , Sean Paul , Thierry Reding , Sam Ravnborg References: <20210713191633.121317-1-marex@denx.de> <072e01b7-8554-de4f-046a-da11af3958d6@denx.de> From: Marek Vasut Message-ID: <3799d8fe-0ff3-f3df-e963-b40d825f8e95@denx.de> Date: Tue, 21 Sep 2021 19:31:27 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org On 9/21/21 3:33 PM, Lee Jones wrote: > On Sat, 11 Sep 2021, Marek Vasut wrote: > >> On 7/13/21 9:16 PM, Marek Vasut wrote: >>> The note in c2adda27d202f ("video: backlight: Add of_find_backlight helper >>> in backlight.c") says that gpio-backlight uses brightness as power state. >>> This has been fixed since in ec665b756e6f7 ("backlight: gpio-backlight: >>> Correct initial power state handling") and other backlight drivers do not >>> require this workaround. Drop the workaround. >>> >>> This fixes the case where e.g. pwm-backlight can perfectly well be set to >>> brightness 0 on boot in DT, which without this patch leads to the display >>> brightness to be max instead of off. >>> >>> Fixes: c2adda27d202f ("video: backlight: Add of_find_backlight helper in backlight.c") >>> Acked-by: Noralf Trønnes >>> Reviewed-by: Daniel Thompson >>> Cc: # 5.4+ >>> Cc: # 4.19.x: ec665b756e6f7: backlight: gpio-backlight: Correct initial power state handling >>> Signed-off-by: Marek Vasut >>> Cc: Daniel Thompson >>> Cc: Meghana Madhyastha >>> Cc: Noralf Trønnes >>> Cc: Sean Paul >>> Cc: Thierry Reding >>> --- >>> V2: Add AB/RB, CC stable >>> --- >>> drivers/video/backlight/backlight.c | 6 ------ >>> 1 file changed, 6 deletions(-) >>> >>> diff --git a/drivers/video/backlight/backlight.c b/drivers/video/backlight/backlight.c >>> index 537fe1b376ad7..fc990e576340b 100644 >>> --- a/drivers/video/backlight/backlight.c >>> +++ b/drivers/video/backlight/backlight.c >>> @@ -688,12 +688,6 @@ static struct backlight_device *of_find_backlight(struct device *dev) >>> of_node_put(np); >>> if (!bd) >>> return ERR_PTR(-EPROBE_DEFER); >>> - /* >>> - * Note: gpio_backlight uses brightness as >>> - * power state during probe >>> - */ >>> - if (!bd->props.brightness) >>> - bd->props.brightness = bd->props.max_brightness; >>> } >>> } >>> >> >> Any news on this ? >> >> Expanding CC list. > > Looks like I was left off of the original submission. > > I can't apply a quoted patch. Please re-submit. I see. It seems the patch is available in both Lore and Patchwork: https://lore.kernel.org/all/072e01b7-8554-de4f-046a-da11af3958d6@denx.de/T/ https://patchwork.freedesktop.org/patch/443823/