From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chris Wilson Subject: Re: [PATCH v4] drm/i915: clarify semaphore-ring interaction Date: Mon, 21 May 2012 09:44:02 +0100 Message-ID: <1337589849_155240@CP5-2952> References: <1337521955-13626-1-git-send-email-ben@bwidawsk.net> <1337528738-16632-1-git-send-email-ben@bwidawsk.net> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from fireflyinternet.com (smtp.fireflyinternet.com [109.228.6.236]) by gabe.freedesktop.org (Postfix) with ESMTP id E36079EE99 for ; Mon, 21 May 2012 01:44:16 -0700 (PDT) In-Reply-To: <1337528738-16632-1-git-send-email-ben@bwidawsk.net> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org Errors-To: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org To: intel-gfx@lists.freedesktop.org Cc: Ben Widawsky List-Id: intel-gfx@lists.freedesktop.org On Sun, 20 May 2012 08:45:38 -0700, Ben Widawsky wrote: > After Daniel split out this code, I think this makes more sense, and > looks nicer. Also added some comments to help the situation. > > v2: Make signal_mbox be all rings for symmetric-ness. > v3: submitted the wrong version of the patch before. > v2 had an issue with odd number of rings. The fix is to always emit an > even number of instructions to the ring with mbox updates. > v4: I suck. The code should send out mbox updates for NUM_RINGS-1 * > number of commands. Instead of NUM_RINGS * number of commands-1. > -ret = intel_ring_begin(ring, round_up((I915_NUM_RINGS) * 3, 2) + 4); > +ret = intel_ring_begin(ring, round_up((I915_NUM_RINGS-1) * 4, 2) + 4); I'm honestly less enthralled about v4. I'd rather see that as a separate preparatory patch so that it is put into context. -Chris -- Chris Wilson, Intel Open Source Technology Centre