[{"id":2330419,"web_url":"http://patchwork.ozlabs.org/comment/2330419/","msgid":"<20191221194802.GK32732@amd>","list_archive_url":null,"date":"2019-12-21T19:48:02","subject":"Re: [PATCH v7 12/12] led: bd71828: Support LED outputs on ROHM\n\tBD71828 PMIC","submitter":{"id":2109,"url":"http://patchwork.ozlabs.org/api/people/2109/","name":"Pavel Machek","email":"pavel@ucw.cz"},"content":"Hi!\n\n> ROHM BD71828 power management IC has two LED outputs for charge status\n> and button pressing indications. The LED outputs can also be forced\n> by SW so add driver allowing to use these LEDs for other indications\n> as well.\n> \n> Leds are controlled by SW using 'Force ON' bits. Please note the\n> constrains mentioned in data-sheet:\n>     1. If one LED is forced ON - then also the other LED is forced.\n>             => You can't use SW control to force ON one LED and allow HW\n>                to control the other.\n>     2. You can't force both LEDs OFF. If the FORCE bit for both LED's is\n>        zero, then LEDs are controlled by HW and indicate button/charger\n>        states as explained in data-sheet.\n\nThat's really quite sad, is it?\n\nAll the effort and all we got is ... one working LED. Because hardware\ndoes not allow you to control both LEDs...\n\n...and we don't even have support selecting if the LED should be sw or\nhw controlled in the mainline, yet...\n\nBest regards,\n\t\t\t\t\t\t\t\t\tPavel","headers":{"Return-Path":"<linux-gpio-owner@vger.kernel.org>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":["ozlabs.org; spf=none (no SPF record)\n\tsmtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67;\n\thelo=vger.kernel.org;\n\tenvelope-from=linux-gpio-owner@vger.kernel.org;\n\treceiver=<UNKNOWN>)","ozlabs.org;\n\tdmarc=none (p=none dis=none) header.from=ucw.cz"],"Received":["from vger.kernel.org (vger.kernel.org [209.132.180.67])\n\tby ozlabs.org (Postfix) with ESMTP id 47gGPQ1xTYz9s29\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSun, 22 Dec 2019 06:48:09 +1100 (AEDT)","(majordomo@vger.kernel.org) by vger.kernel.org via listexpand\n\tid S1726900AbfLUTsG (ORCPT <rfc822;incoming@patchwork.ozlabs.org>);\n\tSat, 21 Dec 2019 14:48:06 -0500","from jabberwock.ucw.cz ([46.255.230.98]:45404 \"EHLO\n\tjabberwock.ucw.cz\" rhost-flags-OK-OK-OK-OK) by vger.kernel.org\n\twith ESMTP id S1726736AbfLUTsG (ORCPT\n\t<rfc822; linux-gpio@vger.kernel.org>); Sat, 21 Dec 2019 14:48:06 -0500","by jabberwock.ucw.cz (Postfix, from userid 1017)\n\tid A7AD51C24A9; Sat, 21 Dec 2019 20:48:03 +0100 (CET)"],"Date":"Sat, 21 Dec 2019 20:48:02 +0100","From":"Pavel Machek <pavel@ucw.cz>","To":"Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>","Cc":"mazziesaccount@gmail.com, Jacek Anaszewski <jacek.anaszewski@gmail.com>,\n\tDan Murphy <dmurphy@ti.com>, Rob Herring <robh+dt@kernel.org>,\n\tMark Rutland <mark.rutland@arm.com>, Lee Jones <lee.jones@linaro.org>,\n\tMichael Turquette <mturquette@baylibre.com>,\n\tStephen Boyd <sboyd@kernel.org>,\n\tLinus Walleij <linus.walleij@linaro.org>,\n\tBartosz Golaszewski <bgolaszewski@baylibre.com>,\n\tLiam Girdwood <lgirdwood@gmail.com>, Mark Brown <broonie@kernel.org>,\n\tAlessandro Zummo <a.zummo@towertech.it>,\n\tAlexandre Belloni <alexandre.belloni@bootlin.com>,\n\tlinux-leds@vger.kernel.org, devicetree@vger.kernel.org,\n\tlinux-kernel@vger.kernel.org, linux-clk@vger.kernel.org,\n\tlinux-gpio@vger.kernel.org, linux-rtc@vger.kernel.org","Subject":"Re: [PATCH v7 12/12] led: bd71828: Support LED outputs on ROHM\n\tBD71828 PMIC","Message-ID":"<20191221194802.GK32732@amd>","References":"<cover.1576745635.git.matti.vaittinen@fi.rohmeurope.com>\n\t<c95eb856c8e05a196551179c2416455c022eb3ea.1576745635.git.matti.vaittinen@fi.rohmeurope.com>","MIME-Version":"1.0","Content-Type":"multipart/signed; micalg=pgp-sha1;\n\tprotocol=\"application/pgp-signature\"; boundary=\"++alDQ2ROsODg1x+\"","Content-Disposition":"inline","In-Reply-To":"<c95eb856c8e05a196551179c2416455c022eb3ea.1576745635.git.matti.vaittinen@fi.rohmeurope.com>","User-Agent":"Mutt/1.5.23 (2014-03-12)","Sender":"linux-gpio-owner@vger.kernel.org","Precedence":"bulk","List-ID":"<linux-gpio.vger.kernel.org>","X-Mailing-List":"linux-gpio@vger.kernel.org"}},{"id":2332002,"web_url":"http://patchwork.ozlabs.org/comment/2332002/","msgid":"<75e9d581aef0127b4e24eb06b57ef397842cf7c9.camel@fi.rohmeurope.com>","list_archive_url":null,"date":"2019-12-27T09:43:24","subject":"Re: [PATCH v7 12/12] led: bd71828: Support LED outputs on ROHM\n\tBD71828 PMIC","submitter":{"id":74146,"url":"http://patchwork.ozlabs.org/api/people/74146/","name":"Matti Vaittinen","email":"matti.vaittinen@fi.rohmeurope.com"},"content":"On Sat, 2019-12-21 at 20:48 +0100, Pavel Machek wrote:\n> Hi!\n> \n> > ROHM BD71828 power management IC has two LED outputs for charge\n> > status\n> > and button pressing indications. The LED outputs can also be forced\n> > by SW so add driver allowing to use these LEDs for other\n> > indications\n> > as well.\n> > \n> > Leds are controlled by SW using 'Force ON' bits. Please note the\n> > constrains mentioned in data-sheet:\n> >     1. If one LED is forced ON - then also the other LED is forced.\n> >             => You can't use SW control to force ON one LED and\n> > allow HW\n> >                to control the other.\n> >     2. You can't force both LEDs OFF. If the FORCE bit for both\n> > LED's is\n> >        zero, then LEDs are controlled by HW and indicate\n> > button/charger\n> >        states as explained in data-sheet.\n> \n> That's really quite sad, is it?\n> \n> All the effort and all we got is ... one working LED. Because\n> hardware\n> does not allow you to control both LEDs...\n\nYes and no. I do fully agree that it would be much nicer if the LEDs\ncould be set to be fully controlled by SW. OTOH, knowing the LEDs are\nusually OFF, using them to indicate something else is still doable. I\nthink you know typical LED use-cases better than I do - but I guess\nthat some blink pattern in order to indicate errors is well doable with\nthese LEDs.\n\n> ...and we don't even have support selecting if the LED should be sw\n> or\n> hw controlled in the mainline, yet...\n\nWhich sounds like we have such support somewhere - and hopefully in\nmainline one day ;)\n\nAnyways, Thanks for taking a look at this! :)\n\nBr,\n\tMatti Vaittinen","headers":{"Return-Path":"<linux-gpio-owner@vger.kernel.org>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":["ozlabs.org; spf=none (no SPF record)\n\tsmtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67;\n\thelo=vger.kernel.org;\n\tenvelope-from=linux-gpio-owner@vger.kernel.org;\n\treceiver=<UNKNOWN>)","ozlabs.org; dmarc=none (p=none dis=none)\n\theader.from=fi.rohmeurope.com"],"Received":["from vger.kernel.org (vger.kernel.org [209.132.180.67])\n\tby ozlabs.org (Postfix) with ESMTP id 47khj42Qmtz9sRV\n\tfor <incoming@patchwork.ozlabs.org>;\n\tFri, 27 Dec 2019 20:43:36 +1100 (AEDT)","(majordomo@vger.kernel.org) by vger.kernel.org via listexpand\n\tid S1726379AbfL0Jnd (ORCPT <rfc822;incoming@patchwork.ozlabs.org>);\n\tFri, 27 Dec 2019 04:43:33 -0500","from mailgate1.rohmeurope.com ([178.15.145.194]:52852 \"EHLO\n\tmailgate1.rohmeurope.com\" rhost-flags-OK-OK-OK-OK) by vger.kernel.org\n\twith ESMTP id S1726270AbfL0Jnc (ORCPT\n\t<rfc822; linux-gpio@vger.kernel.org>); Fri, 27 Dec 2019 04:43:32 -0500","from smtp.reu.rohmeu.com (will-cas001.reu.rohmeu.com\n\t[192.168.251.177])\n\tby mailgate1.rohmeurope.com (Symantec Messaging Gateway) with SMTP id\n\t4C.78.08102.242D50E5; Fri, 27 Dec 2019 10:43:30 +0100 (CET)","from WILL-MAIL001.REu.RohmEu.com ([fe80::2915:304f:d22c:c6ba]) by\n\tWILL-CAS001.REu.RohmEu.com ([fe80::d57e:33d0:7a5d:f0a6%16]) with\n\tmapi id 14.03.0439.000; Fri, 27 Dec 2019 10:43:25 +0100"],"X-AuditID":"c0a8fbf4-199ff70000001fa6-39-5e05d242b8aa","From":"\"Vaittinen, Matti\" <Matti.Vaittinen@fi.rohmeurope.com>","To":"\"pavel@ucw.cz\" <pavel@ucw.cz>","CC":"\"linux-leds@vger.kernel.org\" <linux-leds@vger.kernel.org>,\n\t\"dmurphy@ti.com\" <dmurphy@ti.com>,\n\t\"linux-rtc@vger.kernel.org\" <linux-rtc@vger.kernel.org>,\n\t\"linux-gpio@vger.kernel.org\" <linux-gpio@vger.kernel.org>,\n\t\"alexandre.belloni@bootlin.com\" <alexandre.belloni@bootlin.com>,\n\t\"linux-kernel@vger.kernel.org\" <linux-kernel@vger.kernel.org>,\n\t\"mturquette@baylibre.com\" <mturquette@baylibre.com>,\n\t\"mazziesaccount@gmail.com\" <mazziesaccount@gmail.com>,\n\t\"devicetree@vger.kernel.org\" <devicetree@vger.kernel.org>,\n\t\"jacek.anaszewski@gmail.com\" <jacek.anaszewski@gmail.com>,\n\t\"a.zummo@towertech.it\" <a.zummo@towertech.it>,\n\t\"linus.walleij@linaro.org\" <linus.walleij@linaro.org>,\n\t\"lgirdwood@gmail.com\" <lgirdwood@gmail.com>,\n\t\"mark.rutland@arm.com\" <mark.rutland@arm.com>,\n\t\"robh+dt@kernel.org\" <robh+dt@kernel.org>,\n\t\"bgolaszewski@baylibre.com\" <bgolaszewski@baylibre.com>,\n\t\"linux-clk@vger.kernel.org\" <linux-clk@vger.kernel.org>,\n\t\"lee.jones@linaro.org\" <lee.jones@linaro.org>,\n\t\"sboyd@kernel.org\" <sboyd@kernel.org>,\n\t\"broonie@kernel.org\" <broonie@kernel.org>","Subject":"Re: [PATCH v7 12/12] led: bd71828: Support LED outputs on ROHM\n\tBD71828 PMIC","Thread-Topic":"[PATCH v7 12/12] led: bd71828: Support LED outputs on ROHM\n\tBD71828 PMIC","Thread-Index":"AQHVtlJZu+ZgBKDQ/kGh/gU1BPf/i6fE8bMAgAjFD4A=","Date":"Fri, 27 Dec 2019 09:43:24 +0000","Message-ID":"<75e9d581aef0127b4e24eb06b57ef397842cf7c9.camel@fi.rohmeurope.com>","References":"<cover.1576745635.git.matti.vaittinen@fi.rohmeurope.com>\n\t<c95eb856c8e05a196551179c2416455c022eb3ea.1576745635.git.matti.vaittinen@fi.rohmeurope.com>\n\t<20191221194802.GK32732@amd>","In-Reply-To":"<20191221194802.GK32732@amd>","Accept-Language":"en-US, de-DE","Content-Language":"de-DE","X-MS-Has-Attach":"","X-MS-TNEF-Correlator":"","x-originating-ip":"[213.255.186.46]","Content-Type":"text/plain; charset=\"utf-8\"","Content-ID":"<33416C44855CEE488D9031465630B719@de.rohmeurope.com>","Content-Transfer-Encoding":"base64","MIME-Version":"1.0","X-Brightmail-Tracker":"H4sIAAAAAAAAA01Ta0hUWRzv3Nccx+7umUnXo6XRSIVFL4g4hIUZC7c+LEZRy5Larbk5g+OM\n\t3RkrewpRqYW0YESDj13JitStxswcEmJytHQ38ZVGz2klK8SyNJkK657G0k/nd87v9f/wP5A1\n\tPhNioNXuUlS7bDMJeu7WxU9XFyV38mlLiwKx5FxHj44cHzqvIyOlrRw5HegXSHnTPZ6caLvG\n\tk4d1VzjydNQPyIfufIYUf77AkOGTT3hSW/4ZkC5viUDqBv8BpLmqWyCVvR0MKam8w5GO1l/J\n\t41a/QI42NunI+P2rXFKkVF1WDaQ3fUd1Uln1fqnB/VgneS4VCNKj+zcFqaWvnpHOlAUZ6WLV\n\tmE5674lL0f8Rnrhddu3eaM2wL1m9Ldzif3aZyX5p2Fv68YEuD1QbCkEYxGg5Lu5r5guBHhpR\n\tD8DXxv7jQpc7ALf5ghoDoYASceEDHTVEoDm49mSBQDUsug5xw4sehmpmoM24zRsf0mzBJWW1\n\tfAivxJ7hZpZiDs3Fnf7Bbzki+g3/3Xieo9iIbgN8ZPgAxWEoAb983vPNC1AsLsgbYihmURT2\n\tvBjjQ0MjfO5mOxvCkfjV/+MT7ybcGAxwdBxWy7nsXRKyJuFHA2cnYubg4hOBiREM+O7Zfu4U\n\t+MU9pcE96XZPcbunuN1T3H8B/hLAWbLVliG7lGWLVSVnseqwZGnHDkeWB4Q2ZuQG+OJb5wMM\n\tBD4QDRlTpNhZyacZf9ruMOdaZKclXc2xKU4fwJA1RYj2DI0TzXLuPkV1fKdmQs4UJc4P/Jlq\n\tRLQrU1GyFfU7OwtCExbXdmhGg6pkKHt3Wm2uSZqBYTRcHxPhVOxmRZVzXJZ0uh7pTm0/KDVd\n\t602mdtGZLWdpryFrK1gIT70qrWBhU2llBWvk7A67EhMlrqFSRKWWHPuPotcgCgLTDNFI2ena\n\tt/mR81qrYLSKYSNDK1zyJBWTBxJJPjTrkfPp9YKw9VsOv43L/Lc/tya1u2v8xpWGmpEV5Qm9\n\tA6PJG6P9NceqvG8q/HFJ24Y4f1F5e/Su8OX1q7a2jKacmZ19OL/IJpQMru2dtpCft8Gbcmhz\n\t+zEB+cXV9da+NHN8rGFP/O8H08z3PgYbU5OD3QOddR8OKdPe/bxvk4lzWuRlC1jVKX8FSFSW\n\trvMDAAA=","Sender":"linux-gpio-owner@vger.kernel.org","Precedence":"bulk","List-ID":"<linux-gpio.vger.kernel.org>","X-Mailing-List":"linux-gpio@vger.kernel.org"}}]