mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Peter Marshall <pm@petermarshall.ca>
To: Sakari Ailus <sakari.ailus@linux.intel.com>,
	Mauro Carvalho Chehab <mchehab@kernel.org>,
	Benjamin Mugnier <benjamin.mugnier@foss.st.com>,
	Sylvain Petinot <sylvain.petinot@foss.st.com>
Cc: linux-kernel@vger.kernel.org, devicetree@vger.kernel.org,
	linux-media@vger.kernel.org, platform-driver-x86@vger.kernel.org,
	Peter Marshall <pm@petermarshall.ca>
Subject: [PATCH 05/11] media: i2c: st-vd55g1: Default to illuminator on GPIO 1
Date: Fri, 18 Sep 2026 18:16:59 -0400	[thread overview]
Message-ID: <20260918221705.323510-6-pm@petermarshall.ca> (raw)
In-Reply-To: <20260918221705.323510-1-pm@petermarshall.ca>

Sensors enumerated through a bus at runtime instead of a device tree may
not have any GPIO pins detected. Assume the illuminator is connected to
GPIO 1.

Signed-off-by: Peter Marshall <pm@petermarshall.ca>
---
 drivers/media/i2c/vd55g1.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/media/i2c/vd55g1.c b/drivers/media/i2c/vd55g1.c
index 22b1497e8851..032b76a84638 100644
--- a/drivers/media/i2c/vd55g1.c
+++ b/drivers/media/i2c/vd55g1.c
@@ -1895,6 +1895,11 @@ static int vd55g1_parse_dt_gpios(struct vd55g1 *sensor)
 		set_bit(led_gpios[i], &sensor->ext_leds_mask);
 	}
 
+	if (nb_gpios_leds == 0) {
+		sensor->gpios[1] = VD55G1_GPIO_MODE_STROBE;
+		set_bit(1, &sensor->ext_leds_mask);
+	}
+
 	return 0;
 }
 
-- 
2.55.0


  parent reply	other threads:[~2026-09-18 22:19 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-18 22:16 [PATCH v2 00/11] media: i2c: st-vd55g1: Genericize driver and add VD55G0 support Peter Marshall
2026-09-18 22:16 ` [PATCH 01/11] dt-bindings: media: i2c: st,vd55g1: Move allOf: after required: Peter Marshall
2026-09-19  7:04   ` Krzysztof Kozlowski
2026-09-18 22:16 ` [PATCH 02/11] media: dt-bindings: i2c: vd55g1: Add vd55g0 compatible Peter Marshall
2026-09-19  7:06   ` Krzysztof Kozlowski
2026-09-18 22:16 ` [PATCH 03/11] media: ipu-bridge: Add VD55G0 to the list of supported sensors Peter Marshall
2026-09-18 22:16 ` [PATCH 04/11] platform/x86: int3472: Add VD55G0 supply GPIO mapping Peter Marshall
2026-09-18 22:16 ` Peter Marshall [this message]
2026-09-18 22:17 ` [PATCH 06/11] media: i2c: st,vd55g1: Handle virtual firmware graph endpoints Peter Marshall
2026-09-18 22:17 ` [PATCH 07/11] media: i2c: st-vd55g1: Clean up module error reporting Peter Marshall
2026-09-18 22:17 ` [PATCH 08/11] media: i2c: st-vd55g1: Unify frame timing calculations Peter Marshall
2026-09-18 22:17 ` [PATCH 09/11] media: i2c: st-vd55g1: Abstract sensor models, revisions, and features Peter Marshall

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=20260918221705.323510-6-pm@petermarshall.ca \
    --to=pm@petermarshall.ca \
    --cc=benjamin.mugnier@foss.st.com \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=platform-driver-x86@vger.kernel.org \
    --cc=sakari.ailus@linux.intel.com \
    --cc=sylvain.petinot@foss.st.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

all inboxes | Powered by JetHome®