Re: [PATCH v6 3/5] i3c: master: svc: Add basic HDR mode support

Frank Li
2025-10-23T23:45:04Z

On Thu, Oct 23, 2025 at 09:25:00PM +0300, Andy Shevchenko wrote:
> On Thu, Oct 23, 2025 at 11:24:02AM -0400, Frank Li wrote:
> > On Thu, Oct 23, 2025 at 11:29:53AM +0300, Andy Shevchenko wrote:
> > > On Tue, Oct 14, 2025 at 12:40:02PM -0400, Frank Li wrote:
>
> ...
>
> > > > + readl_poll_timeout(master->regs + SVC_I3C_MSTATUS, reg,
> > > > + SVC_I3C_MSTATUS_MCTRLDONE(reg), 0, 1000);
> > >
> > > No error checks? Why is it okay?
> > > Why is the first parameter 0 while it's not an _atomic() call?
> > >
> > > > + udelay(1);
> > >
> > > No explanations given. Also is it really need to be atomic? If not, use
> > > fsleep() and it will choose the best suitable API under the hood.
> >
> > It is in atomic context. I will add comments.
>
> Not only, the call that's used in the code from iopoll.h is wrong in such a
> case. Haven't you tested this with debug atomic context?

not enable debug atomic, but I think it should be
readl_poll_timeout_atomic ().

Frank
>
> --
> With Best Regards,
> Andy Shevchenko
>
>