From: Vic Lee <llyzs.vic@gmail.com>
To: dri-devel@lists.freedesktop.org
Subject: any reason drmDropMaster() has to be root?
Date: Wed, 11 Apr 2012 11:15:50 +0800 [thread overview]
Message-ID: <4F84F766.5030002@gmail.com> (raw)
Hi Everyone,
I am referring to this line in drm_drv.c in drm module:
DRM_IOCTL_DEF(DRM_IOCTL_DROP_MASTER, drm_dropmaster_ioctl, DRM_ROOT_ONLY)
I can understand that set_master requires root, but if the process is
already master and just want to drop itself from master, I don't see any
point why this has to be root. Could anyone clarify this? If not, I
suggest to change drop_master to DRM_AUTH only.
My use case is like this: I have an application which will start before
X starts, and this app will internally call drmOpen(). Since it's the
first app to open the gpu it automatically becomes master, but then X
won't start afterwards because X requires master for KMS to work. So in
the application I must call drmDropMaster() after drmOpen(), but then I
have to run the application as root just in order to drop master.
Thanks in advanced.
Vic
reply other threads:[~2012-04-11 3:15 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4F84F766.5030002@gmail.com \
--to=llyzs.vic@gmail.com \
--cc=dri-devel@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox