From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 41092224B15; Wed, 13 May 2026 14:00:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778680846; cv=none; b=pkegR0J7EHWvqx0IemCeo/IJ9PjQSeGZZhYkrpq1Y0parR5pgAa1aKTtnAAO6wcl5s4bAE6ZjYIuOFODOafLukTQol9GTZCM/C5qwyb4ZdiB3/VYOLLrZCqapUiRvHPPP+dJulzbePykLQo9pO+56K020jYOqjUE9a3Upt4TkWw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778680846; c=relaxed/simple; bh=Fg1mrlWMnj05/L7JUG6z1j7E/W6et1xH3QyvjiwbRfg=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=c120GcPb2YrxHa5AqsQcUpXboyIt1FwMA4JGgCaAPGvAcjL1/xiBNPJy4RRu/1YeRvrHjZgcOGYMPXwBGQe+cnzdnxQdSOviZc/YlvXpLwLVrIml6egyf5SP8l9Be+a6GTy8C8x5S8oGVJoqpkp1+1UYjaDDxjyM+GwVPQFyEJE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=cQrubRky; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="cQrubRky" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 908BEC2BCB3; Wed, 13 May 2026 14:00:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1778680845; bh=Fg1mrlWMnj05/L7JUG6z1j7E/W6et1xH3QyvjiwbRfg=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=cQrubRkyOCuBrBGRrIsyYlVDWDvPJ4V6CSDxAQC259nErLzuRA4/P9Aun/PuF78Ba WNzSB/3z0G4JR0qv6LJCChcSL679reLh5GcyK+J1+uEjdxSV4hEJ111ufEL4W6qjlP jV1B0moohypLZ+me+iE2q3ljGq8oAmF8vYNufO5dzC7YjseUyIcrNku92SxUMolIbW XMvB45YU6TpasjrVbsmml0KIvnnDWXrZpyQIk8oU/ZqQFWUaKfbmTw1UH1LxFil/O6 ZebrehYM/ZHrPO0Oz5Wy0zkw7nxYH5VUclM9rTyIcLvIwcZ2vPS9r2RZZhVL99qeQ0 TVpw87ouR6EtQ== Date: Wed, 13 May 2026 15:00:38 +0100 From: Lee Jones To: Jacek Anaszewski Cc: Kaustabh Chakraborty , Pavel Machek , Rob Herring , Krzysztof Kozlowski , Conor Dooley , MyungJoo Ham , Chanwoo Choi , Sebastian Reichel , Krzysztof Kozlowski , =?iso-8859-1?Q?Andr=E9?= Draszik , Alexandre Belloni , Jonathan Corbet , Shuah Khan , Nam Tran , =?utf-8?B?xYF1a2FzeiBMZWJpZWR6acWEc2tp?= , 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 Message-ID: <20260513140038.GB305027@google.com> References: <20260424-s2mu005-pmic-v5-0-fcbc9da5a004@disroot.org> <20260424-s2mu005-pmic-v5-7-fcbc9da5a004@disroot.org> <20260507164654.GS305027@google.com> <80d85385-f5af-44e3-b9ed-d4489542d4da@gmail.com> Precedence: bulk X-Mailing-List: linux-pm@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline 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 > > > --- > > > 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