Linux MIPS Architecture development
 help / color / mirror / Atom feed
* 64 bit kernel for BCM1250
@ 2005-05-17  9:36 Michael Belamina
  2005-05-17 10:49 ` Maciej W. Rozycki
  0 siblings, 1 reply; 14+ messages in thread
From: Michael Belamina @ 2005-05-17  9:36 UTC (permalink / raw)
  To: linux-mips

Hi,

  I have built a 64 bit kernel for BCM1250.
  When the kernel is loaded and control is passed to
kernel_entry there is an exception:

CFE> boot -elf LinuxServer:vmlinux.64
Loader:elf Filesys:tftp Dev:eth2
File:LinuxServer:vmlinux.64 Options:(null)
Loading: 0xffffffff80100000/2162688
0xffffffff80310000/557344 Entry at 0xffffffff802d0000
Closing network.
Starting program at 0xffffffff802d0000
**Exception 8: EPC=FFFFFFFF802D003C, Cause=0000900C
(TLBMissWr)
                RA=FFFFFFFF9FC0086C,
VAddr=0000000000000000

        0  ($00) = 0000000000000000     AT ($01) =
0000000000000000
        v0 ($02) = 0000000000000080     v1 ($03) =
0000000000000003
        a0 ($04) = FFFFFFFF81F07FF0     a1 ($05) =
0000000000000000
        a2 ($06) = FFFFFFFF9FC008E8     a3 ($07) =
0000000043464531
        t0 ($08) = FFFFFFFF802D0000     t1 ($09) =
FFFFFFFF81F01DB8
        t2 ($10) = FFFFFFFFA0008000     t3 ($11) =
0000000000008000
        t4 ($12) = 0000000000000000     t5 ($13) =
FFFFFFFF81F18E60
        t6 ($14) = FFFFFFFF81F14A20     t7 ($15) =
000000000000000A
        s0 ($16) = FFFFFFFF9FC0086C     s1 ($17) =
FFFFFFFF81F01D20
        s2 ($18) = FFFFFFFF820036F8     s3 ($19) =
FFFFFFFF81F00000
        s4 ($20) = FFFFFFFF820036E8     s5 ($21) =
FFFFFFFFFFFFFFFF
        s6 ($22) = 0000000000000000     s7 ($23) =
0000000000000000
        t8 ($24) = 0000000010000000     t9 ($25) =
FFFFFFFF9FC46430
        k0 ($26) = FFFFFFFF81F22E28     k1 ($27) =
FFFFFFFF81F1F098
        gp ($28) = FFFFFFFF81F07FF0     sp ($29) =
FFFFFFFF82003550
        fp ($30) = 0000000000000000     ra ($31) =
FFFFFFFF9FC0086C



The code where the exception occurs is:
ffffffff802d0000 <kernel_entry>:
ffffffff802d0000:       400c6000        mfc0   
t0,c0_status
ffffffff802d0004:       3c011000        lui    
at,0x1000
ffffffff802d0008:       3421009f        ori    
at,at,0x9f
ffffffff802d000c:       01816025        or     
t0,t0,at
ffffffff802d0010:       398c001f        xori   
t0,t0,0x1f
ffffffff802d0014:       408c6000        mtc0   
t0,c0_status
ffffffff802d0018:       000000c0        sll    
zero,zero,0x3
ffffffff802d001c:       37bd000f        ori    
sp,sp,0xf
ffffffff802d0020:       3bbd000f        xori   
sp,sp,0xf
ffffffff802d0024:       3c0c0000        lui     t0,0x0
ffffffff802d0028:       3c010000        lui     at,0x0
ffffffff802d002c:       658c0000        daddiu 
t0,t0,0
ffffffff802d0030:       64210000        daddiu 
at,at,0
ffffffff802d0034:       000c603c        dsll32 
t0,t0,0x0
ffffffff802d0038:       0181602d        daddu  
t0,t0,at
ffffffff802d003c:       fd800000        sd     
zero,0(t0) 
ffffffff802d0040:       3c0d0000        lui     t1,0x0
ffffffff802d0044:       3c010000        lui     at,0x0
ffffffff802d0048:       65ad0000        daddiu 
t1,t1,0
ffffffff802d004c:       6421fff8        daddiu 
at,at,-8
ffffffff802d0050:       000d683c        dsll32 
t1,t1,0x0
ffffffff802d0054:       01a1682d        daddu  
t1,t1,at
ffffffff802d0058:       658c0008        daddiu 
t0,t0,8
ffffffff802d005c:       158dfffe        bne    
t0,t1,ffffffff802d0058 <__init_begin+0x58>
ffffffff802d0060:       fd800000        sd     
zero,0(t0)
ffffffff802d0064:       3c1c0000        lui     gp,0x0
ffffffff802d0068:       3c010000        lui     at,0x0


A 32 bit kernel loads and boot with no problems on the
same board. The board design is based on Sentosa. The
boot loader is CFE. The kernel version is 2.4.28

Please advice.
 
Thank,
  Michael




__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
  2005-05-17  9:36 Michael Belamina
@ 2005-05-17 10:49 ` Maciej W. Rozycki
  0 siblings, 0 replies; 14+ messages in thread
From: Maciej W. Rozycki @ 2005-05-17 10:49 UTC (permalink / raw)
  To: Michael Belamina; +Cc: linux-mips

On Tue, 17 May 2005, Michael Belamina wrote:

>   I have built a 64 bit kernel for BCM1250.
>   When the kernel is loaded and control is passed to
> kernel_entry there is an exception:
> 
> CFE> boot -elf LinuxServer:vmlinux.64
[...]

 I'm assuming vmlinux.64 is a 64-bit ELF file.  If so, then, well, 
depending on the version of CFE you have, this may or may not work.  The 
workaround is to always use 32-bit ELF files.  You should get one after 
your Linux build -- if not (which may depend on how you do builds), then 
try `make vmlinux.32' and use the result.

  Maciej

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
@ 2005-05-17 19:52 Michael Belamina
  0 siblings, 0 replies; 14+ messages in thread
From: Michael Belamina @ 2005-05-17 19:52 UTC (permalink / raw)
  To: Maciej W. Rozycki; +Cc: linux-mips

Hi,

  Thanks for your reply.
  I tried using the resulted vmlinux.32 and got the
same result. 

  After looking into it, I found out that t0 is loaded
with 0x0 while it should load _edata value which
should be 0xffffffff80310000 (according to the
System.map).   in the 32 bit version (which I build
using a different toolchain), edata is loaded to t0
register as it should.

It looks to me like it is a toolchain problem. 

1. where can I download a pre built, prooven working
64 bit toolchain?

2. Is there anything else that can cause this problem?


Thanks,
 Michael


--- "Maciej W. Rozycki" <macro@linux-mips.org> wrote:
> On Tue, 17 May 2005, Michael Belamina wrote:
> 
> >   I have built a 64 bit kernel for BCM1250.
> >   When the kernel is loaded and control is passed
> to
> > kernel_entry there is an exception:
> > 
> > CFE> boot -elf LinuxServer:vmlinux.64
> [...]
> 
>  I'm assuming vmlinux.64 is a 64-bit ELF file.  If
> so, then, well, 
> depending on the version of CFE you have, this may
> or may not work.  The 
> workaround is to always use 32-bit ELF files.  You
> should get one after 
> your Linux build -- if not (which may depend on how
> you do builds), then 
> try `make vmlinux.32' and use the result.
> 
>   Maciej
> 

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
@ 2005-05-18  8:09 Michael Belamina
  2005-05-18 15:58 ` David Daney
  0 siblings, 1 reply; 14+ messages in thread
From: Michael Belamina @ 2005-05-18  8:09 UTC (permalink / raw)
  To: linux-mips


I downloaded a new toolchain from ftp.mips-linux.org 
 and the previous problem is not repeating itself (t0
is now loaded properly with the _edata value). 

 Now I have another problem. I am getting the
following exception:


----  Start of pasted message  ---------

Starting program at 0xffffffff802ec000
Broadcom SiByte BCM1250 B2 @ 800 MHz (SB1 rev 2)
Board type: SiByte BCM91250E (Sentosa)
@@@@ This is a BCM1250 B1/B2, but the kernel is
conservatively configured for an 'A' stepping. @@@@
This kernel optimized for board runs with CFE
CPU revision is: 01040102
FPU revision is: 000f0102
Primary instruction cache 32kB, 4-way, linesize 32
bytes.
Primary data cache 32kB, 4-way, linesize 32 bytes.
Linux version 2.4.30 (michael@LinuxServer.lan) (gcc
version 3.4.3) #29 SMP Wed May 18 10:37:00 IDT 2005
Determined physical RAM map:
 memory: 0000000001effe00 @ 0000000000000000 (usable)
 memory: 000000000dffbe00 @ 0000000002004000 (usable)
 memory: 000000000ffffe00 @ 0000000080000000 (usable)
On node 0 totalpages: 589823
zone(0): 589823 pages.
zone(1): 0 pages.
zone(2): 0 pages.
Kernel command line: root=/dev/nfs ip=any
ramdisk_size=48000
Calibrating delay loop... 532.48 BogoMIPS
Memory: 468216k/523236k available (1951k kernel code,
55020k reserved, 148k data, 112k init)
Dentry cache hash table entries: 131072 (order: 9,
2097152 bytes)
Inode cache hash table entries: 131072 (order: 9,
2097152 bytes)
Mount cache hash table entries: 256 (order: 0, 4096
bytes)
Buffer cache hash table entries: 262144 (order: 9,
2097152 bytes)
Page-cache hash table entries: 262144 (order: 9,
2097152 bytes)
Checking for 'wait' instruction...  unavailable.
Checking for the multiply/shift bug... no.
Checking for the daddi bug... no.
Checking for the daddiu bug... no.
POSIX conformance testing by UNIFIX
Detected 2 available CPU(s)
Starting CPU 1...
Primary instruction cache 32kB, 4-way, linesize 32
bytes.
Primary data cache 32kB, 4-way, linesize 32 bytes.
Slave cpu booted successfully
Waiting on wait_init_idle (map = 0x2)
All processors have done init_idle
pipe_mnt =                0
Cpu 0 Unable to handle kernel paging request at
address 0000000000000028, epc == ffffffff8016e3bc, ra
== ffffffff8014
Oops in fault.c::do_page_fault, line 231:
Cpu 0
$0      : 0000000000000000 ffffffff803b0000
0000000000000000 0000000000000009
$4      : ffffffff802c31ba ffffffff802c45f2
0000000000000072 0000000000000000
$8      : ffffffff803bf630 ffffffff803bf630
ffffffff803bd550 000000000000000a
$12     : ffffffffffffffff ffffffff8039b487
0000000000000000 ffffffff802bf0d0
$16     : ffffffff80100098 a80000008fff6080
ffffffffffffffe9 a80000008fff6140
$20     : 0000000000000000 ffffffff803078c0
0000000000000001 ffffffff80324688
$24     : 0000000000000000 0000000000000020
$28     : ffffffff802e8000 ffffffff802ebce0
ffffffff802ebd70 ffffffff8016e3c4
Hi      : 0000000000000000
Lo      : 0000000000000000
epc     : ffffffff8016e3bc    Not tainted
badvaddr: 0000000000000028
Status  : 14001fe3  [ KX SX UX KERNEL EXL IE ]
Cause   : 80808008
PrId  : 01040102
Process swapper (pid: 0, stackpage=ffffffff802e8000)
Stack: 0000000000000000 0000000000040004
0000000000000000 9000000010060120
       9000000010060100 ffffffff803bd550
ffffffff803bf630 ffffffff803bf630
       ffffffff80100098 0000000000000000
0000000000010f00 ffffffff80307860
       0000000000000000 ffffffff803078c0
0000000000000001 ffffffff80324688
       0000000000000000 ffffffff8010a0c8
ffffffffffffffff 000000000000000a
       ffffffff80107e2c 0000000000000000
0000000000000000 0000000000000020
       0000000000000001 000000000000000a
ffffffff802e8000 ffffffff802ebe00
       0000000000000000 ffffffff8021458c
00000000000013bf c000000000000000
       0000000000010f00 0000000000000000
ffffffff802ebef0 0000000000000fc0
       ffffffffffffffc0 0000000000000000
0000000014001fe1 ffffffff8039b488
       000000000000003e ...
Call Trace: [<ffffffff80100098>] [<ffffffff8010a0c8>]
[<ffffffff80107e2c>]
            [<ffffffff8021458c>] [<ffffffff80100098>]
[<ffffffff8012583c>]
            [<ffffffff80105488>] [<ffffffff8012583c>]

Code: dc42a5f0  104000fc  00000000 <0c05ffcc> dc440028
 104000e7  0040802d  0c05b892  0040202d
Kernel panic: Attempted to kill the idle task!
In idle task - not syncing
 <0>Rebooting in 5 seconds..Passing control back to
CFE...


----  End of pasted message  ---------


The fault is in do_pipe() function when trying to
call:

struct inode *inode = new_inode(pipe_mnt->mnt_sb);

The pipe_mnt is NULL at this point because
init_pipe_fs () was not called yet.


Any ideas what could be wrong?

Thanks,
  Michael






--- "Maciej W. Rozycki" <macro@linux-mips.org> wrote:
> On Tue, 17 May 2005, Michael Belamina wrote:
> 
> >   I have built a 64 bit kernel for BCM1250.
> >   When the kernel is loaded and control is passed
> to
> > kernel_entry there is an exception:
> > 
> > CFE> boot -elf LinuxServer:vmlinux.64
> [...]
> 
>  I'm assuming vmlinux.64 is a 64-bit ELF file.  If
> so, then, well, 
> depending on the version of CFE you have, this may
> or may not work.  The 
> workaround is to always use 32-bit ELF files.  You
> should get one after 
> your Linux build -- if not (which may depend on how
> you do builds), then 
> try `make vmlinux.32' and use the result.
> 
>   Maciej
> 

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
  2005-05-18  8:09 Michael Belamina
@ 2005-05-18 15:58 ` David Daney
  2005-05-18 16:24   ` Maciej W. Rozycki
  0 siblings, 1 reply; 14+ messages in thread
From: David Daney @ 2005-05-18 15:58 UTC (permalink / raw)
  To: Michael Belamina; +Cc: linux-mips

Michael Belamina wrote:
.
.
.
> Linux version 2.4.30 (michael@LinuxServer.lan) (gcc
> version 3.4.3) #29 SMP Wed May 18 10:37:00 IDT 2005
.
.
.
> 
> The fault is in do_pipe() function when trying to
> call:
> 
> struct inode *inode = new_inode(pipe_mnt->mnt_sb);
> 
> The pipe_mnt is NULL at this point because
> init_pipe_fs () was not called yet.
> 
> 
> Any ideas what could be wrong?
> 

I saw this with a 32 bit kernel (for a 32 bit target).  As far as I 
know, no 2.4.x kernels from linux-mips.org will work with gcc 3.4.x.

I have previously posted patches to this list that fixed the problem for 
me.  Specifically I think the messages in this thread are relevant:

http://www.linux-mips.org/cgi-bin/mesg.cgi?a=linux-mips&i=41AFDA18.2010906%40avtrex.com

David Daney.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
  2005-05-18 15:58 ` David Daney
@ 2005-05-18 16:24   ` Maciej W. Rozycki
  2005-05-18 16:35     ` David Daney
  0 siblings, 1 reply; 14+ messages in thread
From: Maciej W. Rozycki @ 2005-05-18 16:24 UTC (permalink / raw)
  To: David Daney; +Cc: Michael Belamina, linux-mips

On Wed, 18 May 2005, David Daney wrote:

> I saw this with a 32 bit kernel (for a 32 bit target).  As far as I know, no
> 2.4.x kernels from linux-mips.org will work with gcc 3.4.x.

 That could actually be true -- I've been using GCC 4.0.0 for quite some 
time now (that includes CVS snapshots from before the release), so I have 
no slightest idea whether it's OK to use older versions. ;-)

> I have previously posted patches to this list that fixed the problem for me.
> Specifically I think the messages in this thread are relevant:
> 
> http://www.linux-mips.org/cgi-bin/mesg.cgi?a=linux-mips&i=41AFDA18.2010906%40avtrex.com

 Hasn't one of the proposed fixes for the bug made its way to Linux in the 
end?  That would be regrettable...

  Maciej

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
  2005-05-18 16:24   ` Maciej W. Rozycki
