From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Vetter Subject: Re: [PATCH 2/3] drm: make DRM_UNLOCKED ioctls with their own mutex Date: Wed, 26 Oct 2011 09:47:41 +0200 Message-ID: <20111026074741.GC2889@phenom.ffwll.local> References: <1319595614-9098-1-git-send-email-ihadzic@research.bell-labs.com> <1319595614-9098-3-git-send-email-ihadzic@research.bell-labs.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail-wy0-f177.google.com (mail-wy0-f177.google.com [74.125.82.177]) by gabe.freedesktop.org (Postfix) with ESMTP id 289B49EF86 for ; Wed, 26 Oct 2011 00:46:49 -0700 (PDT) Received: by wyg8 with SMTP id 8so1628521wyg.36 for ; Wed, 26 Oct 2011 00:46:49 -0700 (PDT) Content-Disposition: inline In-Reply-To: <1319595614-9098-3-git-send-email-ihadzic@research.bell-labs.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org Errors-To: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org To: Ilija Hadzic Cc: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org On Tue, Oct 25, 2011 at 10:20:13PM -0400, Ilija Hadzic wrote: > drm_getmap, drm_getclient and drm_getstats are all > protected with their own mutex (dev->struct_mutex) > no need to hold global mutex; make them DRM_UNLOCKED > > Signed-off-by: Ilija Hadzic Just to check before I dig into reviewing this: Have you check all the other users of these data structure that these functions touch whether they don't accidentally rely on the global lock being taken? Just because there's some locking around doesn't mean it actually protects much ... I ask because I've just recently waded through the non-kms drm cruft again and there's some horrible stuff there. Yours, Daniel -- Daniel Vetter Mail: daniel@ffwll.ch Mobile: +41 (0)79 365 57 48