linux-sh.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Russell King - ARM Linux <linux@arm.linux.org.uk>
To: linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH] mmc: omap_hsmmc: Restrict compilation to ARM
Date: Sun, 19 Jan 2014 10:02:35 +0000	[thread overview]
Message-ID: <20140119100235.GN27282@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <1390123794-26401-1-git-send-email-geert@linux-m68k.org>

On Sun, Jan 19, 2014 at 10:29:54AM +0100, Geert Uytterhoeven wrote:
> commit bcf24e1daa94f4c52ef7a3f657e43cc6bc50d46b ("mmc: omap_hsmmc: use the
> generic config for omap2plus devices"), enabled the build for other
> platforms for compile testing.
> 
> sh-allmodconfig now fails with:
> 
>     include/linux/omap-dma.h:171:8: error: expected identifier before numeric constant
>     make[4]: *** [drivers/mmc/host/omap_hsmmc.o] Error 1
> 
> This happens because sh #defines "CCR", which is one of the enum values in
> include/linux/omap-dma.h.
> 
> I expect a similar failure on blackfin, which also has #define CCR.
> 
> Restrict the build to ARM to fix this.

This isn't the right fix.  When this has happened on ARM in the past, we've
had a lot of pressure to change the definition since it's far too generic.

"CCR" should only be used for stuff which is restricted to (eg) one driver,
and not in some system wide header file included by lots of files.

In the case of OMAP, the unfortunate thing is that include/linux/omap-dma.h
was moved lock stock and barrel out of the ARM-private includes.  It
really needs splitting up in two - one which drivers are expected to
include, and the other for shared definitions between arch/arm/*omap*/dma.c
and drivers/dma/omap-dma.c.

Even so, "CCR" will still exist - but will be localised to the compilation
units which need it.  The same should happen with SH.

So, as for this patch, that's a NAK.

-- 
FTTC broadband for 0.8mile line: 5.8Mbps down 500kbps up.  Estimation
in database were 13.1 to 19Mbit for a good line, about 7.5+ for a bad.
Estimate before purchase was "up to 13.2Mbit".

  reply	other threads:[~2014-01-19 10:02 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-19  9:29 [PATCH] mmc: omap_hsmmc: Restrict compilation to ARM Geert Uytterhoeven
2014-01-19 10:02 ` Russell King - ARM Linux [this message]
2014-01-24 16:53   ` [PATCH/RFC] dmaengine: omap-dma: split header file Balaji T K
2014-01-24 16:54     ` Balaji T K
2014-02-04 12:48     ` Balaji T K

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=20140119100235.GN27282@n2100.arm.linux.org.uk \
    --to=linux@arm.linux.org.uk \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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;
as well as URLs for NNTP newsgroup(s).