[PATCH] drm/bridge: nxp-ptn3460: fix i2c_master_send() error checking

Robert Foss rfoss at kernel.org
Tue Dec 5 14:04:49 UTC 2023


On Tue, Dec 5, 2023, 15:01 Dan Carpenter <dan.carpenter at linaro.org> wrote:

> On Tue, Dec 05, 2023 at 02:48:26PM +0100, Robert Foss wrote:
> > On Mon, 4 Dec 2023 15:29:00 +0300, Dan Carpenter wrote:
> > > The i2c_master_send/recv() functions return negative error codes or the
> > > number of bytes that were able to be sent/received.  This code has
> > > two problems.  1)  Instead of checking if all the bytes were sent or
> > > received, it checks that at least one byte was sent or received.
> > > 2) If there was a partial send/receive then we should return a negative
> > > error code but this code returns success.
> > >
> > > [...]
> >
> > Applied, thanks!
> >
> > [1/1] drm/bridge: nxp-ptn3460: fix i2c_master_send() error checking
> >       https://cgit.freedesktop.org/drm/drm-misc/commit/?id=914437992876
> >
>
> Wait.  That was unexpected.  Neil's review comments were correct.  I was
> planning to send a v2 patch which was just a cleanup.
>

Sorry Dan, I was too quick on the draw. Can you send a fixup and I'll apply
it too?


> regards,
> dan carpenter
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/dri-devel/attachments/20231205/39ca3986/attachment-0001.htm>


More information about the dri-devel mailing list