Re: [PATCH] media: dvb: usb: Fix WARNING in dib0700_i2c_xfer/usb_submit_urb

Wolfram Sang
2025-03-25T22:17:35Z

[-- Attachment #1: Type: text/plain, Size: 676 bytes --]

On Tue, Mar 25, 2025 at 05:47:53PM -0400, Alan Stern wrote:
> On Tue, Mar 25, 2025 at 08:56:57PM +0100, Wolfram Sang wrote:
> >
> > > + static const struct i2c_adapter_quirks i2c_usb_quirks = {
> > > + .flags = I2C_AQ_NO_ZERO_LEN_READ,
> > > + };
> >
> > Why didn't you create the static struct outside of probe?
>
> Because it's used only in that one function. But if you prefer, I will
> move the definition outside of the function. It doesn't make any real
> difference.

Then, for consistency reasons, I'd really prefer it outside probe. I
also think it doesn't really make a difference, it just looks unusual to
me.

Thanks and happy hacking!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]