@ 2005-05-18 16:35     ` David Daney
  0 siblings, 0 replies; 14+ messages in thread
From: David Daney @ 2005-05-18 16:35 UTC (permalink / raw)
  To: Maciej W. Rozycki; +Cc: Michael Belamina, linux-mips

Maciej W. Rozycki wrote:
> On Wed, 18 May 2005, David Daney wrote:
> 
> 
>>I saw this with a 32 bit kernel (for a 32 bit target).  As far as I know, no
>>2.4.x kernels from linux-mips.org will work with gcc 3.4.x.
> 
> 
>  That could actually be true -- I've been using GCC 4.0.0 for quite some 
> time now (that includes CVS snapshots from before the release), so I have 
> no slightest idea whether it's OK to use older versions. ;-)
> 
> 
>>I have previously posted patches to this list that fixed the problem for me.
>>Specifically I think the messages in this thread are relevant:
>>
>>http://www.linux-mips.org/cgi-bin/mesg.cgi?a=linux-mips&i=41AFDA18.2010906%40avtrex.com
> 
> 
>  Hasn't one of the proposed fixes for the bug made its way to Linux in the 
> end?  That would be regrettable...
> 

WRT the 2.4 kernel the answer seems to be no.  And yes I think it is 
regrettable.

If anybody thinks it would be useful, I could post my current patch again.

David Daney.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
@ 2005-05-19 13:52 Michael Belamina
  2005-05-19 15:19 ` Maciej W. Rozycki
  0 siblings, 1 reply; 14+ messages in thread
From: Michael Belamina @ 2005-05-19 13:52 UTC (permalink / raw)
  To: David Daney, Maciej W. Rozycki; +Cc: Michael Belamina, linux-mips

Hi,

   Thanks very much for your replies and the valuable
info. 
   I am still not sure about the following:

   1. Is this problem related only to kernels
downloaded from linux-mips.org or it is a more general
one?

   2. Can someone point to a known to work 64 bit
versions of gcc and binutil for BCM1250 (the problem
that started this thread was actually a problem of the
mip64-linux-ld I was using).
    
Thanks,
 Michael



--- David Daney <ddaney@avtrex.com> wrote:
> Maciej W. Rozycki wrote:
> > On Wed, 18 May 2005, David Daney wrote:
> > 
> > 
> >>I saw this with a 32 bit kernel (for a 32 bit
> target).  As far as I know, no
> >>2.4.x kernels from linux-mips.org will work with
> gcc 3.4.x.
> > 
> > 
> >  That could actually be true -- I've been using
> GCC 4.0.0 for quite some 
> > time now (that includes CVS snapshots from before
> the release), so I have 
> > no slightest idea whether it's OK to use older
> versions. ;-)
> > 
> > 
> >>I have previously posted patches to this list that
> fixed the problem for me.
> >>Specifically I think the messages in this thread
> are relevant:
> >>
>
>>http://www.linux-mips.org/cgi-bin/mesg.cgi?a=linux-mips&i=41AFDA18.2010906%40avtrex.com
> > 
> > 
> >  Hasn't one of the proposed fixes for the bug made
> its way to Linux in the 
> > end?  That would be regrettable...
> > 
> 
> WRT the 2.4 kernel the answer seems to be no.  And
> yes I think it is 
> regrettable.
> 
> If anybody thinks it would be useful, I could post
> my current patch again.
> 
> David Daney.
> 


		
__________________________________ 
Do you Yahoo!? 
Yahoo! Mail - Helps protect you from nasty viruses. 
http://promotions.yahoo.com/new_mail

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
  2005-05-19 13:52 64 bit kernel for BCM1250 Michael Belamina
