Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
121 user(s) are online (92 user(s) are browsing Forums)

Members: 0
Guests: 121

more...

Headlines

 
  Register To Post  

(1) 2 3 »
QEMU, e500 and Linux
Amigans Defender
Amigans Defender


See User information
since there are a lot of people that is using QEMU. Can anyone has tried version 8.1 with e500v2 and PPC Linux? Is there a way to use ide bus? Because it seems it doesn't have any ide or scsi bus available.
Any hint?

i'm really tired...
Go to top
Re: QEMU, e500 and Linux
Not too shy to talk
Not too shy to talk


See User information
@afxgroup

Hi

I only have Debian/linux with kernel under Pegasos 2 on Qemu.
I can't help you

Go to top
Re: QEMU, e500 and Linux
Not too shy to talk
Not too shy to talk


See User information
@afxgroup

You can add a device to do this, and you can get the full list of valid devices using the following line.

./qemu-system-ppc -device help


Here is the list of valid storage devices

Storage devices:
name "am53c974"bus PCIdesc "AMD Am53c974 PCscsi-PCI SCSI adapter"
name "dc390"bus PCIdesc "Tekram DC-390 SCSI adapter"
name "floppy"bus floppy-busdesc "virtual floppy drive"
name "ich9-ahci"bus PCIalias "ahci"
name "ide-cd"bus IDEdesc "virtual IDE CD-ROM"
name "ide-cf"bus IDEdesc "virtual CompactFlash card"
name "ide-hd"bus IDEdesc "virtual IDE disk"
name "isa-fdc"bus ISAdesc "virtual floppy controller"
name "isa-ide"bus ISA
name 
"lsi53c810"bus PCI
name 
"lsi53c895a"bus PCIalias "lsi"
name "megasas"bus PCIdesc "LSI MegaRAID SAS 1078"
name "megasas-gen2"bus PCIdesc "LSI MegaRAID SAS 2108"
name "mptsas1068"bus PCIdesc "LSI SAS 1068"
name "nvme"bus PCIdesc "Non-Volatile Memory Express"
name "nvme-ns"bus nvme-busdesc "Virtual NVMe namespace"
name "nvme-subsys"desc "Virtual NVMe subsystem"
name "pvscsi"bus PCI
name 
"scsi-cd"bus SCSIdesc "virtual SCSI CD-ROM"
name "scsi-hd"bus SCSIdesc "virtual SCSI disk"
name "sd-card"bus sd-bus
name 
"sdhci-pci"bus PCI
name 
"sii3112"bus PCIdesc "SiI3112A SATA controller"
name "usb-bot"bus usb-bus
name 
"usb-storage"bus usb-bus
name 
"usb-uas"bus usb-bus
name 
"virtio-blk-device"bus virtio-bus
name 
"virtio-blk-pci"bus PCIalias "virtio-blk"
name "virtio-blk-pci-non-transitional"bus PCI
name 
"virtio-blk-pci-transitional"bus PCI
name 
"virtio-scsi-device"bus virtio-bus
name 
"virtio-scsi-pci"bus PCIalias "virtio-scsi"
name "virtio-scsi-pci-non-transitional"bus PCI
name 
"virtio-scsi-pci-transitional"bus PCI


For scsi you could add a new device of 'virtio-scsi-pci', and then add a scsi-hd image and attach it to scsi.0

-device virtio-scsi-pci -drive if=none,id=hda,file=linux.hdf,format=raw -device scsi-hd,drive=hda,bus=scsi.0

Go to top
Re: QEMU, e500 and Linux
Amigans Defender
Amigans Defender


See User information
I've tried with:

qemu-system-ppc -machine ppce500 -m 1024 -device virtio-scsi-pci -drive if=none,id=hda,file=D:\LinuxE500\e500.img,format=qcow2 -device scsi-hd,drive=hda,bus=scsi.0 -g 1024x768x32 -monitor stdio


But it doesn't work. U-boot starts but no ide/scsi devices are found and so the autoboot fail

i'm really tired...
Go to top
Re: QEMU, e500 and Linux
Just popping in
Just popping in


See User information
@afxgroup

Our X5000 Linux kernels work in virtual e5500 QEMU machines and we have successfully tested NVMe, SCSI, VirtIO and IDE drives. Maybe you can find some information in the following thread:

Hyperion forum

