Linux Samsung SOC development
 help / color / mirror / Atom feed
From: Lee Jones <lee@kernel.org>
To: Jacek Anaszewski <jacek.anaszewski@gmail.com>
Cc: "Kaustabh Chakraborty" <kauschluss@disroot.org>,
	"Pavel Machek" <pavel@kernel.org>,
	"Rob Herring" <robh@kernel.org>,
	"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
	"Conor Dooley" <conor+dt@kernel.org>,
	"MyungJoo Ham" <myungjoo.ham@samsung.com>,
	"Chanwoo Choi" <cw00.choi@samsung.com>,
	"Sebastian Reichel" <sre@kernel.org>,
	"Krzysztof Kozlowski" <krzk@kernel.org>,
	"André Draszik" <andre.draszik@linaro.org>,
	"Alexandre Belloni" <alexandre.belloni@bootlin.com>,
	"Jonathan Corbet" <corbet@lwn.net>,
	"Shuah Khan" <skhan@linuxfoundation.org>,
	"Nam Tran" <trannamatk@gmail.com>,
	"Łukasz Lebiedziński" <kernel@lvkasz.us>,
	linux-leds@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org,
	linux-samsung-soc@vger.kernel.org, linux-rtc@vger.kernel.org,
	linux-doc@vger.kernel.org
Subject: Re: [PATCH v5 07/11] leds: flash: add support for Samsung S2M series PMIC flash LED device
Date: Wed, 13 May 2026 15:00:38 +0100	[thread overview]
Message-ID: <20260513140038.GB305027@google.com> (raw)
In-Reply-To: <80d85385-f5af-44e3-b9ed-d4489542d4da@gmail.com>

On Thu, 07 May 2026, Jacek Anaszewski wrote:

> Hi Lee,
> 
> On 5/7/26 6:46 PM, Lee Jones wrote:
> > On Fri, 24 Apr 2026, Kaustabh Chakraborty wrote:
> > 
> > > Add support for flash LEDs in certain Samsung S2M series PMICs.
> > > The device has two channels for LEDs, typically for the back and front
> > > cameras in mobile devices. Both channels can be independently
> > > controlled, and can be operated in torch or flash modes.
> > > 
> > > The driver includes initial support for the S2MU005 PMIC flash LEDs.
> > > 
> > > Signed-off-by: Kaustabh Chakraborty <kauschluss@disroot.org>
> > > ---
> > >   drivers/leds/flash/Kconfig          |  12 ++
> > >   drivers/leds/flash/Makefile         |   1 +
> > >   drivers/leds/flash/leds-s2m-flash.c | 358 ++++++++++++++++++++++++++++++++++++
> > >   3 files changed, 371 insertions(+)
> > > 
> > > diff --git a/drivers/leds/flash/Kconfig b/drivers/leds/flash/Kconfig
> > > index 5e08102a67841..be62e05277429 100644
> > > --- a/drivers/leds/flash/Kconfig
> > > +++ b/drivers/leds/flash/Kconfig
> > > @@ -114,6 +114,18 @@ config LEDS_RT8515
> > >   	  To compile this driver as a module, choose M here: the module
> > >   	  will be called leds-rt8515.
> > > +config LEDS_S2M_FLASH
> > > +	tristate "Samsung S2M series PMICs flash/torch LED support"
> > > +	depends on LEDS_CLASS
> > > +	depends on MFD_SEC_CORE
> > > +	depends on V4L2_FLASH_LED_CLASS || !V4L2_FLASH_LED_CLASS
> > 
> > The `|| !V4L2_FLASH_LED_CLASS` part of this dependency makes it
> > unconditionally true. Was this intended? Perhaps this dependency can be
> > removed entirely.
> This is for a reason to allow building the driver if
> V4L2_FLASH_LED_CLASS is turned off, or build it as a module
> if V4L2_FLASH_LED_CLASS=m. You will get nice explanation from
> Google AI if you type just
> "V4L2_FLASH_LED_CLASS || !V4L2_FLASH_LED_CLASS".
> 
> See e.g. [0], which fixes undefined symbol error by adding this.
> 
> [0] https://git.paulk.fr/projects/linux.git/commit/drivers?h=sunxi/cedrus/jpeg-nv16&id=dbeb02a0bc41b9e9b9c05e460890351efecf1352

