From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pavel Machek Subject: Re: [PATCH v5 2/3] platform/chrome: Add Wilco EC keyboard backlight LEDs support Date: Thu, 4 Apr 2019 21:52:10 +0200 Message-ID: <20190404195210.GC29984@amd> References: <20190404171007.160878-1-ncrews@chromium.org> <20190404171007.160878-2-ncrews@chromium.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="/Uq4LBwYP4y1W6pO" Return-path: Content-Disposition: inline In-Reply-To: <20190404171007.160878-2-ncrews@chromium.org> Sender: linux-kernel-owner@vger.kernel.org To: Nick Crews Cc: enric.balletbo@collabora.com, bleung@chromium.org, linux-leds@vger.kernel.org, jacek.anaszewski@gmail.com, alexandre.belloni@bootlin.com, a.zummo@towertech.it, linux-rtc@vger.kernel.org, linux-kernel@vger.kernel.org, dlaurie@chromium.org, sjg@google.com, groeck@google.com, dtor@google.com List-Id: linux-leds@vger.kernel.org --/Uq4LBwYP4y1W6pO Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu 2019-04-04 11:10:08, Nick Crews wrote: > The EC is in charge of controlling the keyboard backlight on > the Wilco platform. We expose a standard LED class device at > /sys/class/leds/platform::kbd_backlight. This driver is modeled > after the standard Chrome OS keyboard backlight driver at > drivers/platform/chrome/cros_kbd_led_backlight.c >=20 > Some Wilco devices do not support a keyboard backlight. This > is checked via wilco_ec_keyboard_leds_exist() in the core driver, > and a platform_device will only be registered by the core if > a backlight is supported. >=20 > After an EC reset the backlight could be in a non-PWM mode. > Earlier in the boot sequence the BIOS should send a command to > the EC to set the brightness, so things **should** be set up, > but we double check in probe() as we query the initial brightness. > If not set up, then set the brightness to 0. >=20 > Since the EC will never change the backlight level of its own accord, > we don't need to implement a brightness_get() method. =2E.. > Signed-off-by: Nick Crews > Acked-by: Jacek Anaszewski Acked-by: Pavel Machek --=20 (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blo= g.html --/Uq4LBwYP4y1W6pO Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAlymYGoACgkQMOfwapXb+vLYUgCgsPgTBohHm4ztKgBYMtWoJma0 VRkAoI4/89nZFkwhMdJlDvcCK+hHhMyL =c7Go -----END PGP SIGNATURE----- --/Uq4LBwYP4y1W6pO--