linux-mips
[Top] [All Lists]

Re: compilation problem with kernel 2.6.15

To: linux-mips@linux-mips.org
Subject: Re: compilation problem with kernel 2.6.15
From: peter fuerst <pf@net.alphadv.de>
Date: Wed, 29 Mar 2006 01:06:48 +0200 (CEST)
In-reply-to: <20060328143708.57991.qmail@web53507.mail.yahoo.com>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <20060328143708.57991.qmail@web53507.mail.yahoo.com>
Reply-to: pf@net.alphadv.de
Sender: linux-mips-bounce@linux-mips.org

On Tue, 28 Mar 2006, Krishna wrote:

> Date: Tue, 28 Mar 2006 06:37:08 -0800 (PST)
> From: Krishna <dhunjukrishna@yahoo.com>
> Reply-To: dhunjukrishna@gmail.com
> To: linux-mips@linux-mips.org
> Subject: compilation problem with kernel 2.6.15
>
> I tried to cross compile kernel 2.6.15 for BCM1480. Please tell me what the 
> following error indicates:
> ...

Hi !

You are trying to use gcc 4.2, aren't you ?

`fault_in_pages_readable' is defined as follows:

fault_in_pages_readable(const char __user *uaddr, int size)
{
    volatile char c;
    int ret;
    ret = __get_user(c, uaddr);
    ...
}

this invokes the __get_user_nocheck(c,uaddr,sizeof(*uaddr)) macro:

#define __get_user_nocheck(x,ptr,size)  \
({      \
    __typeof(*(ptr)) __gu_val =  (__typeof(*(ptr))) 0;  \
    ... \
})

defining `__gu_val' of type `const char', which gcc 4.2 (don't know about 4.1)
no longer accepts as asm-output (lvalue).  At least until this macro will be
changed, you should switch back to gcc 4.0.

kind regards

pf


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