[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] PreP kernels boot using Qemu
From: |
Aurelien Jarno |
Subject: |
Re: [Qemu-devel] PreP kernels boot using Qemu |
Date: |
Mon, 22 Oct 2007 18:28:10 +0200 |
User-agent: |
Mutt/1.5.13 (2006-08-11) |
On Mon, Oct 22, 2007 at 09:36:07AM +0200, J. Mayer wrote:
> Hi all,
>
> I've been investigating more about PreP kernel boot using Qemu and I
> achieved to boot 2.4.35, 2.6.12 and 2.6.22 kernels using Qemu CVS and
> unmodified OHW.
> The issues I found in the kernel are:
> - the OpenFirmware video console driver is broken in recent 2.4 kernels
> and have been removed from recent 2.6 kernel
> - I then decided to use the vga16fb console driver but needed to do some
> patches in order to make it compile properly
> - the CMOS RTC driver is not available for PPC architecture in 2.6
> kernels and need some patches in order to be usable
> - I discovered that the mkprep utility is bugged in 2.4.35 and 2.6.12
> kernels. The bugs are visible only when cross-compiling from a
> little-endian and/or 64 bits host.
> - I got issues (ie process freezing) when using the 2.6.22 kernel with
> HZ > 100. It seems to run properly when the system timer is set to 100
> Hz but this needs more tests for confirmation.
> - I got the 2.6.22 kernel crashing (ie kernel Oops in workqueue code)
> when it has no RTC available. There is no problem when the RTC is
> present. This is likely to be a kernel bug: when no RTC is available, it
> cannot calibrate its timers properly and the kernel timer seems to run
> very fast. Forcing (with hacks...) the timer to run at nearly real-time
> seems to prevent the bug to happen.
>
> I then generated some kernels that allow me to boot and use those 3
> kernels.
> Here are 3 tarballs with:
> - a patch to be applied to the vanilla kernel sources to fix the
> mentionned bugs
> - the .config file I used to build the kernel
> - the zImage.prep image
> <http://perso.magic.fr/l_indien/qemu-ppc/linux-tests/linux-2.4.35-prep.tar.bz2>
> <http://perso.magic.fr/l_indien/qemu-ppc/linux-tests/linux-2.6.12-prep.tar.bz2>
> <http://perso.magic.fr/l_indien/qemu-ppc/linux-tests/linux-2.6.22-prep.tar.bz2>
>
> I then run Qemu with the following command line template:
> ./ppc-softmmu/qemu-system-ppc -serial stdio -net nic,model=ne2k_isa -net
> tap -net nic,model=ne2k_pci -net tap -net nic,model=rtl8139 -net tap
> -cpu 604 -M prep -L pc-bios/ -hda <my_first_disk> -cdrom <my_cdrom>
> -kernel
> <src_base>/linux-<kversion>.patched/arch/ppc/boot/images/zImage.prep
>
> Hope this helps.
>
Yes, this help a lot, thanks! With your config file, I have been able to
build and boot a 2.6.22 kernel. I have used a Debian sid chroot.
Here are a few remarks:
- The NE2000 card doesn't work for the same reason as with the powerpc
architecture. The kernel patch below fixes the problem. I will send it
later along with the ppc patch.
- The "floating point" problem I reported during the week-end does not
exists, probably because of the switch from powerpc to ppc. I still
don't know if it is a kernel problem or a QEMU problem (or both).
- PCI is broken. PCI IDs are reported in the wrong endianness:
00:00.0 Non-VGA unclassified device: Unknown device 0148:5710 (rev 06)
00:01.0 Non-VGA unclassified device: Santa Cruz Operation Unknown device 3412
(rev 03)
Otherwise everything works fine for me, it looks a bit faster than
MIPS(el) emulation (which is faster than ARM and SPARC). I still haven't
done that much tests though.
Signed-off-by: Aurelien Jarno <address@hidden>
diff --git a/arch/ppc/syslib/i8259.c b/arch/ppc/syslib/i8259.c
index 1e5a00a..559f27c 100644
--- a/arch/ppc/syslib/i8259.c
+++ b/arch/ppc/syslib/i8259.c
@@ -127,6 +127,7 @@ static void i8259_unmask_irq(unsigned int irq_nr)
static struct irq_chip i8259_pic = {
.typename = " i8259 ",
.mask = i8259_mask_irq,
+ .disable = i8259_mask_irq,
.unmask = i8259_unmask_irq,
.mask_ack = i8259_mask_and_ack_irq,
};
--
.''`. Aurelien Jarno | GPG: 1024D/F1BCDB73
: :' : Debian developer | Electrical Engineer
`. `' address@hidden | address@hidden
`- people.debian.org/~aurel32 | www.aurel32.net
- [Qemu-devel] PreP kernels boot using Qemu, J. Mayer, 2007/10/22
- Re: [Qemu-devel] PreP kernels boot using Qemu, Jocelyn Mayer, 2007/10/22
- Re: [Qemu-devel] PreP kernels boot using Qemu,
Aurelien Jarno <=
- Re: [Qemu-devel] PreP kernels boot using Qemu, J. Mayer, 2007/10/22
- Re: [Qemu-devel] PreP kernels boot using Qemu, Aurelien Jarno, 2007/10/22
- Re: [Qemu-devel] PreP kernels boot using Qemu, J. Mayer, 2007/10/22
- Re: [Qemu-devel] PreP kernels boot using Qemu, Thiemo Seufer, 2007/10/23
- Re: [Qemu-devel] PreP kernels boot using Qemu, J. Mayer, 2007/10/23
- Re: [Qemu-devel] PreP kernels boot using Qemu, Aurelien Jarno, 2007/10/23
- Re: [Qemu-devel] PreP kernels boot using Qemu, J. Mayer, 2007/10/23
- Re: [Qemu-devel] PreP kernels boot using Qemu, Thiemo Seufer, 2007/10/23
Re: [Qemu-devel] PreP kernels boot using Qemu, Rob Landley, 2007/10/27