I see.  Thanks for the explanation.

-- 
Lee Jones

  reply	other threads:[~2026-05-13 14:00 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-23 19:38 [PATCH v5 00/11] Support for Samsung S2MU005 PMIC and its sub-devices Kaustabh Chakraborty
2026-04-23 19:39 ` [PATCH v5 01/11] dt-bindings: leds: document Samsung S2M series PMIC flash LED device Kaustabh Chakraborty
2026-04-23 19:39 ` [PATCH v5 02/11] dt-bindings: extcon: document Samsung S2M series PMIC extcon device Kaustabh Chakraborty
2026-04-28  6:00   ` Krzysztof Kozlowski
2026-04-23 19:39 ` [PATCH v5 03/11] dt-bindings: mfd: add documentation for S2MU005 PMIC Kaustabh Chakraborty
2026-04-28  6:01   ` Krzysztof Kozlowski
2026-04-29 13:12     ` Kaustabh Chakraborty
2026-04-30 10:50       ` Krzysztof Kozlowski
2026-04-23 19:39 ` [PATCH v5 04/11] mfd: sec: add support " Kaustabh Chakraborty
2026-04-23 19:39 ` [PATCH v5 05/11] mfd: sec: set DMA coherent mask Kaustabh Chakraborty
2026-04-23 19:39 ` [PATCH v5 06/11] mfd: sec: resolve PMIC revision in S2MU005 Kaustabh Chakraborty
2026-04-23 19:39 ` [PATCH v5 07/11] leds: flash: add support for Samsung S2M series PMIC flash LED device Kaustabh Chakraborty
2026-05-07 16:46   ` Lee Jones
2026-05-07 18:33     ` Kaustabh Chakraborty
2026-05-07 19:39     ` Jacek Anaszewski
2026-05-13 14:00       ` Lee Jones [this message]
2026-04-23 19:39 ` [PATCH v5 08/11] leds: rgb: add support for Samsung S2M series PMIC RGB " Kaustabh Chakraborty
2026-05-07 19:00   ` Lee Jones
2026-05-08 17:27     ` Kaustabh Chakraborty
2026-04-23 19:39 ` [PATCH v5 09/11] Documentation: leds: document pattern behavior of Samsung S2M series PMIC RGB LEDs Kaustabh Chakraborty
2026-04-23 19:39 ` [PATCH v5 10/11] extcon: add support for Samsung S2M series PMIC extcon devices Kaustabh Chakraborty
2026-04-23 19:39 ` [PATCH v5 11/11] power: supply: add support for Samsung S2M series PMIC charger device Kaustabh Chakraborty

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260513140038.GB305027@google.com \
    --to=lee@kernel.org \
    --cc=alexandre.belloni@bootlin.com \
    --cc=andre.draszik@linaro.org \
    --cc=conor+dt@kernel.org \
    --cc=corbet@lwn.net \
    --cc=cw00.choi@samsung.com \
    --cc=devicetree@vger.kernel.org \
    --cc=jacek.anaszewski@gmail.com \
    --cc=kauschluss@disroot.org \
    --cc=kernel@lvkasz.us \
    --cc=krzk+dt@kernel.org \
    --cc=krzk@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-leds@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux-rtc@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=myungjoo.ham@samsung.com \
    --cc=pavel@kernel.org \
    --cc=robh@kernel.org \
    --cc=skhan@linuxfoundation.org \
    --cc=sre@kernel.org \
    --cc=trannamatk@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox