From: Andreas Schwab <schwab@linux-m68k.org>
To: Arnd Bergmann <arnd@arndb.de>
Cc: linux-kernel@vger.kernel.org, John Kacur <jkacur@redhat.com>,
Frederic Weisbecker <fweisbec@gmail.com>,
David Airlie <airlied@linux.ie>,
dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 1/3] drm: kill BKL from common code
Date: Tue, 24 Aug 2010 20:46:40 +0200 [thread overview]
Message-ID: <m262yzyhkf.fsf@igel.home> (raw)
In-Reply-To: <1278798701-11171-2-git-send-email-arnd@arndb.de> (Arnd Bergmann's message of "Sat, 10 Jul 2010 23:51:39 +0200")
Arnd Bergmann <arnd@arndb.de> writes:
> diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c
> index 4a66201..76d98f4 100644
> --- a/drivers/gpu/drm/drm_drv.c
> +++ b/drivers/gpu/drm/drm_drv.c
> @@ -506,9 +506,9 @@ long drm_ioctl(struct file *filp,
> if (ioctl->flags & DRM_UNLOCKED)
> retcode = func(dev, kdata, file_priv);
> else {
> - lock_kernel();
> + mutex_lock(&drm_global_mutex);
> retcode = func(dev, kdata, file_priv);
> - unlock_kernel();
> + mutex_unlock(&drm_global_mutex);
How is this supposed to work in the context of sleeping ioctls, like
drm_lock?
[drm:drm_ioctl], pid=2461, cmd=0x8008642a, nr=0x2a, dev 0xe200, auth=1
[drm:drm_lock], 1 (pid 2461) requests lock (0x80000003), flags = 0x00000000
[drm:drm_ioctl], pid=2520, cmd=0x8008642b, nr=0x2b, dev 0xe200, auth=1
# ps 2461 2520
PID TTY STAT TIME COMMAND
2461 tty7 Ss+ 0:01 /usr/bin/Xorg -br :0 vt7 -nolisten tcp -auth /var/lib
2520 pts/2 D+ 0:00 glxgears
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
next prev parent reply other threads:[~2010-08-24 18:46 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-10 21:51 [PATCH 0/3] further BKL removal Arnd Bergmann
2010-07-10 21:51 ` [PATCH 1/3] drm: kill BKL from common code Arnd Bergmann
2010-08-24 18:46 ` Andreas Schwab [this message]
2010-08-24 20:45 ` Arnd Bergmann
2010-07-10 21:51 ` [PATCH 2/3] Remove BKL from fs/locks.c Arnd Bergmann
2010-07-10 22:01 ` Christoph Hellwig
2010-07-11 10:31 ` Arnd Bergmann
2010-07-10 21:51 ` [PATCH 3/3] sound: push BKL into open functions Arnd Bergmann
2010-07-11 7:15 ` Jaroslav Kysela
2010-07-11 7:15 ` Jaroslav Kysela
2010-07-11 10:16 ` Arnd Bergmann
2010-07-12 15:53 ` Takashi Iwai
2010-07-12 15:53 ` Takashi Iwai
2010-07-12 17:53 ` [PATCH] sound/oss: convert to unlocked_ioctl Arnd Bergmann
2010-07-12 20:38 ` Takashi Iwai
2010-07-12 20:38 ` Takashi Iwai
2010-07-12 21:13 ` Arnd Bergmann
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=m262yzyhkf.fsf@igel.home \
--to=schwab@linux-m68k.org \
--cc=airlied@linux.ie \
--cc=arnd@arndb.de \
--cc=dri-devel@lists.freedesktop.org \
--cc=fweisbec@gmail.com \
--cc=jkacur@redhat.com \
--cc=linux-kernel@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.