linux-mips
[Top] [All Lists]

Re: xtime declaration

To: Bryan Chua <chua@ayrnetworks.com>
Subject: Re: xtime declaration
From: Ralf Baechle <ralf@oss.sgi.com>
Date: Fri, 3 Aug 2001 02:45:01 +0200
Cc: linux-mips@oss.sgi.com
In-reply-to: <3B699126.E1B5F5E0@ayrnetworks.com>; from chua@ayrnetworks.com on Thu, Aug 02, 2001 at 10:43:02AM -0700
References: <3B699126.E1B5F5E0@ayrnetworks.com>
Sender: owner-linux-mips@oss.sgi.com
User-agent: Mutt/1.2.5i
On Thu, Aug 02, 2001 at 10:43:02AM -0700, Bryan Chua wrote:

> Has anyone else come across a compile error:
> 
> mips-linux-gcc -I /local/chua/public/linux-mips-latest/include/asm/gcc
> -D__KERNEL__ -I/local/chua/public/linux-mips-latest/include -Wall
> -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strict-aliasing -G 0
> -mno-abicalls -fno-pic -mcpu=r5000 -mips2 -Wa,--trap -pipe    -c -o
> timer.o timer.c
> timer.c:35: conflicting types for `xtime'
> /local/chua/public/linux-mips-latest/include/linux/sched.h:540: previous
> declaration of `xtime'
> 
> in include/linux/sched.h:
> extern struct timeval xtime;
> 
> int timer.c:
> volatile struct timeval xtime __attribute__ ((aligned (16)));
> 
> I am using gcc 3.0 and binutils 2.11.2, both of the released versions.
> I do not know if my kernel actually runs yet with this toolchain...

That's a bug which got fixed in the latest kernels by removing the
volatile from the sched.h declaration.

  Ralf

<Prev in Thread] Current Thread [Next in Thread>