lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 2 Sep 2014 08:58:56 -0700
From:	Guenter Roeck <linux@...ck-us.net>
To:	Xuetao Guan <gxt@....edu.cn>
Cc:	linux-kernel@...r.kernel.org, Guan Xuetao <gxt@...c.pku.edu.cn>,
	Chen Gang <gang.chen.5i5j@...il.com>,
	Grant Likely <grant.likely@...aro.org>
Subject: Re: 回复: Status of 'unicore32'
 architecture in Linux kernel

On Tue, Sep 02, 2014 at 10:03:48PM +0800, Xuetao Guan  wrote:
> Sorry for late reply.
> 
> ----- Guenter Roeck <linux@...ck-us.net> 写道:
> > Status of 'unicore32' architecture in Linux kernel
> > --------------------------------------------------
> > 
> > The idea was to create a working kernel and initramfs for the ongoing Linux
> > kernel test project. This summary describes the result of this effort.
> > 
> > Overall, conclusion is that the architecture would need some work
> > (both in qemu and the kernel itself) to make it testable with qemu.
> 
> Great. And there's a lot of work to do for unicore32.
> 
> > 
> > Guenter
> > 
> > ---------------------
> > Toolchain used was from [1]. I did not attempt to build my own toolchain.
> > 
> > Configuration:
> > 
> > make ARCH=unicore32 defconfig && make ARCH=unicore32
> > 
> > This configuration currently fails to build in the upstream kernel.
> > A patch to fix the problem has been submitted and is pending upstream
> > integration [2]. With this patch merged, the 'defconfig' image can
> > be built.
> 
> Thanks. I'll apply it in my repo.
> 
Linus already accepted the patch upstream after I sent it to him directly,
so this problem has been solved by now.

> > 
> > ----------------
> > qemu
> > 
> > Attempts to load the unicore32:defconfig image with qemu failed.
> > 
> > Research points to [3], which includes a working unicore32 linux kernel
> > in its linux repository [4], in branch unicore32-working. This branch
> > includes a working unicore32 qemu configuration. It also includes
> > a critical patch which is not available in the upstream kernel.
> 
> Yes. And these patches need to be reviewed and reconsidered.
> I'll try to do that in this month.
> 
> > 
> > unicore32: Add ocd console and qemu-defconfig to support qemu simulator
> > 	This patch adds a primitive OCD console to communicate with qemu.
> > 	The same code is already used for early console support.
> 
> Do you mean there's the same/similar code in QEMU.
> 
No, I mean that the ocd functions in the linux kernel (such as ocd_putc) are
used by both earlyprintk and the ocd console code.

> > 
> > With this patch added, and with qemu_defconfig as provided by the same patch,
> > it is possible to build and load a unicore32 image in qemu using the following
> > qemu command line.
> > 
> > qemu-system-unicore32 -curses -M puv3 -m 512 -kernel arch/unicore32/boot/zImage
> > 
> > Caveats:
> > - The use of -nographic instead of -curses causes a qemu crash
> Yes, since qemu curses code was modified to meet the simple OCD console requirement.
> 
The lack of support for -nographic is a problem for scripted testing.
The issue is that we have to interpret console output for scripted testing,
and having to go through curses makes that a bit difficult.

Wonder if '-nographic' can be modeled as '-curses' with no available terminal
configuration. At least in theory that should work, but executing the above
command with TERM=dumb yields no output. Wonder how difficult it would be to
change that.

> > - The qemu emulation only accepts a built-in initramfs.
> Yes, github version only support built-in initramfs.
> NFS+LFS could be also supported, and puv3-pci sim should be added at first.
> 
> > - The only working image is arch/unicore32/boot/zImage.
> >   All other variants, arch/unicore32/boot/Image and vmlinux, cause a crash.
> >   The same (or a similar) crash is also seen if I don't provide a built-in
> >   kernel command line and try to load zImage.
> Sorry for that. That should be fixed.
> 
> > - There is no networking. There is another patch in the github linux
> >   respository [4] which is not available upstream. The driver was submitted
> >   for integration back in 2011 [5] but it was never accepted or merged.
> Yes, exactly.

Too bad. Not exactly necessary for our current scope of testing, but it would be
nice to be able to test networking.

> Thanks Guenter.
> 
You are welcome. Thanks for the feedback.

Guenter
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