Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b06f6a9d authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Dave Airlie
Browse files

drm/nouveau: use mdelay instead of large udelay constants



ARM cannot handle udelay for more than 2 miliseconds, so we
should use mdelay instead for those.

Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Cc: David Airlie <airlied@linux.ie>
Cc: Ben Skeggs <bskeggs@redhat.com>
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: default avatarDave Airlie <airlied@gmail.com>
parent 1ed7fad6
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -51,7 +51,8 @@ nv50_dac_sense(struct nv50_disp_priv *priv, int or, u32 loadval)
	const u32 doff = (or * 0x800);
	int load = -EINVAL;
	nv_wr32(priv, 0x61a00c + doff, 0x00100000 | loadval);
	udelay(9500);
	mdelay(9);
	udelay(500);
	nv_wr32(priv, 0x61a00c + doff, 0x80000000);
	load = (nv_rd32(priv, 0x61a00c + doff) & 0x38000000) >> 27;
	nv_wr32(priv, 0x61a00c + doff, 0x00000000);