I was able to boot Debian 8 PowerPCSPE in QEMU on the A1222 with the following command:

qemu-system-ppc -cpu e500v2 -M mpc8544ds -enable-kvm -m 2047 -bios ./u-boot.e500 -nographic -kernel ./uImage-kvm-guest -drive file=debian_ppcspe.img,index=0,if=virtio -net nic,vlan=0,model=e1000 -net user,vlan=-append "rw root=/dev/vda 1"


Adding an IDE bus and drive:

-drive id=disk,file=disk.qcow2,format=qcow2,if=none -device ahci,id=ahci -device ide-cf,drive=disk,bus=ahci.0

Go to top
Re: QEMU, e500 and Linux
Amigans Defender
Amigans Defender


See User information
It seems you are running it on Linux (PPC) and not on Windows (or lunux x86) for example. However where I can find all I need? I mean uboot and the kernel?
Thank you

i'm really tired...
Go to top
Re: QEMU, e500 and Linux
Quite a regular
Quite a regular


See User information
@afxgroupQuote:
afxgroup wrote:I've tried with:

qemu-system-ppc -machine ppce500 -m 1024 -device virtio-scsi-pci -drive if=none,id=hda,file=D:\LinuxE500\e500.img,format=qcow2 -device scsi-hd,drive=hda,bus=scsi.0 -g 1024x768x32 -monitor stdio


But it doesn't work. U-boot starts but no ide/scsi devices are found and so the autoboot fail


It has nothing to do with Linux PPC, but exactly the same thing happens when I try to use SCSI devices under Pegasos 2 emulation. AmigaOs4.1 shows me the boot logo, but does not boot.

Also under AmigaOs4.1 no SCSI devices are shown that I have mounted. I'm not sure, but maybe the Qemu line still needs to be assigned a suitable SCSI driver supported by AmigaOs4.1 or in your case Linux PPC.

I think it was already mentioned that AmigaOs4.1 is not able to boot from SCSI disks, but at least with AmigaOs4.1 I should have access to SCSI devices then, right?

This is the line I used for this:

-drive if=none,id=hd1,file=/Volumes/Games/AmigaPeg2Developer/hd2.img,format=raw -device ide-hd,drive=hd1,bus=ide.1

MacStudio ARM M1 Max Qemu//Pegasos2 AmigaOs4.1 FE
Go to top
Re: QEMU, e500 and Linux
Quite a regular
Quite a regular


See User information
@Maijestro
If AmigaOS does not have a driver for virtio-scsi then how could it see disks attached to that? The AmigaOne firmware printed scsi not found with a vendor/device id of an LSI scsi contoller but QEMU emulates a somewhat newer version of that so probably it won't work unless one of the emulated scsi controllers in QEMU matches a driver in AmigaOS.

For guests that have virtio drivers maybe using virtio-blk is better as it has less legacy stuff, only pure virtio which should be the fastest and simplest. For AmigaOS that's the same as for virtio-gpu and virtio-net: drivers need to be written.

Go to top
Re: QEMU, e500 and Linux
Just can't stay away
Just can't stay away


See User information
@balaton
AmigaOS 4.x only has a driver for lsi53c8xx SCSI.
(There are more SCSI drivers, for example for the onboard A4000T, CyberStormPPC, etc. SCSI controllers, but lsi53c8xx is the only PCI one.)

Go to top
Re: QEMU, e500 and Linux
Quite a regular
Quite a regular


See User information
@joerg
Is that compatible with any of these?

qemu-system-ppc -device help

Storage devices:
name "am53c974", bus PCI, desc "AMD Am53c974 PCscsi-PCI SCSI adapter"
name "dc390", bus PCI, desc "Tekram DC-390 SCSI adapter"
name "lsi53c810", bus PCI
name "lsi53c895a", bus PCI, alias "lsi"

I think the AmigaOne ROM listed 1000:000f PCI ID but I did not find that in QEMU, it has
#define PCI_VENDOR_ID_LSI_LOGIC          0x1000
#define PCI_DEVICE_ID_LSI_53C810         0x0001
#define PCI_DEVICE_ID_LSI_53C895A        0x0012
#define PCI_DEVICE_ID_LSI_SAS1068        0x0054
#define PCI_DEVICE_ID_LSI_SAS1078        0x0060
#define PCI_DEVICE_ID_LSI_SAS0079        0x0079

so 000f is not there but if it's close to one of the above it may be tried to emulate that.

