Re: [PATCH 2/5] media: uvcvideo: Refactor Power Line Frequency limit selection

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Laurent

On Mon, 10 Jun 2024 at 17:21, Laurent Pinchart
<laurent.pinchart@xxxxxxxxxxxxxxxx> wrote:
> > +static int __uvc_ctrl_add_mapping(struct uvc_video_chain *chain,
> > +     struct uvc_control *ctrl, const struct uvc_control_mapping *mapping);
>
> I wonder if we could avoid the forward declaration by turning the
> .add_mapping() operation into a .filter_mapping() (name to be
> bikshedded) that would return a replacement mapping instead of adding
> it. The caller (the __uvc_ctrl_add_custom_mapping() function) would then
> call __uvc_ctrl_add_mapping() unconditionally. You could actually call
> the new operation directly in __uvc_ctrl_add_custom_mapping() without
> having to add a new __uvc_ctrl_add_custom_mapping() function. What do
> you think, would that be simpler and more redable ?

Let me add it as a forward patch, let me know what you think.

Regards!




[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux