Subject: [alpine-devel] mpv is broken

From: Alba Pompeo <[email-masked]>
Date: Thu, 21 Jan 2016 00:54:32 -0200

mpv is broken on latest release v3.3.1
 (+) Video --vid=1 (*) (h264)
 (+) Audio --aid=1 --alang=und (*) (aac)
libGL error: failed to open drm device: Permission denied
libGL error: failed to load driver: i965
libGL error: unable to load driver: swrast_dri.so
libGL error: failed to load driver: swrast
[vo/opengl/x11] X11 error: BadValue (integer parameter out of range
for operation)
[vo/opengl/x11] Type: 0, display: 0x43f43492980, resourceid: 0, serial: 37
[vo/opengl/x11] Error code: 2, request code: 9a, minor code: 3
[vo/opengl/x11] X11 error: GLXBadContext
[vo/opengl/x11] Type: 0, display: 0x43f43492980, resourceid: a00003, serial: 38
[vo/opengl/x11] Error code: aa, request code: 9a, minor code: 5
[vo/opengl/x11] X11 error: 0
[vo/opengl/x11] Type: 0, display: 0x43f43492980, resourceid: 0, serial: 38
[vo/opengl/x11] Error code: 0, request code: 9a, minor code: 1a
[vo/opengl] Could not set GLX context!

I looked on the archives and found a hint, that I should addgroup me
to video. But I already did that long before and the issue remains.

Ciao

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---

---

From: Isaac Dunham <[email-masked]>
Date: Wed, 20 Jan 2016 19:23:37 -0800

> to video. But I already did that long before and the issue remains.

ls -l /dev/dri/

I suspect that for unknown reasons, eudev isn't setting the proper group.

Currently mdev isn't either...Ah, mdev is only looking for the old
directory-free pathnames (card0 instead of dri/card0).
Adding this to mdev.conf should fix it for those who don't need eudev:
dri/*	root:video 0660

There may be a similar oversight in the eudev rules, or there might not.

HTH,
Isaac Dunham

---

---

From: Alba Pompeo <[email-masked]>
Date: Wed, 10 Feb 2016 12:36:28 -0200

Chromium also have the same error.
And I am sure I'm on the video group.
libGL error: failed to open drm device: Permission denied

---

---

From: Shiz <[email-masked]>
Date: Wed, 10 Feb 2016 16:55:21 +0100

> On 10 Feb 2016, at 15:36, Alba Pompeo <[email-masked]> wrote:
> 

I’ve been having the same issue with mdev, it somehow failing to set the
/dev/dri/* permissions properly despite configuration to the opposite.

Regardless, su -c 'chown -R root:video /dev/dri' fixes the issue, until you reboot.

- Shiz

---

From: Isaac Dunham <[email-masked]>
Date: Wed, 10 Feb 2016 23:23:45 -0800

> Regardless, su -c 'chown -R root:video /dev/dri' fixes the issue, until you reboot.

On my system (uses mdev), this line in mdev.conf solved it:
dri/.*	root:video 0660

If you have current busybox-initscripts from edge, this line is in
/etc/mdev.conf as packaged -- or /etc/mdev.conf.apk-new if you've edited
the config file.

If you are using eudev, THIS CANNOT HELP.

eudev uses its own rules, which apparently might have a similar issue
(ie, matching the regex dri/.* should be used instead of moving to dri/).
I am not an expert in (e)udev.

I do not recommend trying mdev-with-X on non-experimental systems.
If you want to try using mdev with X:
- disable X autostarting
- enable mdev, disable eudev
- apk add mdev-like-a-boss-xorg (and xf86-input-synaptics for laptops)
- reboot (so that you use the mdev-prepared /dev, rather than thinking
 it's working because of a stale udev-prepared dir).
- start X
- check that mouse and keyboard work

Thanks,
Isaac Dunham

---

---

From: Alba Pompeo <[email-masked]>
Date: Wed, 13 Apr 2016 06:31:05 -0300

It has passed 3 months and it's still not fixed.
I don't have root access in all my systems and it bothers me to be
unable to use mpv in those cases.
Can we please have this fixed?
Thanks.

---

---

From: Natanael Copa <[email-masked]>
Date: Wed, 13 Apr 2016 13:56:50 +0200

On Wed, 13 Apr 2016 06:31:05 -0300

> Can we please have this fixed?

I believe this fixed it (in edge):

http://git.alpinelinux.org/cgit/aports/commit/?id=61254e78ff3679e7de3f31d5a65378af50706371

I have now cherry-picked it to 3.3-stable

-nc

---

---

From: Alba Pompeo <[email-masked]>
Date: Wed, 13 Apr 2016 12:19:08 -0300

Thanks, it's fixed.

---