Go to top
Re: QEMU, e500 and Linux
Just can't stay away
Just can't stay away


See User information
@balaton
From the documentation of the AmigaOS 4.x driver:
Quote:
- To use the driver, just drop an LSI/NCR/SYM53Cxxx SCSI board
into any PCI slot, connect it to SCSI drives, make sure
the termination chain is set properly, and add the driver
to your kicklayout.

Quote:
I - Configuring lsi53c8xx through UBOOT envvars
================================================

Currently lsi53c8xx is configurable through the following UBOOT envvars :

- scsi_pci_override

Legal values are : set to the PCI product ID if your board does not show
a product id of 000F. For example, my LSI53C895 board has a product id
of 000C thus I used that feature.

Note : Uboot's internal SCSI code uses the same mechanism and the same
envvar (this is why I chose that name : if you have properly set it for
UBoot then it works for the OS4 driver).

Default if unset : 000F.


SAS SCSI hardware is not supported by the driver, but PCI_DEVICE_ID_LSI_53C895A 0x0012, and maybe even PCI_DEVICE_ID_LSI_53C810 0x0001, should work.


Edited by joerg on 2023/7/28 20:17:26
Go to top
Re: QEMU, e500 and Linux
Not too shy to talk
Not too shy to talk


See User information
@afxgroup
Is this what you want to run?

https://www.qemu.org/docs/master/system/ppc/ppce500.html

https://u-boot.readthedocs.io/en/lates ... ulation/qemu-ppce500.html

u-boot is supplied with qemu. QEMU_PREFIX:shared/qemu/u-boot.e500

What distribution and I understand you want to run ppc with Windows x86, yes?




I just checked what @xeno74 wrote on the console.
as far as I can see he is running ppc on ppc
--
qemu-system-ppc -nographic -machine ppce500 -bios ../share/qemu/u-boot.e500 -cpu e500v2 -M mpc8544ds


U-Boot 2021.07 (06 July 2021 - 09:21:42 +0800)

CPU: Unknown, Version: 0.0, (0x000000)
Core: e500, Version: 2.2, (0x80210022)
Clock configuration:
CPU0:400 MHz,
CCB:400 MHz,
DDR:200 MHz (data rate 400 MT/s), LBC: unknown (LCRR[CLKDIV] = 0x00)
L1: D-cache 32 KiB enabled
I-cache 32 KiB enabled
DRAM: 128 MB
L2: disabled
Loading environment out of nowhere... OK
In: serial@4500
Out: serial@4500
Err: serial@4500
Network: eth0: virtio-net#0
Press any key to stop autoboot: 0

--

If this is what you want, let me know - I'll check tomorrow

Go to top
Re: QEMU, e500 and Linux
Amigans Defender
Amigans Defender


See User information
Yes. It is that one I want to run. But no ide or scsi devices are recognized. I've tried several ways. Tomorrow I will try on Linux x86

i'm really tired...
Go to top
Re: QEMU, e500 and Linux
Quite a regular
Quite a regular


See User information
@smarkusg
You have two machine options in that command line (-M is synonym for -machine). I wonder why it did not give an error but one of those should be enough.

Go to top
Re: QEMU, e500 and Linux
Not too shy to talk
Not too shy to talk


See User information
@balaton
Yes, I see what is wrong - QEMU bug ?
in general it doesn't matter @afxgroup asked about something else

Go to top
Re: QEMU, e500 and Linux
Amigans Defender
Amigans Defender


See User information
@balaton
Quote:

You have two machine options in that command line (-M is synonym for -machine). I wonder why it did not give an error but one of those should be enough.

Yes I saw this. But this isn't the problem. The problem is that with shipped uboot e500 version I can't manage to add any drive. In any way.

i'm really tired...
Go to top
Re: QEMU, e500 and Linux
Quite a regular
Quite a regular


See User information
@afxgroup
I can't help woth that but there should be examples on line on how to use the e500 machine so you should be able to search and find onw. Of course you'd need to emulate something that the guest has drivers for so it amy depend on the guest you're trying to run.

Also the sources fot the included U-boot-e500 firmware is in qemu/roms/u-boot so you may check what config it uses to find out what it shoulc support. If the dir is empty look at git submodule and to build it see qemu/roms/Makefile:
u-boot.e500:
        $(
MAKE) -C u-boot O=build-e500 qemu-ppce500_config
        
$(MAKE) -C u-boot CROSS_COMPILE=$(powerpc_cross_prefix\
                O
=build-e500
        
$(powerpc_cross_prefix)strip u-boot/build-e500/u-boot -o \
                
../pc-bios/u-boot.e500

Go to top
Re: QEMU, e500 and Linux
Amigans Defender
Amigans Defender


See User information
The only devices that seems usable are virtio-blk. And reading the second link you gave me there is also an example. But there is no way to make it work..

i'm really tired...
Go to top
Re: QEMU, e500 and Linux
Not too shy to talk
Not too shy to talk


See User information
@afxgroup

I don't know if this will help you or is at all relevant to your question.
I had a chilwe and tried to run what @xeno74 wrote
I think he is one of the best qemu ppc experts. I have seen , he builds linux kernel , posts on forums etc....
e.g. https://forum.hyperion-entertainment.com/viewtopic.php?t=3954
http://www.supertuxkart-amiga.de/amiga/x1000.html#downloads

To the topic
ubuntu-14.04.5-server-powerpc.iso
There is supposedly a kernel under the e500 ..probably "e500mc"
I got as far as it will help you.
I have no idea if the kernel is the right one or if something should show up ..but it tries to boot up


uboot
--
=> pci
Scanning PCI devices on bus 0
BusDevFun VendorId DeviceId Device Class Sub-Class
_____________________________________________________________
00.00.00 0x1957 0x0030 Processor 0x20
00.11.00 0x1002 0x5046 Display controller 0x00
00.12.00 0x8086 0x2922 Mass storage controller 0x06
00.13.00 0x8086 0x100e Network controller 0x00
--


marekus@Mac-mini-Marek bin % ./qemu-system-ppc -cpu e500v2 -M mpc8544ds -nographic -bios ../share/qemu/u-boot.e500 -device ati-vga,vgamem_mb=32,"romfile=",guest_hwcursor=true -drive format=raw,if=none,id=rdb,file=/Users/marekus/Documents/FS-UAE/sam460ex/Linux.hdf -device ahci,id=ahci -device ide-cf,drive=rdb,bus=ahci.0 -netdev user,id=mynet0 -device e1000,netdev=mynet0 -cdrom /Users/marekus/Downloads/ubuntu-14.04.5-server-powerpc.iso -kernel /Users/marekus/Desktop/vmlinux -initrd /Users/marekus/Desktop/initrd.gz -append "root=/dev/cdrom file=/cdrom/preseed/ubuntu-server.seed quiet --"


U-Boot 2021.07 (Jul 06 2021 - 09:21:42 +0800)

CPU: Unknown, Version: 0.0, (0x00000000)
Core: e500, Version: 2.2, (0x80210022)
Clock Configuration:
CPU0:400 MHz,
CCB:400 MHz,
DDR:200 MHz (400 MT/s data rate), LBC: unknown (LCRR[CLKDIV] = 0x00)
L1: D-cache 32 KiB enabled
I-cache 32 KiB enabled
DRAM: 128 MiB
L2: disabled
Loading Environment from nowhere... OK
In: serial@4500
Out: serial@4500
Err: serial@4500
Net: e1000: 52:54:00:12:34:56
eth0: e1000#0
Hit any key to stop autoboot: 0
## Booting kernel from Legacy Image at 02000000 ...
Image Name: Linux-4.4.0-31-powerpc-e500mc
Created: 2016-07-13 2:10:35 UTC
Image Type: PowerPC Linux Kernel Image (gzip compressed)
Data Size: 5898578 Bytes = 5.6 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... OK
## Flattened Device Tree blob at 07a6de90
Booting using the fdt blob at 0x7a6de90
Uncompressing Kernel Image
Loading Device Tree to 03efc000, end 03ffefff ... OK


ps
I know , in the command line there is a graphics card and "-nographic"

Go to top
Re: QEMU, e500 and Linux
Amigans Defender
Amigans Defender


See User information
Ok. That's fine. But except for the Linux iso. I don't have the kernel, initrd and so on. Do I have to compile it? Or it is possible to download them somewhere?

i'm really tired...
Go to top

  Register To Post
(1) 2 3 »

 




Currently Active Users Viewing This Thread: 2 ( 0 members and 2 Anonymous Users )




Powered by XOOPS 2.0 © 2001-2023 The XOOPS Project