From mboxrd@z Thu Jan 1 00:00:00 1970 From: bugzilla-daemon@freedesktop.org Subject: [Bug 109977] Segmentation fault in drmParsePlatformDeviceInfo Date: Tue, 12 Mar 2019 11:22:46 +0000 Message-ID: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2009279390==" Return-path: Received: from culpepper.freedesktop.org (culpepper.freedesktop.org [IPv6:2610:10:20:722:a800:ff:fe98:4b55]) by gabe.freedesktop.org (Postfix) with ESMTP id C166589CD9 for ; Tue, 12 Mar 2019 11:22:46 +0000 (UTC) List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org --===============2009279390== Content-Type: multipart/alternative; boundary="15523897660.5E55305E.32655" Content-Transfer-Encoding: 7bit --15523897660.5E55305E.32655 Date: Tue, 12 Mar 2019 11:22:46 +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=3D109977 Bug ID: 109977 Summary: Segmentation fault in drmParsePlatformDeviceInfo Product: DRI Version: XOrg git Hardware: All OS: All Status: NEW Severity: normal Priority: medium Component: libdrm Assignee: dri-devel@lists.freedesktop.org Reporter: ichgeh@imkreisrum.de Created attachment 143633 --> https://bugs.freedesktop.org/attachment.cgi?id=3D143633&action=3Dedit [PATCH libdrm] xf86drm: Fix segmentation fault while parsing device info Since commit ee798b98479709acdd8d1492689dc93c1a62f239 (xf85drm: de-duplicate drmParse{Platform.Host1x}{Bus,Device}Info) I encounter a segfault at line 3632: *compatible[i] =3D tmp_name; Libdrm segfaults as soon as i>0.=20 This was encountered on armhf platform (Allwinner A10) with kernel 5.0 including drm-misc-next and the lima driver (https://gitlab.freedesktop.org/lima/linux/commits/lima-drm-misc-next-20190= 309) and the lima mesa branch (https://gitlab.freedesktop.org/lima/mesa) while running glmark2-es2-drm and kmscube. You can see the original issue including backtrace and strace reported here: https://gitlab.freedesktop.org/lima/mesa/issues/80#note_129271 The attached patch fixes it. --=20 You are receiving this mail because: You are the assignee for the bug.= --15523897660.5E55305E.32655 Date: Tue, 12 Mar 2019 11:22:46 +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
Bug ID 109977
Summary Segmentation fault in drmParsePlatformDeviceInfo
Product DRI
Version XOrg git
Hardware All
OS All
Status NEW
Severity normal
Priority medium
Component libdrm
Assignee dri-devel@lists.freedesktop.org
Reporter ichgeh@imkreisrum.de

Created attachment 143633 [details]
[PATCH libdrm] xf86drm: Fix segmentation fault while parsing device  info

Since commit ee798b98479709acdd8d1492689dc93c1a62f239 (xf85drm: de-duplicate
drmParse{Platform.Host1x}{Bus,Device}Info)

I encounter a segfault at line 3632:

     *compatible[i] =3D tmp_name;

Libdrm segfaults as soon as i>0.=20

This was encountered on armhf platform (Allwinner A10) with kernel 5.0
including drm-misc-next and the lima driver
(https://gitlab.freedesktop.org/lima/linux/commits/lima-drm-=
misc-next-20190309)
and the lima mesa branch (https://gitlab.freedesktop.org/lima/mesa) while
running glmark2-es2-drm and kmscube.

You can see the original issue including backtrace and strace reported here:
=
https://gitlab.freedesktop.org/lima/mesa/issues/80#note_129271

The attached patch fixes it.


You are receiving this mail because:
  • You are the assignee for the bug.
= --15523897660.5E55305E.32655-- --===============2009279390== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KZHJpLWRldmVs IG1haWxpbmcgbGlzdApkcmktZGV2ZWxAbGlzdHMuZnJlZWRlc2t0b3Aub3JnCmh0dHBzOi8vbGlz dHMuZnJlZWRlc2t0b3Aub3JnL21haWxtYW4vbGlzdGluZm8vZHJpLWRldmVs --===============2009279390==--