From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chris Wilson Subject: Re: [PATCH 08/37] drm/i915: add DP_TP_STATUS registers Date: Thu, 22 Mar 2012 10:47:03 +0000 Message-ID: References: <1332378612-3814-1-git-send-email-eugeni.dodonov@intel.com> <1332378612-3814-9-git-send-email-eugeni.dodonov@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by gabe.freedesktop.org (Postfix) with ESMTP id EAA189E79C for ; Thu, 22 Mar 2012 03:47:08 -0700 (PDT) In-Reply-To: <1332378612-3814-9-git-send-email-eugeni.dodonov@intel.com> 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: Eugeni Dodonov List-Id: intel-gfx@lists.freedesktop.org On Wed, 21 Mar 2012 22:09:43 -0300, Eugeni Dodonov wrote: > There is one set of those registers for each port. Looks like we need an enum port in addition to enum plane and enum pipe. And a _PORT() switcher. The idea behind having separate PIPE, PLANE, PORT macros was that eventually we would put a BUILD_BUG_ON(typeof(&x)!=typeof(enum pipe *)) and so catch misuse of pipe versus plane (a common bug in the bad old days). However, that requires the code base being cleansed of all the int plane, port; -Chris -- Chris Wilson, Intel Open Source Technology Centre