Unverified Commit 315c9fb7 authored by Paul Cercueil's avatar Paul Cercueil
Browse files

drm: bridge: it66121: Use regmap_noinc_read()



Use regmap_noinc_read() instead of reading the data from the DDC FIFO one
byte at a time.

Signed-off-by: default avatarPaul Cercueil <paul@crapouillou.net>
Reviewed-by: default avatarRobert Foss <robert.foss@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20221214125821.12489-4-paul@crapouillou.net
parent 334c8c1d
Loading
Loading
Loading
Loading
+6 −7
Original line number Diff line number Diff line
@@ -589,13 +589,12 @@ static int it66121_get_edid_block(void *context, u8 *buf,
		if (ret)
			return ret;

		do {
			ret = regmap_read(ctx->regmap, IT66121_DDC_RD_FIFO_REG, &val);
		ret = regmap_noinc_read(ctx->regmap, IT66121_DDC_RD_FIFO_REG,
					buf, cnt);
		if (ret)
			return ret;
			*(buf++) = val;
			cnt--;
		} while (cnt > 0);

		buf += cnt;
	}

	return 0;