From mboxrd@z Thu Jan 1 00:00:00 1970 From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ@public.gmane.org Subject: [Bug 96836] Kernel unaligned access at TPC[105d9fb4] nvkm_instobj_wr32+0x14/0x20 [nouveau] Date: Sun, 10 Jul 2016 03:02:18 +0000 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0467337425==" Return-path: In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: nouveau-bounces-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org Sender: "Nouveau" To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org List-Id: nouveau.vger.kernel.org --===============0467337425== Content-Type: multipart/alternative; boundary="14681197380.794Ae2b72.20981"; charset="UTF-8" --14681197380.794Ae2b72.20981 Date: Sun, 10 Jul 2016 03:02:18 +0000 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://bugs.freedesktop.org/ Auto-Submitted: auto-generated https://bugs.freedesktop.org/show_bug.cgi?id=3D96836 --- Comment #15 from Ilia Mirkin --- (In reply to Ilia Mirkin from comment #14) > OK, well let's start small. One source of problems is that we have >=20 > drivers/gpu/drm/nouveau/nouveau_bios.h:#define ROM16(x) le16_to_cpu(*(u16 > *)&(x)) >=20 > Which can only work on aligned pointers x, but it gets called with unalig= ned > offsets in nouveau_bios.c >=20 > Can you try changing that to >=20 > #define ROM16(x) get_unaligned_le16(&(x)) >=20 > I'm guessing that will help with the first group of unaligned traps. Oh, and same treatment for ROM32 of course (and ROM64 while you're at it, b= ut that never gets called from what I can tell). --=20 You are receiving this mail because: You are the assignee for the bug.= --14681197380.794Ae2b72.20981 Date: Sun, 10 Jul 2016 03:02:18 +0000 MIME-Version: 1.0 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://bugs.freedesktop.org/ Auto-Submitted: auto-generated

Commen= t # 15 on bug 96836<= /a> from Ilia Mirkin
(In reply to Ilia Mirkin from comment #14)
> OK, well let's start small. One source of proble=
ms is that we have
>=20
> drivers/gpu/drm/nouveau/nouveau_bios.h:#define ROM16(x) le16_to_cpu(*(=
u16
> *)&(x))
>=20
> Which can only work on aligned pointers x, but it gets called with una=
ligned
> offsets in nouveau_bios.c
>=20
> Can you try changing that to
>=20
> #define ROM16(x) get_unaligned_le16(&(x))
>=20
> I'm guessing that will help with the first group of unaligned traps.

Oh, and same treatment for ROM32 of course (and ROM64 while you're at it, b=
ut
that never gets called from what I can tell).


You are receiving this mail because:
  • You are the assignee for the bug.
= --14681197380.794Ae2b72.20981-- --===============0467337425== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KTm91dmVhdSBt YWlsaW5nIGxpc3QKTm91dmVhdUBsaXN0cy5mcmVlZGVza3RvcC5vcmcKaHR0cHM6Ly9saXN0cy5m cmVlZGVza3RvcC5vcmcvbWFpbG1hbi9saXN0aW5mby9ub3V2ZWF1Cg== --===============0467337425==--