Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 28 Aug 2008 15:55:32 -0400
From:      Robert Noland <rnoland@FreeBSD.org>
To:        "Paul B. Mahol" <onemda@gmail.com>
Cc:        freebsd-x11 <freebsd-x11@freebsd.org>, jimmiejaz@gmail.com
Subject:   Re: [CFT] drm updates
Message-ID:  <1219953332.2212.4.camel@squirrel.corp.cox.com>
In-Reply-To: <3a142e750808281145m3d49839fv4665066d1791e4e6@mail.gmail.com>
References:  <48B1A590.2040701@gmail.com> <1219674352.53929.2.camel@squirrel.corp.cox.com> <3a142e750808250928n612761cch69a3bd2ebf374f92@mail.gmail.com> <3a142e750808260741p224bd68aw52711eab7e76aa59@mail.gmail.com> <3a142e750808260851u13de6cf9jf2640c195f9be81e@mail.gmail.com> <1219769914.58043.11.camel@squirrel.corp.cox.com> <3a142e750808270307k237c5660ha98e8bcdfbddc4dc@mail.gmail.com> <1219850374.61484.7.camel@squirrel.corp.cox.com> <3a142e750808281007r42bbe4d0u53be9c0074386c10@mail.gmail.com> <1219944411.61066.5.camel@squirrel.corp.cox.com> <3a142e750808281145m3d49839fv4665066d1791e4e6@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--=-9UWLqcdf5XN8cwpAv1QY
Content-Type: multipart/mixed; boundary="=-7QlQA2nFUdqvyb4Tyy5T"


--=-7QlQA2nFUdqvyb4Tyy5T
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable

On Thu, 2008-08-28 at 20:45 +0200, Paul B. Mahol wrote:
> On 8/28/08, Robert Noland <rnoland@freebsd.org> wrote:
> > On Thu, 2008-08-28 at 19:07 +0200, Paul B. Mahol wrote:
> >> On 8/27/08, Robert Noland <rnoland@freebsd.org> wrote:
> >> > On Wed, 2008-08-27 at 12:07 +0200, Paul B. Mahol wrote:
> >> >> On 8/26/08, Robert Noland <rnoland@freebsd.org> wrote:
> >> >> > On Tue, 2008-08-26 at 17:51 +0200, Paul B. Mahol wrote:
> >> >> >> Here is more kernel debug info (after updating libdrm and testin=
g
> >> >> >> with
> >> >> >> glxgears)
> >> >> >
> >> >> > I don't think that the two issues are related, but try this patch=
...
> >> >> > It
> >> >> > should at least, resolve the issue below.
> >> >> >
> >> >> > robert.
> >> >>
> >> >> Issue bellow is fixed, previous problem still exist.
> >> >>
> >> >> textdump of panic when unloading drm attached.
> >> >
> >> > Ok, The locking semantics are a nightmare... Give this a try, it sho=
uld
> >> > correct both the previous issue as well as this one.
> >> >
> >> > robert.
> >> >
> >>=20
> >> Panic fixed, now only Xorg crashing when using glxgears (,...) remains=
 ;)
> >
> > Ok, what hardware are you using again?  Can you manually load drm
> > modules and set hw.dri.0.debug=3D1 and send me the debug output?
> >
> > robert.
>=20
> Hardware: "Mobile 945GM/GU Express Integrated Graphics Controller"
> Debug ouptut attached.

Alright, try this...  I was pointed at this from another thread, but
your trace confirms why it doesn't work, at least with your driver.

robert.

