public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@osdl.org>
To: Paul Fulghum <paulkf@microgate.com>
Cc: paulkf@microgate.com, jeff@garzik.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] fix generic HDLC synclink mismatch build error
Date: Wed, 7 Jun 2006 18:28:08 -0700	[thread overview]
Message-ID: <20060607182808.a230e5ee.akpm@osdl.org> (raw)
In-Reply-To: <44877659.2020103@microgate.com>

On Wed, 07 Jun 2006 19:59:05 -0500
Paul Fulghum <paulkf@microgate.com> wrote:

> Andrew:
> 
> Maybe you can lend some insight on what I should do.
> 
> I have posted multiple, working patches to correct
> the build errors resultsing from random kernel configs.
> 
> But we appear to be in perpetual micromanagement by committee
> mode where different people are giving conflicting
> feedback of the "that's ugly" or "you shouldn't do that" kind.
> 
> I'm happy to accept any *patch* anyone wants to post
> that corrects the build errors *and* does not break
> the driver by removing the ability to optionally include
> generic HDLC support in the synclink drivers *and*
> is accepted by everyone here. Nothing that meets
> those requirements has been posted yet.
> 
> (Randy's last patch comes as close as my last patch, but
> Jeff says any code using conditional configuration is wrong
> so that removes any patch posted so far)
> 
> I'm also happy to accept the status quo, the
> driver works fine.
> 
> So where do we go from here?

Well your patch looked reasonable, except it muddies the CONFIG_foo
namespace.  So could you rework it thusly:


- Change all instances of

#ifdef CONFIG_HDLC
	<stuff>
#endif

to

#ifdef HDLC_ENABLED
	<stuff>
#endif


then do

#if defined(CONFIG_HDLC) || (defined(CONFIG_HDLC_MODULE) && defined(CONFIG_SYNCLINK_MODULE))
#define HDLC_ENABLED
#endif

or whatever?



Or, better, (but semi off-topic):


#if HDLC_ENABLED
	<stuff>
#endif

#if defined(CONFIG_HDLC) || (defined(CONFIG_HDLC_MODULE) && defined(CONFIG_SYNCLINK_MODULE))
#define HDLC_ENABLED 1
#else
#define HDLC_ENABLED 0
#endif

Because then a) you'll get a warning if someone already defined
HDLC_ENABLED and b) you'll get a warning if you mistype `#if HLDC_ENABLED'

  reply	other threads:[~2006-06-08  1:28 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-07 15:42 [PATCH] fix generic HDLC synclink mismatch build error Paul Fulghum
2006-06-07 21:31 ` Randy.Dunlap
2006-06-07 21:43   ` Paul Fulghum
2006-06-07 21:48     ` Randy.Dunlap
2006-06-07 22:00       ` Paul Fulghum
2006-06-09 15:47   ` Paul Fulghum
2006-06-09 16:00     ` Roman Zippel
2006-06-09 16:16       ` Paul Fulghum
2006-06-09 16:37         ` Roman Zippel
2006-06-09 16:44           ` Paul Fulghum
2006-06-07 22:58 ` Roman Zippel
2006-06-08  0:23   ` Paul Fulghum
2006-06-08  2:38     ` Randy.Dunlap
2006-06-07 23:02 ` Jeff Garzik
2006-06-08  0:20   ` Paul Fulghum
2006-06-08  0:59     ` Paul Fulghum
2006-06-08  1:28       ` Andrew Morton [this message]
2006-06-08  1:52         ` Paul Fulghum
2006-06-08 13:20         ` Paul Fulghum

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20060607182808.a230e5ee.akpm@osdl.org \
    --to=akpm@osdl.org \
    --cc=jeff@garzik.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=paulkf@microgate.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox