From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ville =?iso-8859-1?Q?Syrj=E4l=E4?= Subject: Re: [PATCH 01/10] drm/i915: Grab struct_mutex around all FBC updates Date: Thu, 21 Nov 2013 12:49:26 +0200 Message-ID: <20131121104926.GE7819@intel.com> References: <1383771745-22463-1-git-send-email-ville.syrjala@linux.intel.com> <1383771745-22463-2-git-send-email-ville.syrjala@linux.intel.com> <20131120223708.GA4234@bratislava.jf.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by gabe.freedesktop.org (Postfix) with ESMTP id 46C94FB7D9 for ; Thu, 21 Nov 2013 02:49:30 -0800 (PST) Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces@lists.freedesktop.org Errors-To: intel-gfx-bounces@lists.freedesktop.org To: Daniel Vetter Cc: intel-gfx List-Id: intel-gfx@lists.freedesktop.org On Thu, Nov 21, 2013 at 09:22:43AM +0100, Daniel Vetter wrote: > On Wed, Nov 20, 2013 at 11:39 PM, Rodrigo Vivi w= rote: > > On Wed, Nov 06, 2013 at 11:02:16PM +0200, ville.syrjala@linux.intel.com= wrote: > >> From: Ville Syrj=E4l=E4 > >> > >> We need some protection for the FBC state, and since struct_mutex > >> is it currently in most places, make sure all FBC update/disable > >> calles are protected by it. > > > > Why don't you create a new mutex only for fbc update? > = > Yeah, if it's not core gem state please don't spread the usage of > dev->struct_mutex. Eventually we need to slash that one into pieces, > but until that happens making things worse doesn't help. I don't think I'm making things worse. struct_mutex is the lock that protects the fbc state currently, except we forgot to grab it in a some places. I'd rather fix this first, and then as a followup someone can start to think about using a new lock for fbc. -- = Ville Syrj=E4l=E4 Intel OTC