mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* Locking question for DRM
@ 2010-04-23 10:22 Alan Cox
  2010-04-23 10:24 ` Dave Airlie
  0 siblings, 1 reply; 5+ messages in thread
From: Alan Cox @ 2010-04-23 10:22 UTC (permalink / raw)
  To: Dave Airlie, dri-devel, linux-kernel


Various bits of the DRM deal with minor->master:

In the case of the open helper its protected by the struct mutex.

In the release path it's protected on some paths, but not this one ...

     /* if the master has gone away we can't do anything with the lock */
        if (file_priv->minor->master)
                drm_master_release(dev, filp);

and I can't see what makes this safe if the drm_release for the master
and a client occur at the same time ?

The setmaster/dropmaster ioctl seems similar - the various conditional
checks are not protected from parallel changes occuring during their
execution.

Is this a bug or is something clever afoot ?

Alan

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2010-04-23 10:55 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-04-23 10:22 Locking question for DRM Alan Cox
2010-04-23 10:24 ` Dave Airlie
2010-04-23 10:37   ` Alan Cox
2010-04-23 10:44     ` Dave Airlie
2010-04-23 11:00       ` Alan Cox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®