Re: [PATCH net v3] net: lan743x: Don't sleep in atomic context

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

 



On Tue, Jun 27, 2023 at 03:40:04PM +0200, Moritz Fischer wrote:
> Hi Andrew,
> 
> On Tue, Jun 27, 2023 at 3:07 PM Andrew Lunn <andrew@xxxxxxx> wrote:
> >
> > > > +static int lan743x_csr_wait_for_bit_atomic(struct lan743x_adapter *adapter,
> > >
> > > adapter is not used in readx_poll_timeout_atomic() call, right?
> > > can be removed.
> >
> > I thought that when i first looked at an earlier version of this
> > patch. But LAN743X_CSR_READ_OP is not what you think :-(
> 
> Yeah, it's not great / confusing. I tried to keep it the same as the
> rest of the file when fixing the bug.

Ahh bummer. Additionally from the first sight @data looked like being used
uninited, I thought I haven't got fooled here :)

Side note would be that I don't see much value in iopoll.h's macros
returning

	(cond) ? 0 : -ETIMEDOUT; \

this could be just !!cond but given the count of the callsites...probably
better to leave it as is.

> 
> I can see if I can clean it up across the file in a follow up.
> >
> >        Andrew
> 
> Do you want me to send a v4 with an updated commit message?

>From my POV I don't think it's worth it...

> 
> Thanks,
> Moritz



[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux