All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rob Herring <robherring2-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: Olof Johansson <olof-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org>
Cc: rmk+kernel-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Barry Song <21cnbao-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	Shawn Guo <shawn.guo-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
Subject: Re: [PATCH] ARM: l2x0: fix compile error on !CONFIG_USE_OF
Date: Wed, 09 Nov 2011 14:14:42 -0600	[thread overview]
Message-ID: <4EBADF32.6040106@gmail.com> (raw)
In-Reply-To: <1320864823-5015-1-git-send-email-olof-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org>

On 11/09/2011 12:53 PM, Olof Johansson wrote:
> fae2b89ab1 (ARM: l2x0: add empty l2x0_of_init) adds a static inline
> function that returns -ENODEV, but at least on tegra cache-l2x0.h is
> included without errno.h being pulled in first, resulting in compile
> errors if OF isn't enabled:
> 
> In file included from arch/arm/mach-tegra/common.c:26:
> arch/arm/include/asm/hardware/cache-l2x0.h: In function 'l2x0_of_init':
> arch/arm/include/asm/hardware/cache-l2x0.h:110: error: 'ENODEV' undeclared (first use in this function)
> arch/arm/include/asm/hardware/cache-l2x0.h:110: error: (Each undeclared identifier is reported only once
> arch/arm/include/asm/hardware/cache-l2x0.h:110: error: for each function it appears in.)
> 
> Add errno.h to the include file to make it self-contained.
> 
> Signed-off-by: Olof Johansson <olof-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org>
> Cc: Rob Herring <rob.herring-bsGFqQB8/DxBDgjK7y7TUQ@public.gmane.org>

Sigh... I guess the platforms I built happened to include errno.h first.

Acked-by: Rob Herring <rob.herring-bsGFqQB8/DxBDgjK7y7TUQ@public.gmane.org>

> ---
>  arch/arm/include/asm/hardware/cache-l2x0.h |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
> 
> diff --git a/arch/arm/include/asm/hardware/cache-l2x0.h b/arch/arm/include/asm/hardware/cache-l2x0.h
> index 1db1143..7df239b 100644
> --- a/arch/arm/include/asm/hardware/cache-l2x0.h
> +++ b/arch/arm/include/asm/hardware/cache-l2x0.h
> @@ -20,6 +20,8 @@
>  #ifndef __ASM_ARM_HARDWARE_L2X0_H
>  #define __ASM_ARM_HARDWARE_L2X0_H
>  
> +#include <linux/errno.h>
> +
>  #define L2X0_CACHE_ID			0x000
>  #define L2X0_CACHE_TYPE			0x004
>  #define L2X0_CTRL			0x100

WARNING: multiple messages have this Message-ID (diff)
From: robherring2@gmail.com (Rob Herring)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: l2x0: fix compile error on !CONFIG_USE_OF
Date: Wed, 09 Nov 2011 14:14:42 -0600	[thread overview]
Message-ID: <4EBADF32.6040106@gmail.com> (raw)
In-Reply-To: <1320864823-5015-1-git-send-email-olof@lixom.net>

On 11/09/2011 12:53 PM, Olof Johansson wrote:
> fae2b89ab1 (ARM: l2x0: add empty l2x0_of_init) adds a static inline
> function that returns -ENODEV, but at least on tegra cache-l2x0.h is
> included without errno.h being pulled in first, resulting in compile
> errors if OF isn't enabled:
> 
> In file included from arch/arm/mach-tegra/common.c:26:
> arch/arm/include/asm/hardware/cache-l2x0.h: In function 'l2x0_of_init':
> arch/arm/include/asm/hardware/cache-l2x0.h:110: error: 'ENODEV' undeclared (first use in this function)
> arch/arm/include/asm/hardware/cache-l2x0.h:110: error: (Each undeclared identifier is reported only once
> arch/arm/include/asm/hardware/cache-l2x0.h:110: error: for each function it appears in.)
> 
> Add errno.h to the include file to make it self-contained.
> 
> Signed-off-by: Olof Johansson <olof@lixom.net>
> Cc: Rob Herring <rob.herring@calxeda.com>

Sigh... I guess the platforms I built happened to include errno.h first.

Acked-by: Rob Herring <rob.herring@calxeda.com>

> ---
>  arch/arm/include/asm/hardware/cache-l2x0.h |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
> 
> diff --git a/arch/arm/include/asm/hardware/cache-l2x0.h b/arch/arm/include/asm/hardware/cache-l2x0.h
> index 1db1143..7df239b 100644
> --- a/arch/arm/include/asm/hardware/cache-l2x0.h
> +++ b/arch/arm/include/asm/hardware/cache-l2x0.h
> @@ -20,6 +20,8 @@
>  #ifndef __ASM_ARM_HARDWARE_L2X0_H
>  #define __ASM_ARM_HARDWARE_L2X0_H
>  
> +#include <linux/errno.h>
> +
>  #define L2X0_CACHE_ID			0x000
>  #define L2X0_CACHE_TYPE			0x004
>  #define L2X0_CTRL			0x100

  parent reply	other threads:[~2011-11-09 20:14 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-09 18:53 [PATCH] ARM: l2x0: fix compile error on !CONFIG_USE_OF Olof Johansson
2011-11-09 18:53 ` Olof Johansson
     [not found] ` <1320864823-5015-1-git-send-email-olof-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org>
2011-11-09 20:14   ` Rob Herring [this message]
2011-11-09 20:14     ` Rob Herring
2011-11-17 13:41   ` Barry Song
2011-11-17 13:41     ` Barry Song

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=4EBADF32.6040106@gmail.com \
    --to=robherring2-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
    --cc=21cnbao-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=olof-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org \
    --cc=rmk+kernel-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org \
    --cc=shawn.guo-QSEj5FYQhm4dnm+yROfE0A@public.gmane.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.