All of lore.kernel.org
 help / color / mirror / Atom feed
From: Yang Shi <yang.shi@windriver.com>
To: Yang Shi <yang.shi@windriver.com>
Cc: Ralf Baechle <ralf@linux-mips.org>, linux-mips@linux-mips.org
Subject: Re: [Bug report] Got bus error when loading kernel module on SB1250 Rev B2 board with 64 bit kernel
Date: Tue, 18 May 2010 15:27:51 +0800	[thread overview]
Message-ID: <4BF24177.7090803@windriver.com> (raw)
In-Reply-To: <4BF2083B.4000303@windriver.com>

Yang Shi 写道:
> Yang Shi 写道:
>   
>> Ralf Baechle 写道:
>>   
>>     
>>> On Fri, May 14, 2010 at 06:29:07PM +0800, Yang Shi wrote:
>>>
>>>   
>>>     
>>>       
>>>> I'm running 2.6.34-rc7 mainline kernel on SB1250 (Rev B2) board. And, I
>>>> use the default sb1250 kernel config (sb1250-swarm_defconfig). So, 64
>>>> bit kernel is used. During kernel loading module got bus error, see
>>>> below log:
>>>>     
>>>>       
>>>>         
>>> Whops.  Fixes which were supposed to handle exactly this problem went
>>> upstream for 2.6.34-rc3 and were tested successfully by others on their
>>> systems.
>>>
>>> I wonder if in arch/mips/sibyte/sb1250/setup.c you can instrument
>>> the function sb1250_m3_workaround_needed() and print the values of
>>> soc_type, soc_pass and the retun value of that function.  Then let's take
>>> it from there.
>>>   
>>>     
>>>       
>> See below log:
>>
>> Broadcom SiByte BCM1250 B2 @ 800 MHz (SB1 rev 2)
>>
>> And, soc_typs is 0x0 and soc_pass is 0x11, sb1250_m3_workaround_needed 
>> should return 1. So, tlb refill handler should go the m3 workaround code 
>> path.
>>   
>>     
>
> It seems CPU_PREFETCH caused this issue. See commit:
>
> commit 6b4caed2ebff4ee232f227d62eb3180d0b558a31
> Author: Ralf Baechle <ralf@linux-mips.org>
> Date:   Wed Jan 28 17:48:40 2009 +0000
>
>     MIPS: IP27: Switch from DMA_IP27 to DMA_COHERENT
>    
>     commit 0d356eaa6316cbb3e89b4607de20b2f2d0ceda25 from linux-mips
>    
>     The special IP27 DMA code selected by DMA_IP27 has been removed a while
>     ago turning DMA_IP27 into almost a nop.  Also fixup the broken logic of
>     its last users memcpy.S and memcpy-inatomic.s.
>    
>     Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
>   

This patch did below fix:

-#if !defined(CONFIG_DMA_COHERENT) || !defined(CONFIG_DMA_IP27)
+#ifdef CONFIG_DMA_NONCOHERENT
 #undef CONFIG_CPU_HAS_PREFETCH

Before the fix, CONFIG_DMA_IP27 is undefined for all of boards except 
IP27, so CONFIG_CPU_HAS_PREFETCH is undefined always.

Thanks,
Yang

> If undef CPU_PREFETCH for SB1250, module can be loaded correctly.
>
> Thanks,
> Yang
>
>   
>> Thanks,
>> Yang
>>
>>   
>>     
>>>   Ralf
>>>
>>>   
>>>     
>>>       
>>
>>   
>>     
>
>
>   

  reply	other threads:[~2010-05-18  7:28 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-14 10:29 [Bug report] Got bus error when loading kernel module on SB1250 Rev B2 board with 64 bit kernel Yang Shi
2010-05-14 18:02 ` Ralf Baechle
2010-05-17  2:57   ` Yang Shi
2010-05-18  3:23     ` Yang Shi
2010-05-18  7:27       ` Yang Shi [this message]
2010-05-18 10:38       ` Ralf Baechle
2010-05-18 11:07         ` Yang Shi

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=4BF24177.7090803@windriver.com \
    --to=yang.shi@windriver.com \
    --cc=linux-mips@linux-mips.org \
    --cc=ralf@linux-mips.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.