Thread (20 messages) 20 messages, 3 authors, 2025-01-08

Re: [PATCH v4 2/9] media: i2c: ds90ub960: Replace aliased clients list with address list

From: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Date: 2025-01-08 13:33:01
Also in: linux-gpio, linux-i2c, linux-media, lkml

Hi,

On 08/01/2025 15:27, Romain Gantois wrote:
Hi Tomi,

On lundi 6 janvier 2025 10:34:10 heure normale d’Europe centrale Tomi
Valkeinen wrote:
quoted
Hi,

On 30/12/2024 15:22, Romain Gantois wrote:
...
quoted
quoted
@@ -1031,17 +1031,17 @@ static int ub960_atr_attach_client(struct i2c_atr
*atr, u32 chan_id,>
   	struct device *dev = &priv->client->dev;
   	unsigned int reg_idx;

-	for (reg_idx = 0; reg_idx < ARRAY_SIZE(rxport->aliased_clients);
reg_idx++) { -		if (!rxport->aliased_clients[reg_idx])
+	for (reg_idx = 0; reg_idx < UB960_MAX_PORT_ALIASES; reg_idx++) {
Any reason to drop the use of ARRAY_SIZE()? Usually when dealing with
fixed size arrays, it's nicer to use ARRAY_SIZE().
No reason in particular, I just thought it was more explicit to use ARRAY_SIZE
but I'll keep the UB960_MAX_PORT_ALIASES since you think it's nicer.
You got that the wrong way. The driver uses ARRAY_SIZE, but you change 
it to UB960_MAX_PORT_ALIASES...

  Tomi
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help