Hi, On Mon, Jul 27, 2026 at 4:40 AM Jani Nikula <[email protected]> wrote: > > On Thu, 23 Jul 2026, Pengpeng Hou <[email protected]> wrote: > > ps8640_aux_transfer_msg() programs the AUX address registers, starts the > > AUX transfer, waits for SWAUX_SEND to clear, and reads the AUX status > > register. Several of those regmap operations have return values, but the > > function only checks a stale ret after the status read. > > > > Propagate failures from the address write, transfer start, completion > > poll, and status read. This avoids returning a transfer length when the > > bridge register transaction or AUX completion wait failed. > > > > Fixes: 13afcdd7277e ("drm/bridge: parade-ps8640: Add support for AUX > > channel") > > Signed-off-by: Pengpeng Hou <[email protected]> > > --- > > Changes since v1: > > https://lore.kernel.org/all/[email protected]/ > > - include the AUX address and length in the address-write diagnostic > > - describe poll failures without assuming that every error is a timeout > > - add the Fixes tag suggested by Doug > > - rebase onto the current drm-misc-next tree > > > > drivers/gpu/drm/bridge/parade-ps8640.c | 27 +++++++++++++++++++++------ > > 1 file changed, 21 insertions(+), 6 deletions(-) > > > > diff --git a/drivers/gpu/drm/bridge/parade-ps8640.c > > b/drivers/gpu/drm/bridge/parade-ps8640.c > > index 96332721cb69..56b48f8feab6 100644 > > --- a/drivers/gpu/drm/bridge/parade-ps8640.c > > +++ b/drivers/gpu/drm/bridge/parade-ps8640.c > > @@ -257,8 +257,14 @@ static ssize_t ps8640_aux_transfer_msg(struct > > drm_dp_aux *aux, > > addr_len[PAGE0_SWAUX_LENGTH - base] = (len == 0) ? SWAUX_NO_PAYLOAD : > > ((len - 1) & SWAUX_LENGTH_MASK); > > > > - regmap_bulk_write(map, PAGE0_SWAUX_ADDR_7_0, addr_len, > > - ARRAY_SIZE(addr_len)); > > + ret = regmap_bulk_write(map, PAGE0_SWAUX_ADDR_7_0, addr_len, > > + ARRAY_SIZE(addr_len)); > > + if (ret) { > > + DRM_DEV_ERROR(dev, > > DRM_DEV_ERROR() is deprecated in favour of drm_err() or dev_err().
Good point. I'm inclined to land this anyway, though, since this is nominally a bugfix and it matches the error printing in the rest of the function. Any objections? It would be a nice future cleanup to fix the error printing in this driver overall to use the non-deprecated functions... -Doug
