[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <e0377059-4073-4779-8385-506b9b39301e@web.de>
Date: Tue, 16 Apr 2024 09:03:36 +0200
From: Markus Elfring <Markus.Elfring@....de>
To: Ricardo Ribalda <ribalda@...omium.org>, linux-media@...r.kernel.org,
kernel-janitors@...r.kernel.org, Abylay Ospan <aospan@...up.ru>,
Alain Volmat <alain.volmat@...s.st.com>,
Alexandre Torgue <alexandre.torgue@...s.st.com>,
Angelo Gioacchino Del Regno <angelogioacchino.delregno@...labora.com>,
Benjamin Mugnier <benjamin.mugnier@...s.st.com>,
Bjorn Andersson <andersson@...nel.org>,
Bryan O'Donoghue <bryan.odonoghue@...aro.org>, Chen-Yu Tsai <wens@...e.org>,
Dmitry Osipenko <digetx@...il.com>,
Ezequiel Garcia <ezequiel@...guardiasur.com.ar>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Hans Verkuil <hverkuil@...all.nl>,
Hugues Fruchet <hugues.fruchet@...s.st.com>,
Jacopo Mondi <jacopo+renesas@...ndi.org>,
Jernej Skrabec <jernej.skrabec@...il.com>,
Jonathan Hunter <jonathanh@...dia.com>,
Kieran Bingham <kieran.bingham+renesas@...asonboard.com>,
Konrad Dybcio <konrad.dybcio@...aro.org>,
Laurent Pinchart <laurent.pinchart@...asonboard.com>,
Luca Ceresoli <luca.ceresoli@...tlin.com>,
Martin Tuma <martin.tuma@...iteqautomotive.com>,
Matthias Brugger <matthias.bgg@...il.com>,
Mauro Carvalho Chehab <mchehab@...nel.org>,
Maxime Coquelin <mcoquelin.stm32@...il.com>,
Niklas Söderlund <niklas.soderlund+renesas@...natech.se>,
Paul Kocialkowski <paul.kocialkowski@...tlin.com>,
Pavel Machek <pavel@....cz>, Sakari Ailus <sakari.ailus@...ux.intel.com>,
Samuel Holland <samuel@...lland.org>, Sergey Kozlov <serjk@...up.ru>,
Sergey Senozhatsky <senozhatsky@...omium.org>,
Sowjanya Komatineni <skomatineni@...dia.com>,
Stanimir Varbanov <stanimir.k.varbanov@...il.com>,
Sylvain Petinot <sylvain.petinot@...s.st.com>,
Thierry Reding <thierry.reding@...il.com>,
Vikash Garodia <quic_vgarodia@...cinc.com>
Cc: LKML <linux-kernel@...r.kernel.org>,
linux-stm32@...md-mailman.stormreply.com,
linux-arm-kernel@...ts.infradead.org, linux-staging@...ts.linux.dev,
linux-sunxi@...ts.linux.dev, linux-tegra@...r.kernel.org,
linux-mediatek@...ts.infradead.org, linux-arm-msm@...r.kernel.org
Subject: Re: [PATCH 03/35] media: uvcvideo: Refactor iterators
I would find a hint for a variable change more appropriate in the patch subject
instead of the word “iterators”.
…
> +++ b/drivers/media/usb/uvc/uvc_ctrl.c
…
> @@ -2175,16 +2177,16 @@ int uvc_xu_ctrl_query(struct uvc_video_chain *chain,
> int ret;
>
> /* Find the extension unit. */
…
> + entity = NULL;
> + list_for_each_entry(iter, &chain->entities, chain) {
…
I suggest to move this assignment into the definition for the affected local variable.
By the way:
I see another source code adjustment opportunity in this function implementation.
https://elixir.bootlin.com/linux/v6.9-rc4/source/drivers/media/usb/uvc/uvc_ctrl.c#L2165
Can it be nicer to use labels “free_data” and “unlock” (instead of “done”)?
How do you think about to increase the application of scope-based resource management here?
Regards,
Markus
Powered by blists - more mailing lists