> I have two ktrace.out of Xorg and glxgears but I dont see point sending i=
t.
>=20
> >
> >> >>
> >> >> >> pid 7176 (Xorg), uid 0: exited on signal 6
> >> >> >> free_unr with the following non-sleepable locks held:
> >> >> >> exclusive sleep mutex drmdev (drmdev) r =3D 0 (0xc4783cec) locke=
d @
> >> >> >> /usr/local/src/sys/modules/drm/drm/../../../dev/drm/drm_irq.c:25=
6
> >> >> >> KDB: stack backtrace:
> >> >> >> db_trace_self_wrapper(c0b570bb,c43887cc,c07f0dd5,c4d79b8f,100,..=
.)
> >> >> >> at
> >> >> >> db_trace_self_wrapper+0x26
> >> >> >> kdb_backtrace(c4d79b8f,100,ffffffff,c0dcf79c,c4388800,...) at
> >> >> >> kdb_backtrace+0x29
> >> >> >> _witness_debugger(c0b5930a,c4388814,4,1,0,...) at _witness_debug=
ger
> >> >> >> +0x25
> >> >> >> witness_warn(5,0,c0b58e81,c4388838,c07a528c,...) at
> >> >> >> witness_warn+0x1c1
> >> >> >> free_unr(c49776c0,1,c4d79696,a8,c4783ef4,...) at free_unr+0x2b
> >> >> >> drm_drawable_free_all(c4783c00,c4d7bce0,c4d796d9,1ba,0,...) at
> >> >> >> drm_drawable_free_all+0x174
> >> >> >> drm_lastclose(c4646c80,1,c4d796d9,2e3,8,...) at drm_lastclose+0x=
df
> >> >> >> drm_close(c4b37000,3,2000,c4971230,c4388900,...) at drm_close+0x=
2ca
> >> >> >> giant_close(c4b37000,3,2000,c4971230,c4971230,...) at
> >> >> >> giant_close+0x67
> >> >> >> devfs_close(c4388948,3,c4d4d430,3,c4388968,...) at devfs_close+0=
x29a
> >> >> >> VOP_CLOSE_APV(c0c26380,c4388948,c0b61a19,124,c0c63f80,...) at
> >> >> >> VOP_CLOSE_APV+0xa5
> >> >> >> vn_close(c4d4d430,3,c4ad9700,c4971230,0,...) at vn_close+0xe4
> >> >> >> vn_closefile(c49df1c0,c4971230,c43889ec,c0784853,c49df1c0,...) a=
t
> >> >> >> vn_closefile+0xe9
> >> >> >> devfs_close_f(c49df1c0,c4971230,0,0,c49df1c0,...) at devfs_close=
_f
> >> >> >> +0x25
> >> >> >> _fdrop(c49df1c0,c4971230,c4388a20,c07f0c1c,0,c49712d4,c0dcf798,c=
0c317b0,c0b4f841,c51c452c,6a7,c0b4f841,c4388a48,c07b9fe0,c51c452c,8,c0b4f84=
1,6a7)
> >> >> >> at _fdrop+0x43
> >> >> >> closef(c49df1c0,c4971230,6a7,6a5,c4470340,...) at closef+0x290
> >> >> >> fdfree(c4971230,0,c0b5014d,102,c49712d4,...) at fdfree+0x387
> >> >> >> exit1(c4971230,1,c0b53f0a,aad,c0b4ed7f,...) at exit1+0x543
> >> >> >> sigexit(c4971230,1,c0b53f0a,a3d,c556baa8,...) at sigexit+0xaaf
> >> >> >> postsig(1,0,c0b587c6,df,c496d7d4,...) at postsig+0x1dd
> >> >> >> ast(c4388d38) at ast+0x37f
> >> >> >> doreti_ast() at doreti_ast+0x17
> >> >> >> uma_zalloc_arg: zone "16" with the following non-sleepable locks
> >> >> >> held:
> >> >> >> exclusive sleep mutex drmdev (drmdev) r =3D 0 (0xc4783cec) locke=
d @
> >> >> >> /usr/local/src/sys/modules/drm/drm/../../../dev/drm/drm_irq.c:25=
6
> >> >> >> KDB: stack backtrace:
> >> >> >> db_trace_self_wrapper(c0b570bb,c438874c,c07f0dd5,c4d79b8f,100,..=
.)
> >> >> >> at
> >> >> >> db_trace_self_wrapper+0x26
> >> >> >> kdb_backtrace(c4d79b8f,100,ffffffff,c0dcf79c,c4388780,...) at
> >> >> >> kdb_backtrace+0x29
> >> >> >> _witness_debugger(c0b5930a,c4388794,4,1,0,...) at _witness_debug=
ger
> >> >> >> +0x25
> >> >> >> witness_warn(5,0,c0b78fa6,c0b2b3ab,c0b5930a,...) at
> >> >> >> witness_warn+0x1c1
> >> >> >> uma_zalloc_arg(c1872960,0,102,2,1,...) at uma_zalloc_arg+0x34
> >> >> >> malloc(10,c0c34a40,102,c4388838,c07a528c,...) at malloc+0xd2
> >> >> >> free_unr(c49776c0,1,c4d79696,a8,c4783ef4,...) at free_unr+0x47
> >> >> >> drm_drawable_free_all(c4783c00,c4d7bce0,c4d796d9,1ba,0,...) at
> >> >> >> drm_drawable_free_all+0x174
> >> >> >> drm_lastclose(c4646c80,1,c4d796d9,2e3,8,...) at drm_lastclose+0x=
df
> >> >> >> drm_close(c4b37000,3,2000,c4971230,c4388900,...) at drm_close+0x=
2ca
> >> >> >> giant_close(c4b37000,3,2000,c4971230,c4971230,...) at
> >> >> >> giant_close+0x67
> >> >> >> devfs_close(c4388948,3,c4d4d430,3,c4388968,...) at devfs_close+0=
x29a
> >> >> >> VOP_CLOSE_APV(c0c26380,c4388948,c0b61a19,124,c0c63f80,...) at
> >> >> >> VOP_CLOSE_APV+0xa5
> >> >> >> vn_close(c4d4d430,3,c4ad9700,c4971230,0,...) at vn_close+0xe4
> >> >> >> vn_closefile(c49df1c0,c4971230,c43889ec,c0784853,c49df1c0,...) a=
t
> >> >> >> vn_closefile+0xe9
> >> >> >> devfs_close_f(c49df1c0,c4971230,0,0,c49df1c0,...) at devfs_close=
_f
> >> >> >> +0x25
> >> >> >> _fdrop(c49df1c0,c4971230,c4388a20,c07f0c1c,0,c49712d4,c0dcf798,c=
0c317b0,c0b4f841,c51c452c,6a7,c0b4f841,c4388a48,c07b9fe0,c51c452c,8,c0b4f84=
1,6a7)
> >> >> >> at _fdrop+0x43
> >> >> >> closef(c49df1c0,c4971230,6a7,6a5,c4470340,...) at closef+0x290
> >> >> >> fdfree(c4971230,0,c0b5014d,102,c49712d4,...) at fdfree+0x387
> >> >> >> exit1(c4971230,1,c0b53f0a,aad,c0b4ed7f,...) at exit1+0x543
> >> >> >> sigexit(c4971230,1,c0b53f0a,a3d,c556baa8,...) at sigexit+0xaaf
> >> >> >> postsig(1,0,c0b587c6,df,c496d7d4,...) at postsig+0x1dd
> >> >> >> ast(c4388d38) at ast+0x37f
> >> >> >> doreti_ast() at doreti_ast+0x17
> >> >> >> uma_zalloc_arg: zone "16" with the following non-sleepable locks
> >> >> >> held:
> >> >> >> exclusive sleep mutex drmdev (drmdev) r =3D 0 (0xc4783cec) locke=
d @
> >> >> >> /usr/local/src/sys/modules/drm/drm/../../../dev/drm/drm_irq.c:25=
6
> >> >> >> KDB: stack backtrace:
> >> >> >> db_trace_self_wrapper(c0b570bb,c438874c,c07f0dd5,c4d79b8f,100,..=
.)
> >> >> >> at
> >> >> >> db_trace_self_wrapper+0x26
> >> >> >> kdb_backtrace(c4d79b8f,100,ffffffff,c0dcf79c,c4388780,...) at
> >> >> >> kdb_backtrace+0x29
> >> >> >> _witness_debugger(c0b5930a,c4388794,4,1,0,...) at _witness_debug=
ger
> >> >> >> +0x25
> >> >> >> witness_warn(5,0,c0b78fa6,c0b2b3ab,c0b5930a,...) at
> >> >> >> witness_warn+0x1c1
> >> >> >> uma_zalloc_arg(c1872960,0,102,2,1,...) at uma_zalloc_arg+0x34
> >> >> >> malloc(10,c0c34a40,102,c4388838,c07a528c,...) at malloc+0xd2
> >> >> >> free_unr(c49776c0,1,c4d79696,a8,c4783ef4,...) at free_unr+0x66
> >> >> >> drm_drawable_free_all(c4783c00,c4d7bce0,c4d796d9,1ba,0,...) at
> >> >> >> drm_drawable_free_all+0x174
> >> >> >> drm_lastclose(c4646c80,1,c4d796d9,2e3,8,...) at drm_lastclose+0x=
df
> >> >> >> drm_close(c4b37000,3,2000,c4971230,c4388900,...) at drm_close+0x=
2ca
> >> >> >> giant_close(c4b37000,3,2000,c4971230,c4971230,...) at
> >> >> >> giant_close+0x67
> >> >> >> devfs_close(c4388948,3,c4d4d430,3,c4388968,...) at devfs_close+0=
x29a
> >> >> >> VOP_CLOSE_APV(c0c26380,c4388948,c0b61a19,124,c0c63f80,...) at
> >> >> >> VOP_CLOSE_APV+0xa5
> >> >> >> vn_close(c4d4d430,3,c4ad9700,c4971230,0,...) at vn_close+0xe4
> >> >> >> vn_closefile(c49df1c0,c4971230,c43889ec,c0784853,c49df1c0,...) a=
t
> >> >> >> vn_closefile+0xe9
> >> >> >> devfs_close_f(c49df1c0,c4971230,0,0,c49df1c0,...) at devfs_close=
_f
> >> >> >> +0x25
> >> >> >> _fdrop(c49df1c0,c4971230,c4388a20,c07f0c1c,0,c49712d4,c0dcf798,c=
0c317b0,c0b4f841,c51c452c,6a7,c0b4f841,c4388a48,c07b9fe0,c51c452c,8,c0b4f84=
1,6a7)
> >> >> >> at _fdrop+0x43
> >> >> >> closef(c49df1c0,c4971230,6a7,6a5,c4470340,...) at closef+0x290
> >> >> >> fdfree(c4971230,0,c0b5014d,102,c49712d4,...) at fdfree+0x387
> >> >> >> exit1(c4971230,1,c0b53f0a,aad,c0b4ed7f,...) at exit1+0x543
> >> >> >> sigexit(c4971230,1,c0b53f0a,a3d,c556baa8,...) at sigexit+0xaaf
> >> >> >> postsig(1,0,c0b587c6,df,c496d7d4,...) at postsig+0x1dd
> >> >> >> ast(c4388d38) at ast+0x37f
> >> >> >> doreti_ast() at doreti_ast+0x17
> >> >> >> drm0: [ITHREAD]
> >> >> >> pid 9156 (Xorg), uid 0: exited on signal 6
> >> >> >>
> >> >> >
> >> >
> >