@ 2005-05-19 15:19 ` Maciej W. Rozycki
  2005-05-23 15:26   ` Re[2]: " Jerry
  0 siblings, 1 reply; 14+ messages in thread
From: Maciej W. Rozycki @ 2005-05-19 15:19 UTC (permalink / raw)
  To: Michael Belamina; +Cc: David Daney, linux-mips

On Thu, 19 May 2005, Michael Belamina wrote:

>    I am still not sure about the following:
> 
>    1. Is this problem related only to kernels
> downloaded from linux-mips.org or it is a more general
> one?

 The problem is Linux 2.4 is generally in the maintenance mode, which 
means no new development is done on it (although still an occasional 
backport from 2.6 may happen).  As a result maintainers are rather 
hesitant about applying changes unless they fix critical bugs.  Bugs 
revealed by new versions of build tools are not usually considered as 
critical, because you may work them around by using an old version of the 
triggering tool.

 Still for the MIPS port what you can get from linux-mips.org is probably 
less behind than what there is at kernel.org.

>    2. Can someone point to a known to work 64 bit
> versions of gcc and binutil for BCM1250 (the problem
> that started this thread was actually a problem of the
> mip64-linux-ld I was using).

 For 64-bit builds you probably want to use fairly recent versions or you 
risk hitting serious bugs that used to exist in older versions.  Using 
David's patch (or preferably mine ;-) -- as available here: 
"http://www.linux-mips.org/cgi-bin/mesg.cgi?a=linux-mips&i=Pine.LNX.4.55.0406281509170.23162%40jurand.ds.pg.gda.pl"; 
which I keep using with GCC 4.0.0) is probably the lesser evil.

  Maciej

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
@ 2005-05-22 20:31 Michael Belamina
  0 siblings, 0 replies; 14+ messages in thread
From: Michael Belamina @ 2005-05-22 20:31 UTC (permalink / raw)
  To: Maciej W. Rozycki; +Cc: David Daney, linux-mips


  Thanks you all for your replies.
  I will check this out and post the outcome.

 Michael

  


