[Urgent] About the latest kernel for loongson

7 views
Skip to first unread message

Wu Zhangjin

unread,
Nov 29, 2009, 6:39:04 AM11/29/09
to loongson-dev, Zhang Le, Liu Shiwei, Michael Heide, Robert Millan
Hi, All

At least three users have reported the problem of NFS & CIFS in 2.6.30
and 2.6.31 for loongson: when they copy a large number of files from the
other machines to loongson machines(FuLoong Mini PC and U-NAS), the
files will be broken.

I'm trying to reproduce the problem in my own FuLoong box, but not
encounter the problem currently, I can not ensure which part have
introduced this bug. Michael have helped to test the old loongson
patchset(from 2.6.27) on 2.6.31, the problem is also there, so, I guess,
there may be some problem is the mainline kernel or the relative network
driver.

Before the bug is found and fixed, to avoid breaking your files, please
stop using the latest kernel in your FuLoong Mini PC and U-Nas system,
but use the old 2.6.27 from http://dev.lemote.com/code/linux_loongson
instead. thanks!

And if you have interest, welcome to test the latest kernel on your
machines, and help to reproduce the problem. any feedbacks are welcome!
thanks!

Best Regards,
Wu Zhangjin

Wu Zhangjin

unread,
Nov 29, 2009, 9:09:43 AM11/29/09
to loongson-dev, Zhang Le, Liu Shiwei, Michael Heide, Robert Millan, Tatu Kilappa, trilkk
On Sun, 2009-11-29 at 19:39 +0800, Wu Zhangjin wrote:
> Hi, All
>
> At least three users have reported the problem of NFS & CIFS in 2.6.30
> and 2.6.31 for loongson: when they copy a large number of files from the
> other machines to loongson machines(FuLoong Mini PC and U-NAS), the
> files will be broken.
>
> I'm trying to reproduce the problem in my own FuLoong box, but not
> encounter the problem currently, I can not ensure which part have
> introduced this bug. Michael have helped to test the old loongson
> patchset(from 2.6.27) on 2.6.31, the problem is also there, so, I guess,
> there may be some problem is the mainline kernel or the relative network
> driver.
>
> Before the bug is found and fixed, to avoid breaking your files, please
> stop using the latest kernel in your FuLoong Mini PC and U-Nas system,
> but use the old 2.6.27 from http://dev.lemote.com/code/linux_loongson
> instead. thanks!
>

If really want to use it, the temp solution is:

$ ethtool -K eth0 rx off

or put the above line into /etc/rc.local.

This solution is from Liu Shiwei, thanks goes to him ;)

Wu Zhangjin

unread,
Nov 30, 2009, 4:48:50 AM11/30/09
to loongson-dev, Zhang Le, Liu Shiwei, Michael Heide, Robert Millan, Tatu Kilappa, trilkk, Ralf Baechle
Hi, forks

New testing report comes from Tatu Kilappa(thanks goes to him), He has
tried CONFIG_SPARSEMEM instead of the CONFIG_FLATMEM, most of the
problems went away.

And as what I knew, CONFIG_FLATMEM will also bring us with the other
troubles, for example, it will make the SUSPEND(STR) fail. and The
linux-mips maintainer(Ralf) told me it also has some other bad
influences. So, I have enabled CONFIG_SPARSEMEM as the default option in
the defconfig:

in 2.6.30/31

$ ls arch/mips/configs/*loong*
arch/mips/configs/fuloong2e_defconfig
arch/mips/configs/fuloong2f_unas_defconfig
arch/mips/configs/fuloong2f_defconfig
arch/mips/configs/yeeloong2f_defconfig

in 2.6.32/33...

arch/mips/configs/fuloong2e_defconfig
arch/mips/configs/lemote2f_defconfig (for all 2F machines)

And please do remember to use SPARSEMEM instead, thanks!

And some other NOTICES here:

1. please do not try PAGE_SIZE_4KB, it not work on Loongson Family
machines.

2. you are recommended to use CONFIG_64BIT instead of CONFIG_32BIT, it
will not only bring us with some performance, and also, will eliminate
some potential problems.

3. and please do remember to use the binutils patch from Lemote

http://sourceware.org/ml/binutils/2009-11/msg00387.html

Anyway, I will try to send a patch to Ralf to disable the problematic
options for Loongson.

Thanks very much!

Best Regards,
Wu Zhangjin

Wu Zhangjin

unread,
Nov 30, 2009, 9:53:33 PM11/30/09
to Ralf Baechle, loongson-dev, Zhang Le, Liu Shiwei, Michael Heide, Robert Millan, Tatu Kilappa, trilkk
On Mon, 2009-11-30 at 22:07 +0000, Ralf Baechle wrote:
> On Mon, Nov 30, 2009 at 05:48:50PM +0800, Wu Zhangjin wrote:
>
> > 1. please do not try PAGE_SIZE_4KB, it not work on Loongson Family
> > machines.
>
> Please remind me, what are the unsolved issues with 4k page size?

Hi, Ralf

Not focused on the details yet, currently, with 4k page size, it will
hang on executing the init program when booting the kernel:

[...]
VFS: Mounted root(ext3 filesystem) readonly on device 3:1
Freeing unused kernel memory: 180k freed.
Kernel panic - not syncing: Attempted to kill init!
....

the possible reason is the cache aliases problem.

As we know, loongson have 64kb size 4 way L1 cache, Way_size = 64k/4 =
16 > 4k Page Size, so, it may have the cache aliase problem. but with
16kb page size, it will have no such problem, and also, it will bring us
with some performance for it have no need to avoid the cache aliases
problem via extra cache flushing.

So, 16kb is recommended, but I will try to ensure the 4k page size works
if it is necessary to make it work.

Thanks!

Best Regards,
Wu Zhangjin

Reply all
Reply to author
Forward
0 new messages