From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Thompson Subject: Re: [PATCH v4 12/20] backlight: introduce backlight_get_brightness() Date: Wed, 8 Jul 2020 11:27:54 +0100 Message-ID: <20200708102754.x3afazd7kbldjg2n@holly.lan> References: <20200703184546.144664-1-sam@ravnborg.org> <20200703184546.144664-13-sam@ravnborg.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: <20200703184546.144664-13-sam@ravnborg.org> Sender: linux-arm-msm-owner@vger.kernel.org To: Sam Ravnborg Cc: dri-devel@lists.freedesktop.org, Jingoo Han , Lee Jones , Andy Gross , Bartlomiej Zolnierkiewicz , Bjorn Andersson , Daniel Vetter , David Airlie , Emil Velikov , Jonathan Corbet , linux-arm-msm@vger.kernel.org, linux-pwm@vger.kernel.org, Maarten Lankhorst , Maxime Ripard , Michael Hennerich , patches@opensource.cirrus.com, Support Opensource , Thierry Reding , Thomas Zimmermann , Uwe List-Id: linux-pwm@vger.kernel.org On Fri, Jul 03, 2020 at 08:45:38PM +0200, Sam Ravnborg wrote: > Based on an idea from Emil Velikov > add a helper that checks backlight_is_blank() and return 0 as brightness > if display is blank or the property value if not. > > This allows us to simplify the update_status() implementation > in most of the backlight drivers. > > Signed-off-by: Sam Ravnborg > Cc: Emil Velikov > Cc: Lee Jones > Cc: Daniel Thompson > Cc: Jingoo Han Reviewed-by: Daniel Thompson