--- "Maciej W. Rozycki" <macro@linux-mips.org> wrote:
> On Thu, 19 May 2005, Michael Belamina wrote:
> 
> >    I am still not sure about the following:
> > 
> >    1. Is this problem related only to kernels
> > downloaded from linux-mips.org or it is a more
> general
> > one?
> 
>  The problem is Linux 2.4 is generally in the
> maintenance mode, which 
> means no new development is done on it (although
> still an occasional 
> backport from 2.6 may happen).  As a result
> maintainers are rather 
> hesitant about applying changes unless they fix
> critical bugs.  Bugs 
> revealed by new versions of build tools are not
> usually considered as 
> critical, because you may work them around by using
> an old version of the 
> triggering tool.
> 
>  Still for the MIPS port what you can get from
> linux-mips.org is probably 
> less behind than what there is at kernel.org.
> 
> >    2. Can someone point to a known to work 64 bit
> > versions of gcc and binutil for BCM1250 (the
> problem
> > that started this thread was actually a problem of
> the
> > mip64-linux-ld I was using).
> 
>  For 64-bit builds you probably want to use fairly
> recent versions or you 
> risk hitting serious bugs that used to exist in
> older versions.  Using 
> David's patch (or preferably mine ;-) -- as
> available here: 
>
"http://www.linux-mips.org/cgi-bin/mesg.cgi?a=linux-mips&i=Pine.LNX.4.55.0406281509170.23162%40jurand.ds.pg.gda.pl";
> 
> which I keep using with GCC 4.0.0) is probably the
> lesser evil.
> 
>   Maciej
> 


		
Discover Yahoo! 
Find restaurants, movies, travel and more fun for the weekend. Check it out! 
http://discover.yahoo.com/weekend.html 

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re[2]: 64 bit kernel for BCM1250
  2005-05-19 15:19 ` Maciej W. Rozycki
@ 2005-05-23 15:26   ` Jerry
  2005-05-23 15:39     ` David Daney
  0 siblings, 1 reply; 14+ messages in thread
From: Jerry @ 2005-05-23 15:26 UTC (permalink / raw)
  To: Maciej W. Rozycki; +Cc: linux-mips

Hello Maciej,
Thursday, May 19, 2005, 6:19:14 PM, you wrote:

>  For 64-bit builds you probably want to use fairly recent versions or you
> risk hitting serious bugs that used to exist in older versions.  Using
> David's patch (or preferably mine ;-) -- as available here: 
> "http://www.linux-mips.org/cgi-bin/mesg.cgi?a=linux-mips&i=Pine.LNX.4.55.0406281509170.23162%40jurand.ds.pg.gda.pl";
> which I keep using with GCC 4.0.0) is probably the lesser evil.

 Without going into details - what difference between your and David's
patch ? :) I'm in doubts which one is more suitable for me...


   ()_()
 -( ^,^ )- -[21398845]- -<The Bat! 3.0.1.33>- -<23/05/2005 18:18>-
  (") (")

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
  2005-05-23 15:26   ` Re[2]: " Jerry
@ 2005-05-23 15:39     ` David Daney
  0 siblings, 0 replies; 14+ messages in thread
From: David Daney @ 2005-05-23 15:39 UTC (permalink / raw)
  To: Jerry; +Cc: Maciej W. Rozycki, linux-mips

Jerry wrote:
> Hello Maciej,
> Thursday, May 19, 2005, 6:19:14 PM, you wrote:
> 
> 
>> For 64-bit builds you probably want to use fairly recent versions or you
>>risk hitting serious bugs that used to exist in older versions.  Using
>>David's patch (or preferably mine ;-) -- as available here: 
>>"http://www.linux-mips.org/cgi-bin/mesg.cgi?a=linux-mips&i=Pine.LNX.4.55.0406281509170.23162%40jurand.ds.pg.gda.pl";
>>which I keep using with GCC 4.0.0) is probably the lesser evil.
> 
> 
>  Without going into details - what difference between your and David's
> patch ? :) I'm in doubts which one is more suitable for me...
> 

FWIW: My current patch is quite similar to Maciej's.

David Daney.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
@ 2005-05-26 18:59 Michael Belamina
  2005-05-31 14:57 ` Maciej W. Rozycki
  0 siblings, 1 reply; 14+ messages in thread
From: Michael Belamina @ 2005-05-26 18:59 UTC (permalink / raw)
  To: Maciej W. Rozycki; +Cc: linux-mips


I have tried the patch on kernel version 2.4.28 and it
seems that the fix is not working for this kernel
version. I used gcc version 2.95.4 and it is working. 

Another questions:

 I am using 32 bit application and 64 bit device
driver that I wrote. ioctl fails with "unknown ioctl"
message. 

1. What is the best way to translate 32 bit ioctl
codes to 64 bit?

2. How 64 bit kernel space buffers will  be used by a
32 bit application (using mmap)? 

3.What is the maximum usable ram out of 2GB I will
have if I am using a 32 bit application and 64 bit
kernel and the kernel is allocating the buffers using
__get_free_pages (I need the buffers for DMA - and I
need them to be physically continuous)?

Thanks,
 Michael








