From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chris Wilson Subject: Re: [PATCH] drm: Pretty print out the reason for rejecting the mode Date: Tue, 05 Apr 2011 22:32:14 +0100 Message-ID: References: <1302036615-14998-1-git-send-email-chris@chris-wilson.co.uk> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1253502130==" Return-path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by gabe.freedesktop.org (Postfix) with ESMTP id 37E8A9E794 for ; Tue, 5 Apr 2011 14:32:18 -0700 (PDT) In-Reply-To: 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 Cc: dri-devel@lists.freedesktop.org List-Id: dri-devel@lists.freedesktop.org --===============1253502130== Content-Type: text/plain On Tue, 5 Apr 2011 23:06:19 +0200, Marcin Ślusarz wrote: > 2011/4/5 Chris Wilson : > > Signed-off-by: Chris Wilson > > --- > >  drivers/gpu/drm/drm_modes.c |   52 +++++++++++++++++++++++++++++++++++++++++- > >  1 files changed, 50 insertions(+), 2 deletions(-) > > > > diff --git a/drivers/gpu/drm/drm_modes.c b/drivers/gpu/drm/drm_modes.c > > index 25bf873..b3e07ac 100644 > > --- a/drivers/gpu/drm/drm_modes.c > > +++ b/drivers/gpu/drm/drm_modes.c > > @@ -853,6 +853,52 @@ void drm_mode_validate_clocks(struct drm_device *dev, > >  } > >  EXPORT_SYMBOL(drm_mode_validate_clocks); > > > > +static const char *mode_status_to_string(enum drm_mode_status status) > > +{ > > +       const char *strings[] = { > > + static? Yes, it should be. I wonder if the compiler is smart enough (smarter than me) for that to make no difference in this case... > > +               [MODE_OK] = "OK", > > +               [MODE_HSYNC] = "hsync out of range", > > +               [MODE_VSYNC] = "vsync out of range", > > +               [MODE_H_ILLEGAL] = "illegal horizontal timings", > > +               [MODE_V_ILLEGAL] = "illegal vertical timings", > > +               [MODE_BAD_WIDTH] = "requires an unsupported linepitch", > > +               [MODE_NOMODE] = "no mode with a maching name", > > s/maching/matching/ Cut'n'paste typo. Another patch for include/drm/drm_crtc.h required! Thanks, -Chris -- Chris Wilson, Intel Open Source Technology Centre --===============1253502130== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/dri-devel --===============1253502130==--