--=-7QlQA2nFUdqvyb4Tyy5T
Content-Disposition: attachment; filename=drm-unlock-context.patch
Content-Transfer-Encoding: base64
Content-Type: text/x-patch; name=drm-unlock-context.patch; charset=us-ascii

ZGlmZiAtLWdpdCBhL2JzZC1jb3JlL2RybV9sb2NrLmMgYi9ic2QtY29yZS9kcm1fbG9jay5jDQpp
bmRleCA5OTQ1ODcxLi4zOGVlOTEwIDEwMDY0NA0KLS0tIGEvYnNkLWNvcmUvZHJtX2xvY2suYw0K
KysrIGIvYnNkLWNvcmUvZHJtX2xvY2suYw0KQEAgLTE3MywxMyArMTczLDE0IEBAIGludCBkcm1f
dW5sb2NrKHN0cnVjdCBkcm1fZGV2aWNlICpkZXYsIHZvaWQgKmRhdGEsIHN0cnVjdCBkcm1fZmls
ZSAqZmlsZV9wcml2KQ0KIAkJICAgIERSTV9DVVJSRU5UUElELCBsb2NrLT5jb250ZXh0KTsNCiAJ
CXJldHVybiBFSU5WQUw7DQogCX0NCisjaWYgMA0KIAkvKiBDaGVjayB0aGF0IHRoZSBjb250ZXh0
IHVubG9jayBiZWluZyByZXF1ZXN0ZWQgYWN0dWFsbHkgbWF0Y2hlcw0KIAkgKiB3aG8gY3VycmVu
dGx5IGhvbGRzIHRoZSBsb2NrLg0KIAkgKi8NCiAJaWYgKCFfRFJNX0xPQ0tfSVNfSEVMRChkZXYt
PmxvY2suaHdfbG9jay0+bG9jaykgfHwNCiAJICAgIF9EUk1fTE9DS0lOR19DT05URVhUKGRldi0+
bG9jay5od19sb2NrLT5sb2NrKSAhPSBsb2NrLT5jb250ZXh0KQ0KIAkJcmV0dXJuIEVJTlZBTDsN
Ci0NCisjZW5kaWYNCiAJRFJNX1NQSU5MT0NLKCZkZXYtPnRza19sb2NrKTsNCiAJaWYgKGRldi0+
bG9ja2VkX3Rhc2tfY2FsbCAhPSBOVUxMKSB7DQogCQlkZXYtPmxvY2tlZF90YXNrX2NhbGwoZGV2
KTsNCg==


--=-7QlQA2nFUdqvyb4Tyy5T--

--=-9UWLqcdf5XN8cwpAv1QY
Content-Type: application/pgp-signature; name=signature.asc
Content-Description: This is a digitally signed message part

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.9 (FreeBSD)

iEYEABECAAYFAki3ArQACgkQM4TrQ4qfROPxrQCfXCFcq5ncO3LJ6lZnsRGqYgbZ
ZvYAnjYWFAiCTUOo/ELZXQlCY4K98SAy
=+glI
-----END PGP SIGNATURE-----

--=-9UWLqcdf5XN8cwpAv1QY--




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1219953332.2212.4.camel>