[PATCH 1/2] fb: drop defines that aren't used/necessary anymore.

Mark Kettenis mark.kettenis at xs4all.nl
Tue Mar 29 01:13:33 PDT 2011


> Date: Tue, 29 Mar 2011 09:55:56 +0200 (CEST)
> From: Mark Kettenis <mark.kettenis at xs4all.nl>
> 
> > From: Dave Airlie <airlied at gmail.com>
> > Date: Tue, 29 Mar 2011 14:26:43 +1000
> > 
> > From: Dave Airlie <airlied at redhat.com>
> > 
> > This was generated by:
> > cd fb
> > coan source --replace -DFB_SCREEN_PRIVATE -DFB_24BIT -DFB_24_32BIT -DFB_SCREEN_PRIVATE -UFBNOPIXADDR -UFBNO24BIT -UFBNO24_32 *.[ch]
> 
> Unfortunately this sort of automatically generated diffs have some
> drawbacks...
> 
> > diff --git a/fb/fb.h b/fb/fb.h
> > index 021a940..e73de3c 100644
> > --- a/fb/fb.h
> > +++ b/fb/fb.h
> > @@ -98,20 +98,12 @@
> >  #error "GLYPHPADBYTES must be 4"
> >  #endif
> 
> ...since they leave behind comments like the one below..
> 
> >  /* whether to bother to include 24bpp support */
> > -#ifndef FBNO24BIT
> > -#define FB_24BIT
> > -#endif
> >  
> 
> ...and the one below...
> 
> >  /*
> >   * Unless otherwise instructed, fb includes code to advertise 24bpp
> >   * windows with 32bpp image format for application compatibility
> >   */
> >  
> > -#ifdef FB_24BIT
> > -#ifndef FBNO24_32
> > -#define FB_24_32BIT
> > -#endif
> > -#endif
> 
> Both comments can probably simply be removed.

Oh, and otherwise this diff looks good.  I still remember being
confused by the #ifdef maze when I fixed some buffer overflows in this
code a couple of years ago.


More information about the xorg-devel mailing list