Re: [V9fs-developer] Re: [PATCH] v9fs: print 9p messages

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



"David Leimbach" <[email protected]> wrote:
>
> > Also, those macro names:
>  >
>  > #define DEBUG_ERROR             (1<<0)
>  > #define DEBUG_CURRENT           (1<<1)
>  > #define DEBUG_9P                (1<<2)
>  > #define DEBUG_VFS               (1<<3)
>  > #define DEBUG_CONV              (1<<4)
>  > #define DEBUG_MUX               (1<<5)
>  > #define DEBUG_TRANS             (1<<6)
>  > #define DEBUG_SLABS             (1<<7)
>  > #define DEBUG_FCALL             (1<<8)
>  >
>  > are quite poorly chosen.  If someone else were to make a similarly poor
>  > naming choice there would be collisions.
> 
> 
> 
>  Would
>  #define 9P_DEBUG_ERROR
>  ...
> 
>  be better?  it seems they should be better "namespaced".

Well, "P9" would have a better chance of compiing ;)

But yes, that's how it should have been from the outset.  Whether you want
to do it now depends upon whether you want to put up with that much churn.

If you _are_ prepared to churn the code that much then it would be a good
time to think about perhaps permitting all that debug code to be omitted
for non-debug builds.  Make the various tests evaluate to constant zero if
!debug and don't include this newly-added file in non-debug builds at all.

It's all rather low-priority stuff though.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux