Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp5283241rwl; Sun, 8 Jan 2023 12:03:02 -0800 (PST) X-Google-Smtp-Source: AMrXdXso50yn28pPMEIWU1rLqWQXZyfRg+NcZBIdh8R//0n5QxYG6lyF3dQGNcMe3Wwt6mHfNIDS X-Received: by 2002:aa7:9526:0:b0:587:405a:421c with SMTP id c6-20020aa79526000000b00587405a421cmr4505248pfp.7.1673208182275; Sun, 08 Jan 2023 12:03:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673208182; cv=none; d=google.com; s=arc-20160816; b=bFwpGzP2oEmRURYzjAl8IlQljgfvl7xFB7kyeDgFGpy8SYGNTKOU4qhPO57F25jkHU MDJDpRHf1pp9x7t8sEfPAhYotCNhzuiA+c7mruaqiS4Rj0kK+gsl8B3xX2xGErBlVWvI PYgyZgKwfsln7NAagiTHUSi5zImDr0De0gMCAoaqfJxVI36GAoqtsTdGn22CN72Rmkk6 XS9bNqkTHtqUmF/a5U5mP8+6FLvmAiSPbbc1LW77NrDcf0AHtBGHrDh80IBwtY821V/O BteUzUeOfoZcfr5gUICh9+c4jPUxxFN1NSN5T7q+rxRGj3Ji19OBQEIlPhYJItXJT4vI 8ERg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :subject:cc:to:from:date; bh=QpIjPigNr2MvAl5Dxd/wFqbiaUae9v5krRdQWbBEXTs=; b=JZz/7Lua5sXGR1L/rOTnOJaugcmW33aSqXGADbaBoyX8+s9SspNsnRWCOIhu5zktf+ 2XzVzh1LPC4qz9qOXdRqrQwLw1u1h4A0wogZoFBznwzrl5nGI8piuNCYdfoHH/BX2qHE FTNk5BtulhZFQgT6ni4SzSJK5pkdMcnvQK5pb0+RRO0PnnOFLp5zb6bPYe+343prvOiz J1uzEIvdd1MwWnAAM0yF6QfIQUyIEJFaJaU2TRNKd7LnxK0Rw8fJ709k2MJQ+g/jFqML vd40vA9ISaRmQi8LPdzi8p9J18Tr/QxvL6Kd1abcSs3JToFRipRO85/gh25nNLxh3iJT b11g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u20-20020a056a00099400b00576a51119c0si8741978pfg.179.2023.01.08.12.02.55; Sun, 08 Jan 2023 12:03:02 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231163AbjAHTmt (ORCPT + 51 others); Sun, 8 Jan 2023 14:42:49 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49758 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233465AbjAHTma (ORCPT ); Sun, 8 Jan 2023 14:42:30 -0500 X-Greylist: delayed 319 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Sun, 08 Jan 2023 11:42:03 PST Received: from 7.mo583.mail-out.ovh.net (7.mo583.mail-out.ovh.net [178.32.124.100]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 686A6E015 for ; Sun, 8 Jan 2023 11:42:03 -0800 (PST) Received: from director7.ghost.mail-out.ovh.net (unknown [10.109.156.215]) by mo583.mail-out.ovh.net (Postfix) with ESMTP id 6D1DB23DFD for ; Sun, 8 Jan 2023 19:36:42 +0000 (UTC) Received: from ghost-submission-6684bf9d7b-wl7j5 (unknown [10.109.138.190]) by director7.ghost.mail-out.ovh.net (Postfix) with ESMTPS id 18A311FED9; Sun, 8 Jan 2023 19:36:39 +0000 (UTC) Received: from sk2.org ([37.59.142.106]) by ghost-submission-6684bf9d7b-wl7j5 with ESMTPSA id Tf9QAUcbu2N19wAAid5/uw (envelope-from ); Sun, 08 Jan 2023 19:36:39 +0000 Authentication-Results: garm.ovh; auth=pass (GARM-106R0064db9debf-ab59-4406-8e3b-2900436b4735, 5128B599F7D401446F64D4771BE19AB2B9CD7A8B) smtp.auth=steve@sk2.org X-OVh-ClientIp: 82.65.25.201 Date: Sun, 8 Jan 2023 20:36:37 +0100 From: Stephen Kitt To: Sam Ravnborg via B4 Submission Endpoint Cc: , Nicolas Ferre , Helge Deller , Alexandre Belloni , Claudiu Beznea , Antonino Daplas , Benjamin Herrenschmidt , Paul Mackerras , Greg Kroah-Hartman , Robin van der Gracht , Miguel Ojeda , Lee Jones , Daniel Thompson , Jingoo Han , linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-omap@vger.kernel.org, linux-staging@lists.linux.dev, linuxppc-dev@lists.ozlabs.org Subject: Re: [PATCH 11/15] powerpc: via-pmu-backlight: Introduce backlight_get_brightness() Message-ID: <20230108203637.0eb346fb@heffalump.sk2.org> In-Reply-To: <20230107-sam-video-backlight-drop-fb_blank-v1-11-1bd9bafb351f@ravnborg.org> References: <20230107-sam-video-backlight-drop-fb_blank-v1-0-1bd9bafb351f@ravnborg.org> <20230107-sam-video-backlight-drop-fb_blank-v1-11-1bd9bafb351f@ravnborg.org> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: multipart/signed; boundary="Sig_/uukmOXDDn4g_OXGHTWj0dxU"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Ovh-Tracer-Id: 1966384190180525702 X-VR-SPAMSTATE: OK X-VR-SPAMSCORE: -100 X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedvhedrkeeggddufedtucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuqfggjfdpvefjgfevmfevgfenuceurghilhhouhhtmecuhedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurhepfffhvfevuffkjghfofggtgesghdtreerredtvdenucfhrhhomhepufhtvghphhgvnhcumfhithhtuceoshhtvghvvgesshhkvddrohhrgheqnecuggftrfgrthhtvghrnhepfeffgefhgfeuueeffeejieefieefgfefffethfdtudegvdejueelhffhfeegjeeinecukfhppeduvdejrddtrddtrddupdefjedrheelrddugedvrddutdeinecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehinhgvthepuddvjedrtddrtddruddpmhgrihhlfhhrohhmpeeoshhtvghvvgesshhkvddrohhrgheqpdhnsggprhgtphhtthhopedupdhrtghpthhtoheplhhinhhugidqkhgvrhhnvghlsehvghgvrhdrkhgvrhhnvghlrdhorhhgpdfovfetjfhoshhtpehmohehkeefpdhmohguvgepshhmthhpohhuth X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --Sig_/uukmOXDDn4g_OXGHTWj0dxU Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Sat, 07 Jan 2023 19:26:25 +0100, Sam Ravnborg via B4 Submission Endpoint wrote: > From: Sam Ravnborg >=20 > Introduce backlight_get_brightness() to simplify logic > and avoid direct access to backlight properties. >=20 > Signed-off-by: Sam Ravnborg > Cc: Benjamin Herrenschmidt > Cc: Sam Ravnborg > Cc: linuxppc-dev@lists.ozlabs.org > --- > drivers/macintosh/via-pmu-backlight.c | 7 +------ > 1 file changed, 1 insertion(+), 6 deletions(-) >=20 > diff --git a/drivers/macintosh/via-pmu-backlight.c > b/drivers/macintosh/via-pmu-backlight.c index 2194016122d2..c2d87e7fa85b > 100644 --- a/drivers/macintosh/via-pmu-backlight.c > +++ b/drivers/macintosh/via-pmu-backlight.c > @@ -71,12 +71,7 @@ static int pmu_backlight_get_level_brightness(int leve= l) > static int __pmu_backlight_update_status(struct backlight_device *bd) > { > struct adb_request req; > - int level =3D bd->props.brightness; > - > - > - if (bd->props.power !=3D FB_BLANK_UNBLANK || > - bd->props.fb_blank !=3D FB_BLANK_UNBLANK) > - level =3D 0; > + int level =3D backlight_get_brightness(bd); > =20 > if (level > 0) { > int pmulevel =3D pmu_backlight_get_level_brightness(level); >=20 > --=20 > 2.34.1 This one is already in 6.2-rc1, it went in via powerpc/next. Regards, Stephen --Sig_/uukmOXDDn4g_OXGHTWj0dxU Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEnPVX/hPLkMoq7x0ggNMC9Yhtg5wFAmO7G0UACgkQgNMC9Yht g5xMrQ/+PwvgQ0CHCn8HmbOrtCc6qRRFkBMOMZAVkGha3M3hYGioht4oHn4GrnMy TjIR7v3/JOkUdOLbjB/64to5DRhpRA1ViZ5+rzli6mJQi4D/vcf83SUedofbYnjy L/qOMiT/c73cpoldhKsOkvgATQSLfTQfddDthcS09XVmldfqgxqcEtSrnJ6cJ3QT eguOeI9WR/MqVNXT8y+NYlQttBWVAk0xoZQJgQcFBt5pS41b8Eql9n7A7+Zn5cxs fZLnmt9N2ul1oWFIc75dwcd803z/huqueMI/lnZ/ClSPuO2Cyvy75j9MOeWdOqBt iFQFUSATbNJS+WqXZQ2Tgxdz2f84jqDheSB3znCijKJuRZT9Z8JyncQKElbaqayB bTUIOcxFQUjQzSj01lRLrvV8R+xoZwSjJzL+DDev9FKbqXrS6lPVh2ZjGveJWvXy 5ERsDt/BScQ0LqR2e7UjXh3md0NGHBts8eQM+sLGSeHp6R8CyxP6et3GdGJrQdBF BfDGcN/PbNufCzTxuVMEEYXkNDqxTtvz/V+rNJJS9KkeEYp8rp4kQIbC00TXDIDQ ZekvV+TKZ4JkqEX+z44qRw+kI0mza8D9FUCx8mxh20WU1JVRtr1IGc8zyl8Y1wu1 0vLNwdTdxVfj8Z7NnIvcI8RxxcwZVT/XoIXauX9N3/iintzk5G8= =ImCK -----END PGP SIGNATURE----- --Sig_/uukmOXDDn4g_OXGHTWj0dxU--