All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrew Dyer <amdyer@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] [PATCH] fix imx-regs.h compilation with ELDK-4.0
Date: Mon, 12 Feb 2007 14:23:15 -0600	[thread overview]
Message-ID: <c166aa9f0702121223p11ee8273q548396cd8bdf7860@mail.gmail.com> (raw)

Compiling cpu/arm920t/imx/generic.c under ELDK-4.0 fails with a bunch
of invalid lvalue errors.    The patch below fixes this.

Signed-off-by: Andrew Dyer <amdyer@gmail.com>

diff --git a/include/asm-arm/arch-imx/imx-regs.h
b/include/asm-arm/arch-imx/imx-regs.h
index 318de22..9ec6d03 100644
--- a/include/asm-arm/arch-imx/imx-regs.h
+++ b/include/asm-arm/arch-imx/imx-regs.h
@@ -8,9 +8,7 @@

 # ifndef __ASSEMBLY__
 #  define __REG(x)     (*((volatile u32 *)(x)))
-# define __REG2(x,y)   \
-       ( __builtin_constant_p(y) ? (__REG((x) + (y))) \
-                         : (*(volatile u32 *)((u32)&__REG(x) + (y))) )
+#  define __REG2(x,y)  (*(volatile u32 *)((u32)&__REG(x) + (y)))
 # else
 #  define __REG(x) (x)
 #  define __REG2(x,y) ((x)+(y))


-- 
Hardware, n.:
        The parts of a computer system that can be kicked.

                 reply	other threads:[~2007-02-12 20:23 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=c166aa9f0702121223p11ee8273q548396cd8bdf7860@mail.gmail.com \
    --to=amdyer@gmail.com \
    --cc=u-boot@lists.denx.de \
    /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.