--- "Maciej W. Rozycki" <macro@linux-mips.org> wrote:
> On Thu, 19 May 2005, Michael Belamina wrote:
> 
> >    I am still not sure about the following:
> > 
> >    1. Is this problem related only to kernels
> > downloaded from linux-mips.org or it is a more
> general
> > one?
> 
>  The problem is Linux 2.4 is generally in the
> maintenance mode, which 
> means no new development is done on it (although
> still an occasional 
> backport from 2.6 may happen).  As a result
> maintainers are rather 
> hesitant about applying changes unless they fix
> critical bugs.  Bugs 
> revealed by new versions of build tools are not
> usually considered as 
> critical, because you may work them around by using
> an old version of the 
> triggering tool.
> 
>  Still for the MIPS port what you can get from
> linux-mips.org is probably 
> less behind than what there is at kernel.org.
> 
> >    2. Can someone point to a known to work 64 bit
> > versions of gcc and binutil for BCM1250 (the
> problem
> > that started this thread was actually a problem of
> the
> > mip64-linux-ld I was using).
> 
>  For 64-bit builds you probably want to use fairly
> recent versions or you 
> risk hitting serious bugs that used to exist in
> older versions.  Using 
> David's patch (or preferably mine ;-) -- as
> available here: 
>
"http://www.linux-mips.org/cgi-bin/mesg.cgi?a=linux-mips&i=Pine.LNX.4.55.0406281509170.23162%40jurand.ds.pg.gda.pl";
> 
> which I keep using with GCC 4.0.0) is probably the
> lesser evil.
> 
>   Maciej
> 


		
__________________________________ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new Resources site
http://smallbusiness.yahoo.com/resources/

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: 64 bit kernel for BCM1250
  2005-05-26 18:59 Michael Belamina
@ 2005-05-31 14:57 ` Maciej W. Rozycki
  0 siblings, 0 replies; 14+ messages in thread
From: Maciej W. Rozycki @ 2005-05-31 14:57 UTC (permalink / raw)
  To: Michael Belamina; +Cc: linux-mips

On Thu, 26 May 2005, Michael Belamina wrote:

> I have tried the patch on kernel version 2.4.28 and it
> seems that the fix is not working for this kernel
> version. I used gcc version 2.95.4 and it is working. 

 Hmm, you may need additional fixes...  How about just switching to 2.6?  
Currently 2.4 is over 4 years old and it shouldn't be used for new 
development.

> 1. What is the best way to translate 32 bit ioctl
> codes to 64 bit?

 Use arch/mips64/kernel/ioctl32.c, but in 2.6 there may be a generic 
solution available.

> 2. How 64 bit kernel space buffers will  be used by a
> 32 bit application (using mmap)? 

 As usual.  Except you can't get more than 2GB of them.

> 3.What is the maximum usable ram out of 2GB I will
> have if I am using a 32 bit application and 64 bit
> kernel and the kernel is allocating the buffers using
> __get_free_pages (I need the buffers for DMA - and I
> need them to be physically continuous)?

 2GB minus what's used by Linux for other purposes.  Physically 
contiguous?  That sounds like a problem (and broken hardware)...

  Maciej

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2005-05-31 14:57 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-05-19 13:52 64 bit kernel for BCM1250 Michael Belamina
2005-05-19 15:19 ` Maciej W. Rozycki
2005-05-23 15:26   ` Re[2]: " Jerry
2005-05-23 15:39     ` David Daney
  -- strict thread matches above, loose matches on Subject: below --
2005-05-26 18:59 Michael Belamina
2005-05-31 14:57 ` Maciej W. Rozycki
2005-05-22 20:31 Michael Belamina
2005-05-18  8:09 Michael Belamina
2005-05-18 15:58 ` David Daney
2005-05-18 16:24   ` Maciej W. Rozycki
2005-05-18 16:35     ` David Daney
2005-05-17 19:52 Michael Belamina
2005-05-17  9:36 Michael Belamina
2005-05-17 10:49 ` Maciej W. Rozycki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox