Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
132 user(s) are online (125 user(s) are browsing Forums)

Members: 1
Guests: 131

FlynnTheAvatar, more...

Support us!

Headlines

 
  Register To Post  

« 1 ... 5 6 7 (8) 9 10 11 12 »
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Home away from home
Home away from home


See User information
@nikitas

Quote:
My serial output goes crazy by repeating the message below forever.
The frequency at which these two messages are repeatedly printed in my console must be almost every clock cycle! (Okay, that's an arbitrary assumption, but they are printed extremely fast.)
Does this thing probe my GPU so hard?
And that's why I see a 100% load on all Radeontop metrics?
It stays at 100% forever without dropping until I stop the process. Then, all the Radeontop metrics going back to 0%.

Of course, I don't understand what these messages mean. Is there an incompatibility in the guest PCI mapping, maybe?

The driver is getting into an infinite loop while going up the PCI bridge chain. It only does that, because some motherboard firmware doesn't set up the PCI bridges properly. The logs don't tell me why it gets stuck, though.

Quote:
Of course, as we already know, when I explicitly define:
bus=pci.0


Then AmigaOS4.1 FE boots normally, but as the thread title says, it's extremely slow.

These are the logs of the successful boot when using pci.0:
...

Have you tried setting the RadeonRX power management to high? One of the last things I see in the log is that the GPU's locks are all set to the lowest that they can go. The GPU's sclk never goes above 551MHz.

It's normal for the GPU to go to minimal clocks when it's idle, but I'm wondering whether forcing it to go to maximum speed will improve the performance.

Join Kea Campus' Amiga Corner and support Amiga content creation
https://keasigmadelta.com/ - see more of my work
Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Just popping in
Just popping in


See User information
@Hans

I changed the GPU Power Setting from Dynamic to High (on the AOS4.1 guest).

On the host UEFI the ASPM is disabled.
On the host OS (Ubuntu 24.04), I added directives in the grub command that disable any PCIe power-saving mode.

Unfortunately, I don't see any improvement.

Despite using the pci.0 slot in QEMU, the AOS4.1 Ranger shows that the passed-through PCI devices are attached to the 0x01 bus. But I guess you already know this.

At least reading the following gives me a small idea of what I'm seeing in the logs. That's a plus...

https://wiki.osdev.org/PCI
https://wiki.osdev.org/PCI_Express

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Quite a regular
Quite a regular


See User information
@nikitas
I think I now understand the issues. With pci.1 it might work but there's the issue with the driver getting stuck trying to find a bridge. With pci.0 the interrupts from that bus are not corrected so it will not get interrupts and only works with interrupts disabled. I don't know if that causes it to be slow but could be. I'll need to find a way to connect the interrupts of pci.0 in QEMU. On real machine INTA and INTB are connected from the AGP port, C and D are ignored. In QEMU only the pci.1 bus is connected. With pci.1 are there any logs before the repeating lines? You can redirect it to a file like -serial stdio >output.txt 2>&1 then you see the beginning that scrolls out with the repeating lines. Maybe that has more info for @Hans to see why this happens.

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Quite a regular
Quite a regular


See User information
@Hans
Quote:
The driver is getting into an infinite loop while going up the PCI bridge chain. It only does that, because some motherboard firmware doesn't set up the PCI bridges properly.

Is this because you get a PCIe card on a PCI bus without a bridge? Or what is the proper setup of the bridge? BBoot does not do anything with the bridge and pegasos2.rom might not be able to do it as the bridge/host device 0 on the PCI bus is just a dummy device with most functions not implemented so if the driver looks for some setting it might not be stored. So what does the driver expect to avoid this loop and why this does not happen on real PegasosII? Maybe in this case we really don't have a bridge as the PCIe card is just connected as PCI and there is no PCI to PCIe bridge in the guest. The host has a CPU to PCIe bridge so that can't be passed through either. Do we need to emulate some dummy bridge device (but bridges did not work on real machine so I'm not sure that would work) or can the driver be changed to avoid this problem?

Also why this does not happen with pci.0? Is that because AmigaOS thinks that's a PCIe bus or because there are no other devices on that bus?

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Home away from home
Home away from home


See User information
@balaton
But radeonhd/radeonrx do not work on real pegasos for now: This is unpossible directly (due having only agp and pure pci), but over bridge it also currenly dont work: RTAS way (which peg2's os4 kernel use to read pci registers, etc) not works, so Hans tried to deal with it by direct reading of regs, test of which show that this way works, and once Hans will find time to update kernel with new code, i will be able to test it, and only then we can see if we have or not have same issue you talk about on real Pegasos.

Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Just popping in
Just popping in


See User information
@balaton @Hans @kas1e

It starts getting very funny. I attached the Radeon R7 240:

- It doesn't work at all with bboot v.07. It works with pegasos.rom.
- The RadeonRX 550 refused to be attached to pci.1 and works only on pci.0. But in AOS4, Ranger reports that it is attached on bus 0x01.
- Now, the Radeon 7 240 refuses to work on pci.0 slot and works only on pci.1. But in AOS4, Ranger reports that it is attached on bus 0x00(!)

Despite being inferior to RadeonRX 550, Radeon R7 240 performs much better(!) but still very slow.

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Quite a regular
Quite a regular


See User information
@nikitas
Quote:
It starts getting very funny. I attached the Radeon R7 240:

- It doesn't work at all with bboot v.07. It works with pegasos.rom.

That suggests that unlike the RX driver the HD driver does not init the card from AtomBIOS or this card does not have suitable BIOS so it needs its ROM to be run by the BIOS emulator in firmware. BBoot does not have a BIOS emulator so it won't run the card BIOS. AmigaOS has a BIOS emulator resource but only the Classic kernel invokes it so won't work even if added to pegasos2. So the only way is to use pegasos2.rom to get the card BIOS executed. However the pegasos2.rom and pegasos2 AmigaOS kernel don't properly init interrupts on pegasos2 so you also need to use BBoot from the firmware to fix that up. That is you need to use both pegasos2.rom and BBoot. To do that copy bboot, bboot.fth and Kickstart.zip to your boot volume where amigaboot.of is and from the pegasos2.rom ok prompt do 'boot hd:0 bboot.fth' (assuming hd:0 is your boot volume, otherwise change this in bboot.fth too). Then this should fix the interrupt settings after the firmware ran the card's BIOS.

Quote:
- The RadeonRX 550 refused to be attached to pci.1 and works only on pci.0. But in AOS4, Ranger reports that it is attached on bus 0x01.

Don't care about those numbers. QEMU numbers them as the chip has it but on pegasos2 these are used in the opposite order (because on real chip pci.0 is 66MHz and used for the AGP port and pci.1 is 33MHz and used for PCI) and AmigaOS numbers them that way but this does not matter it's still the same bus just numbered differently.

Quote:
- Now, the Radeon 7 240 refuses to work on pci.0 slot and works only on pci.1. But in AOS4, Ranger reports that it is attached on bus 0x00(!)

I don't know why unless you tell what does refuse to work mean. Any errors? Maybe it needs the missing interrupt. The firmware should init a GPU in the AGP port too so running the BIOS should not be a problem.

Quote:
Despite being inferior to RadeonRX 550, Radeon R7 240 performs much better(!) but still very slow.

Any numbers on that so we can compare to the RX benchmark results?

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Just popping in
Just popping in


See User information
@balaton

Hello,

Quote:
That is you need to use both pegasos2.rom and BBoot. To do that copy bboot, bboot.fth and Kickstart.zip to your boot volume where amigaboot.of is and from the pegasos2.rom ok prompt do 'boot hd:0 bboot.fth'

Yes, you had told me about this before, so that's the way I boot the system using pegasos.rom and then blindly typing hd:0 bboot.fth.

Quote:
Don't care about those numbers. QEMU numbers them as the chip has it but on pegasos2 these are used in the opposite order (because on real chip pci.0 is 66MHz and used for the AGP port and pci.1 is 33MHz and used for PCI) and AmigaOS numbers them that way but this does not matter it's still the same bus just numbered differently.

Understood.

Quote:
I don't know why unless you tell what does refuse to work mean. Any errors? Maybe it needs the missing interrupt. The firmware should init a GPU in the AGP port too so running the BIOS should not be a problem.

It does not refuse to work actually. It freezes everything. Even the host system, and I have to hard reset the host. When I first tried with BBoot the host froze and in addition after the hard reset he "kickstart.zip" was "fried". It got corrupted. 0 kilobytes.

Quote:
Any numbers on that so we can compare to the RX benchmark results?

Yes, this is the first thing I tried, but the overall score is misleading because during the Gfx2DBench test, the drawings were interrupted very frequently. When it is drawing, it is faster than RX550. But again, it gets interrupted by something—maybe some other process. So, it took 3 hours with an overall score of 60. But, for example, (as @Hans will notice, I'm sure) FillRect is a lot faster.
This means it is not just my system or QEMU, but it seems RadeonHD.chip performs better than RadeonRX.chip, doesn't it?
https://hdrlab.org.nz/benchmark/gfxbench2d/OS/AmigaOS/Result/2812

Quote:
Does the Invalid write at addr 0xFE000080 / 0x80 show up with bus=pci.0 as well or only with pci.1?

Yes, this message appears regardless of the PCI bus used. I see it very often, and I tend to believe that it is unrelated.


Edited by nikitas on 2024/6/26 20:22:06
Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Home away from home
Home away from home


See User information
@nikitas

Quote:
Yes, this is the first thing I tried, but the overall score is misleading because during the Gfx2DBench test, the drawings were interrupted very frequently. When it is drawing, it is faster than RX550. But again, it gets interrupted by something—maybe some other process. So, it took 3 hours with an overall score of 60. But, for example, (as @Hans will notice, I'm sure) FillRect is a lot faster.
This means it is not just my system or QEMU, but it seems RadeonHD.chip performs better than RadeonRX.chip, doesn't it?
https://hdrlab.org.nz/benchmark/gfxbench2d/OS/AmigaOS/Result/2812


Your FillRect and other hardware acceleration results are better, but the memory copy speed has collapsed. They're below 1 MiB/s! Copying to/from VRAM does vary between graphics card chipset series, even with DMA. I noticed this with different transfer rates when using the same motherboard with different graphics cards.

The "interruptions" in the Random test are actually RAM <=> VRAM copy operations that are part of the test. Your memory copy speeds are so slow that it looks like the benchmark tool stops.

Something is definitely going wrong on your machine. The native performance of both graphics cards is multiple orders of magnitude higher. Heck, the same card on an X5000 is also orders of magnitude faster, and that's without DMA assisted RAM <=> VRAM copies:

https://hdrlab.org.nz/benchmark/gfxben ... /AmigaOS/GraphicsCard/639

@balaton
Quote:
Is this because you get a PCIe card on a PCI bus without a bridge?

I don't know yet. There was a bug in older versions of the driver that could cause an infinite loop in some situations. I'm not sure if the version that nikitas is using has that fixed or not.

Hans

Join Kea Campus' Amiga Corner and support Amiga content creation
https://keasigmadelta.com/ - see more of my work
Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Just popping in
Just popping in


See User information
@balaton @Hans

And I can't test it on Debian PPC, because despite recognizing the Radeon R7 GPU when running lspci -nnk, (I have installed the firmware-linux-nonfree package that contains the radeon driver.), during the boot/reboot, it throws an exception (sometimes continues the boot process and I get the terminal but startx doesn't work):

The command:
qemu-system-ppc \
-machine pegasos2 \
-bios pegasos2.rom \
-rtc base=localtime \
-drive if=none,id=CD0,file=debian-8.11.0-powerpc-DVD-1.iso,format=raw -device ide-cd,drive=CD0,bus=ide.1 \
-drive if=none,id=DH0,file=hd.img,format=raw -device ide-hd,drive=DH0,bus=ide.0 \
-vga none \
-device rtl8139,netdev=ETH0 -netdev user,id=ETH0 \
-device vfio-pci,host=01:00.0,x-vga=on,id=vfio0,multifunction=on \
-device vfio-pci,host=01:00.1,id=vfio1 \
-device bochs-display \
-serial stdio


The PegasosII boot:
" /failsafe" io
boot hd
:0 vmlinuz-3.16.0-6-powerpc root=/dev/sda2


The exception during Debian Jessie PPC boot:
[    8.871644radeon 0000:00:02.0enabling device (0000 -> 0003)
[    
8.902604] [drminitializing kernel modesetting (OLAND 0x1002:0x6617 0x1DA2:0xE263).
[    
8.903239] [drmregister mmio base0x80080000
[    8.903355] [drmregister mmio size262144
[    8.905565ATOM BIOSOLAND
[    8.921018radeon 0000:00:02.0VRAM4096M 0x0000000000000000 0x00000000FFFFFFFF (4096M used)
[    
8.921319radeon 0000:00:02.0GTT1024M 0x0000000100000000 0x000000013FFFFFFF
[    8.921587] [drmDetected VRAM RAM=4096MBAR=256M
[    8.921713] [drmRAM width 128bits DDR
[    8.922519] [drmradeon4096M of VRAM memory ready
[    8.927359] [drmradeon1024M of GTT memory ready.
[    
8.927705] [drmLoading OLAND Microcode
[    8.933407radeon 0000:00:02.0firmwaredirect-loading firmware radeon/OLAND_pfp.bin
/dev/sda1fsck[    8.935567radeon 0000:00:02.0firmwaredirect-loading firmware radeon/OLAND_me.bin
[    8.940827radeon 0000:00:02.0firmwaredirect-loading firmware radeon/OLAND_ce.bin
[    8.941847radeon 0000:00:02.0firmwaredirect-loading firmware radeon/OLAND_rlc.bin
[    8.961028radeon 0000:00:02.0firmwaredirect-loading firmware radeon/OLAND_mc2.bin
[    8.961275] [drmradeon/OLAND_mc2.bin31452 bytes
[    8.964061radeon 0000:00:02.0firmwaredirect-loading firmware radeon/OLAND_smc.bin
[    8.964544] [drmInternal thermal controller with fan control
[    8.973876Unable to handle kernel paging request for data at address 0x00000020
[    8.974096Faulting instruction address0xe1c96a7c
[    8.974391OopsKernel access of bad areasig11 [#1]
[    8.974530CHRP
[    8.974646Modules linked inradeon(+) vt8231 snd_hda_codec_hdmi uhci_hcd(+) ehci_hcd snd_via82xx snd_mpu401_uart i2c_viapro snd_rawmidi snd_seq_device snd_via82xx_modem usbcore snd_hda_intel snd_ac97_codec snd_hda_controller bochs_drm ac97_bus gameport usb_common ttm sr_mod snd_hda_codec 8139too drm_kms_helper cdrom snd_hwdep parport_pc parport psmouse snd_pcm 8139cp drm snd_timer via_ircc mii irda snd sg evdev syscopyarea sysfillrect sysimgblt soundcore serio_raw crc_ccitt i8042 atkbd libps2 serio autofs4 ext4 crc16 mbcache jbd2 sd_mod crc_t10dif crct10dif_generic crct10dif_common ata_generic pata_via
[    8.976159CPU0 PID141 Commsystemd-udevd TaintedG        W     3.16.0-6-powerpc #1 Debian 3.16.56-1+deb8u1
[    8.976399taskdeda4010 tidec36000 task.tidec36000
[    8.976527NIPe1c96a7c LRe3bcbe10 CTR00000000
[    8.976645REGSdec37a10 TRAP0300   TaintedG        W      (3.16.0-6-powerpc Debian 3.16.56-1+deb8u1)
[    
8.976869MSR: 00009032 <EE,ME,IR,DR,RI>  CR82228428  XER00000000
[    8.977055DAR00000020 DSISR40000000 
GPR00
e3bcbe10 dec37ac0 deda4010 dfa70400 dec37b1c 00000000 dcd77ffc 000003fd 
GPR08
: 00008000 df8b6000 00000000 00000003 22228482 20128c8c 00000000 c072ca48 
GPR16
c00a6600 00000000 00000124 dfb982c8 e3c34320 dfb982e4 dcd70000 c06ea4a4 
GPR24
dfb982c0 df8be000 e3c32a68 00007adc dd3c91b0 dd3c8000 00000000 dec37b1c 
[    8.977923NIP [e1c96a7cdrm_pcie_get_speed_cap_mask+0x3c/0x12c [drm]
[    
8.978137LR [e3bcbe10si_dpm_init+0x54/0xfd8 [radeon]
[    
8.978280Call Trace:
[    
8.978353] [dec37ac0] [df8be0000xdf8be000 (unreliable)
[    
8.978537] [dec37ae0] [e3bcbe10si_dpm_init+0x54/0xfd8 [radeon]
[    
8.978733] [dec37b80] [e3b63120radeon_pm_init+0x1a8/0x7c4 [radeon]
[    
8.978942] [dec37bd0] [e3b8f010si_init+0x270/0x83c [radeon]
[    
8.979124] [dec37c10] [e3b030f0radeon_device_init+0x62c/0xaa0 [radeon]
[    
8.979327] [dec37c40] [e3b05cfcradeon_driver_load_kms+0xa0/0x1c4 [radeon]
[    
8.979502] [dec37c60] [e1c941d0drm_dev_register+0xd4/0x130 [drm]
[    
8.979659] [dec37c80] [e1c97270drm_get_pci_dev+0xcc/0x1b8 [drm]
[    
8.979855] [dec37ca0] [e3b014c8radeon_pci_probe+0x110/0x144 [radeon]
[    
8.980018] [dec37cd0] [c02a2b48pci_device_probe+0xb4/0x11c
[    8.980154] [dec37d00] [c035ddd4driver_probe_device+0xc0/0x3c0
[    8.980298] [dec37d30] [c035e218__driver_attach+0xc8/0xcc
[    8.980431] [dec37d50] [c035bab4bus_for_each_dev+0x74/0xc0
[    8.980567] [dec37d80] [c035d244bus_add_driver+0x184/0x264
[    8.980702] [dec37da0] [c035eb30driver_register+0x94/0x13c
[    8.980839] [dec37db0] [c00043c0do_one_initcall+0xd0/0x240
[    8.980977] [dec37e20] [c00a9c88load_module+0x1d08/0x2318
[    8.981146] [dec37ee0] [c00aa490SyS_finit_module+0x9c/0xd8
[    8.981284] [dec37f40] [c00152e8ret_from_syscall+0x0/0x40
[    8.981427] --- Exceptionc01 at 0x1ffe6f50
[    8.981427]     LR 0x1fe14670
[    8.981599Instruction dump:
[    
8.9817299421ffe0 7c0802a6 bfc10018 90010024 39200000 91240000 7c9f2378 812300d0 
[    8.9819332f890000 419e0038 81290008 83c9001c <a13e00202b891106 419e0024 2b891166 
[    8.982303] ---[ end trace 3860cff9fa78db7c ]---



This might indicate an issue with reading/writing in PCI BARs (as always...)
Unable to handle kernel paging request for data at address 0x00000020

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Amigans Defender
Amigans Defender


See User information
@all

I've received the laptop with RadeonRX550 (along the intel vga)
I've configured it for passthrough and IOMMU

This is my sh file:

taskset -c 1 \
 qemu
-system-ppc \
 
-M pegasos2 \
 
-m 2G \
 
-vga none \
 
-kernel bboot \
 
-initrd Kickstart.zip \
 
-drive if=none,id=cd -device ide-cd,drive=cd,bus=ide.1 \
 
-drive if=none,id=hd,file=./hdpeg.img,format=raw -device ide-hd,drive=hd,bus=ide.0 \
 
-device vfio-pci,host=3b:00.0,bus=pci.1 \
 
-rtc base=localtime,clock=rt \
 
-serial stdio \
 
-device rtl8139,netdev=nic -netdev user,hostname=pegasos-os4,hostfwd=tcp::6000-:6000,id=nic \
 
-display sdl,gl=on


The system seems to start and this is my output:

BBoot 0.7 (15.4.2024)
/
pci@80000000io fe000000/10000 mem 80000000/40000000
/pci@80000000/host:    0:0.0     11ab:6460 60000 646011ab 0000 7
Added assigned
-addresses
/pci@80000000/display:    0:1.0     1002:6987 38000 69871002 01ff 0
Truncated 64 bit BAR 43000810
Truncated 64 bit BAR 43000818
Added assigned
-addressesset interrupt 0109
 
42000810        0 80000000         0 10000000  0000000c 8000000c
 42000818        0 90000000         0   200000  
0000000c 9000000c
  1000820        0 fe001200         0      100  
00000001 00001201
  2000824        0 90200000         0    40000  
00000000 90200000
  2000830        0 90240000         0    20000  
00000000 90240000
/pci@80000000/ethernet:    0:2.0     10ec:8139 20000 813910ec 0100 0
Added assigned
-addressesset interrupt 0109
  
1001010        0 fe001300         0      100  00000001 00001301
  2001014        0 90260000         0      100  
00000000 90260000
  2001030        0 90280000         0    40000  
00000000 90280000
/pci@80000000/isa:    0:c.0     1106:8231 60100 82311106 0000 8
Added assigned
-addresses
/pci@80000000/ide:    0:c.1     1106:0571 1018f 05711106 010e 87
Added assigned
-addresses
  1006110        0 fe001000         0        8  
00000001 00001001
  1006114        0 fe001008         0        4  
00000001 ! 00001009
  
1006118        0 fe001010         0        8  00000001 00001011
  100611c        0 fe001018         0        4  
00000001 ! 00001019
  
1006120        0 fe001020         0       10  00000001 00001021
/pci@80000000/usb:    0:c.2     1106:3038 c0300 30381106 0409 7
Added assigned
-addresses
  1006220        0 fe001040         0       20  
00000001 00001041
/pci@80000000/usb:    0:c.3     1106:3038 c0300 30381106 0409 7
Added assigned
-addresses
  1006320        0 fe001060         0       20  
00000001 00001061
/pci@80000000/other:    0:c.4     1106:8235 68000 82351106 0009 0
Added assigned
-addresses
/pci@80000000/sound:    0:c.5     1106:3058 40100 30581106 0309 4
Added assigned
-addresses
  1006510        0 fe001100         0      100  
00000001 00001101
  1006514        0 fe001030         0        4  
00000001 00001031
  1006518        0 fe001034         0        4  
00000001 00001035
/pci@80000000/pci1106,3068:    0:c.6     1106:3068 78000 30681106 0309 30
Added assigned
-addresses
/pci@c0000000io f8000000/10000 mem c0000000/20000000
/pci@c0000000/host:    0:0.0     11ab:6460 60000 646011ab 0000 7
Added assigned
-addresses
Checking initrd at 0x600000
-0xcc440f (7095311 bytes)
Found zip with 73 entries
Parsing Kicklayout at 0xcc440f 
(3324 bytes)
Booting config 1AmigaOS_4.1_Final_Edition
Loading loader
.of
Loading kernel
Loading FastFileSystem
Loading SmartFilesystem
Loading peg2ide
.device.kmod
Loading battclock
.resource.kmod
Loading bootmenu
.kmod
Loading bootimage
Loading CDFileSystem
Loading con
-handler.kmod
Loading console
.device.kmod
Loading diskboot
.kmod
Loading diskboot
.config
Loading diskcache
.library.kmod
Loading dos
.library.kmod
Loading elf
.library.kmod
Loading env
-handler.kmod
Loading FileSystem
.resource.kmod
Loading gadtools
.library.kmod
Loading gameport
.device.kmod
Loading graphics
.library.kmod
Loading hunk
.library.kmod
Loading input
.device.kmod
Loading intuition
.library.kmod
Loading it8212ide
.device.kmod
Loading keyboard
.device.kmod
Loading keymap
.library.kmod
Loading lsi53c8xx
.device.kmod
Loading newlib
.library.kmod
Loading nonvolatile
.library.kmod
Loading nvram
.config
Loading ps2
.resource.kmod
Loading ram
-handler.kmod
Loading ramdrive
.device.kmod
Loading ramlib
.kmod
Loading shell
.kmod
Loading strap
.kmod
Loading timer
.device.kmod
Loading PCIGraphics
.card
Loading ATIRadeon
.chip
Loading siliconmotion502
.chip
Loading petunia
.library.kmod
Loading usbresource
.library
Loading usbsys
.device
Loading hub
.usbfd
Loading bootmouse
.usbfd
Loading bootkeyboard
.usbfd
Loading massstorage
.usbfd
Loading uhci
.usbhcd
Loading ohci
.usbhcd
Loading ehci
.usbhcd
Loading mounter
.library
Starting exec


But then nothing happens.
If I add ,x-vga=on

I get this error:

qemu-system-ppc: -device vfio-pci,host=3b:00.0,bus=pci.1,x-vga=onvfio 0000:3b:00.0failed getting region info for VGA region index 8Invalid argument
device does not support requested feature x
-vga

It seems an error you have when no external monitor is attached. But I have it

Any hint?

i'm really tired...
Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Just popping in
Just popping in


See User information
@afxgroup

I don't know about the error, but it seems you forgot to include
RadeonRX.chip in your Kicklayout.

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Amigans Defender
Amigans Defender


See User information
@nikitas

You where right, but no changes. Always on "Starting exec"
How do you enable more debug?

i'm really tired...
Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Just popping in
Just popping in


See User information
@afxgroup

I found this:
Quote:
"A workaround is available in qemu, by adding the parameter "x-igd-gms=1" to the according IGD device line."


So it could be?
x-vga=on,x-idg-gms=1


You also use:
-display sdl,gl=on

I don't think you need this at all.

For more debugging output you can add:
-d guest_errors,unimp


For getting logs from the guest, I think you can add:
-append "os4_commandline serial debuglevel=3"

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Quite a regular
Quite a regular


See User information
@all
Can you test this QEMU patch This should fix interrupts on pci.0 while it should make no difference for pci.1 so only could iprove things when using pci.0 and should not break things when using pci.1 (or no bus=pci.0 option as default for pegasos2 is pci.1). You should be able to apply to QEMU git master with git am command.

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Quite a regular
Quite a regular


See User information
@nikitas
Quote:
I found this:
Quote:
"A workaround is available in qemu, by adding the parameter "x-igd-gms=1" to the according IGD device line."

So it could be?
x-vga=on,x-idg-gms=1

I don't know what that is but IGD is Intel integrated graphics so this would do nothing for a Radeon device. With a laptop it might be difficult to configure pass through as the Radeon device should be removed from host and configured to load no host drivers only vfio so I don't know if that was done correctly. Getting some more logs or trying with a Linux guest that can give more diagnostics could help to debug it.

Quote:
You also use:
-display sdl,gl=on

I don't think you need this at all.

It should not hurt either as this just sets the grapchics backend QEMU uses. But since you have no window to display (guest should use the passed through card) it also does not matter.

Quote:
For more debugging output you can add:
-d guest_errors,unimp

For getting logs from the guest, I think you can add:
-append "os4_commandline serial debuglevel=3"


You don't need os4_commandline in -append. That's the variable name when you set it from pegasos2.rom but for -append it only needs the values as the kernel command line is the only variable -append can set. So it's just -append 'serial debuglevel=7' You can experiment with different debug levels but too high won't boot so maybe up to 12-13 still works but less may be enough. Running with -d unimp,guest_errors is useful if it crashes otherwise it might not print an error.

I don't know what your Linux kernel Oops means but at least it has some stack trace to some code that could show what operations it tried to do so could give some idea about the problem but have to check the kernel code to find out. This is why testing with Linux might help because with AmigaOS we don't know what it does and we can't get much info from the errors so those might only help if @Hans can find out what's wrong based on those. With Linux guest we have more insight what it does.

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Quite a regular
Quite a regular


See User information
@nikitas
In any case si_dpm_init and radeon_pm_init in the Linux backtrace as well as the line before the Oops talking about fan control suggests it's some issue with power management of the card. Hans also suspeted the card may be running at lower clocks that could also be because of missing power management so maybe that's where we should look. Is there a way to disable power management in Linux and set the card to run at some fixed value? Also may meed some options to Linux guest to make it skip power management for this card but I don't know what are those options or if they exist.

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Amigans Defender
Amigans Defender


See User information
@balaton

Radeon card is using vfio also on laptop:

3b:00.0 Display controller [0380]: Advanced Micro DevicesInc. [AMD/ATILexa [Radeon 540X/550X/630 RX 640 E9171 MCM] [1002:6987] (rev c0)
    
SubsystemHewlett-Packard Company Lexa [Radeon 540X/550X/630 RX 640 E9171 MCM] [103c:854b]
    
Kernel driver in use: vfio-pci
    Kernel modules
amdgpu


I've enabled the debug and messages are almost the same @nikitas has on desktop pc

Invalid write at addr 0xFE000080size 1region '(null)'reasonrejected
Invalid write at addr 0x80
size 1region '(null)'reasonrejected

With my previous command line and:

PegasosII Boot Strap (c2002-2003 bplan GmbH
Running on CPU PVR
:80020102
Enable L1 ICache
...                                                    Done.
mv64361_writeUnimplemented register write 0x108 0
Clean
/Flush Block enabled
mv64361_read
Unimplemented register read 0x160
mv64361_write
Unimplemented register write 0x160 3000
Reading W83194 
:                                                       FAILED.
Setting Front Side Bus to 133MHz...                                    FAILED.
Invalid write at addr 0xFE000E43size 1region '(null)'reasonrejected
Invalid write at addr 0xE43
size 1region '(null)'reasonrejected
Invalid write at addr 0xFE000E44
size 1region '(null)'reasonrejected
Invalid write at addr 0xE44
size 1region '(null)'reasonrejected
Invalid read at addr 0xFE000E41
size 1region '(null)'reasonrejected
Invalid read at addr 0xE41
size 1region '(null)'reasonrejected
Invalid read at addr 0xFE000E42
size 1region '(null)'reasonrejected
Invalid read at addr 0xE42
size 1region '(null)'reasonrejected
Invalid write at addr 0xFE000E40
size 1region '(null)'reasonrejected
Invalid write at addr 0xE40
size 1region '(null)'reasonrejected
Configuring DDR
...mv64361_writeUnimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1494 291
mv64361_write
Unimplemented register write 0x1480 300000
mv64361_write
Unimplemented register write 0x10 0
mv64361_write
Unimplemented register write 0x210 0
mv64361_write
Unimplemented register write 0x20 0
mv64361_write
Unimplemented register write 0x220 0
mv64361_write
Unimplemented register write 0x8 0
mv64361_write
Unimplemented register write 0x208 20000000
mv64361_write
Unimplemented register write 0x18 40000000
mv64361_write
Unimplemented register write 0x218 60000000
mv64361_write
Unimplemented register write 0x1400 58200400
mv64361_write
Unimplemented register write 0x1404 24110051
mv64361_write
Unimplemented register write 0x1408 12813330
mv64361_write
Unimplemented register write 0x140c 11b
mv64361_write
Unimplemented register write 0x1414 0
mv64361_write
Unimplemented register write 0x1410 22
mv64361_write
Unimplemented register write 0x1418 5
mv64361_read
Unimplemented register read 0x1418
mv64361_write
Unimplemented register write 0x1418 1
mv64361_read
Unimplemented register read 0x1418
mv64361_write
Unimplemented register write 0x1420 0
mv64361_write
Unimplemented register write 0x1418 4
mv64361_read
Unimplemented register read 0x1418
mv64361_write
Unimplemented register write 0x141c 162
mv64361_write
Unimplemented register write 0x1418 3
mv64361_read
Unimplemented register read 0x1418
mv64361_write
Unimplemented register write 0x141c 62
mv64361_write
Unimplemented register write 0x1418 3
mv64361_read
Unimplemented register read 0x1418
mv64361_write
Unimplemented register write 0x1418 1
mv64361_read
Unimplemented register read 0x1418
mv64361_write
Unimplemented register write 0x1418 2
mv64361_read
Unimplemented register read 0x1418
mv64361_write
Unimplemented register write 0x1418 2
mv64361_read
Unimplemented register read 0x1418
                                                     Done
.
Configuring PCI0...mv64361_writeUnimplemented register write 0xc3c ffffffff
mv64361_read
Unimplemented register read 0x10
mv64361_write
Unimplemented register write 0xc08 0
mv64361_read
Unimplemented register read 0x210
mv64361_write
Unimplemented register write 0xd08 0
mv64361_read
Unimplemented register read 0x20
mv64361_write
Unimplemented register write 0xc0c 0
mv64361_read
Unimplemented register read 0x220
mv64361_write
Unimplemented register write 0xd0c 0
mv64361_write
Unimplemented register write 0xc10 0
mv64361_write
Unimplemented register write 0xd10 0
mv64361_write
Unimplemented register write 0xd18 0
mv64361_write
Unimplemented register write 0xc14 0
mv64361_write
Unimplemented register write 0xd14 0
mv64361_write
Unimplemented register write 0xd1c 0
mv64361_write
Unimplemented register write 0xd20 0
mv64361_write
Unimplemented register write 0xd24 0
mv64361_write
Unimplemented register write 0xd28 0
mv64361_write
Unimplemented register write 0xe00 0
                                                    Done
.
Configuring PCI1...mv64361_writeUnimplemented register write 0xcbc ffffffff
mv64361_read
Unimplemented register read 0x10
mv64361_write
Unimplemented register write 0xc88 0
mv64361_read
Unimplemented register read 0x210
mv64361_write
Unimplemented register write 0xd88 0
mv64361_read
Unimplemented register read 0x20
mv64361_write
Unimplemented register write 0xc8c 0
mv64361_read
Unimplemented register read 0x220
mv64361_write
Unimplemented register write 0xd8c 0
mv64361_write
Unimplemented register write 0xc90 0
mv64361_write
Unimplemented register write 0xd90 0
mv64361_write
Unimplemented register write 0xd98 0
mv64361_write
Unimplemented register write 0xc94 0
mv64361_write
Unimplemented register write 0xd94 0
mv64361_write
Unimplemented register write 0xd9c 0
mv64361_write
Unimplemented register write 0xda0 0
mv64361_write
Unimplemented register write 0xda4 0
mv64361_write
Unimplemented register write 0xda8 0
mv64361_write
Unimplemented register write 0xe80 0
                                                    Done
.
Configuring ETH...mv64361_writeUnimplemented register write 0x2290 3f
mv64361_read
Unimplemented register read 0x10
mv64361_write
Unimplemented register write 0x2204 0
mv64361_write
Unimplemented register write 0x2200 0
mv64361_read
Unimplemented register read 0x210
mv64361_write
Unimplemented register write 0x220c 0
mv64361_write
Unimplemented register write 0x2208 0
mv64361_read
Unimplemented register read 0x20
mv64361_write
Unimplemented register write 0x2214 0
mv64361_write
Unimplemented register write 0x2210 0
mv64361_read
Unimplemented register read 0x220
mv64361_write
Unimplemented register write 0x221c 0
mv64361_write
Unimplemented register write 0x2218 0
mv64361_write
Unimplemented register write 0x2220 0
mv64361_write
Unimplemented register write 0x2224 0
mv64361_write
Unimplemented register write 0x2228 0
mv64361_write
Unimplemented register write 0x222c 0
mv64361_write
Unimplemented register write 0x2290 3f
mv64361_write
Unimplemented register write 0x2000 e0
                                                     Done
.
mv64361_writeUnimplemented register write 0xd9c 1ffff000
mv64361_read
Unimplemented register read 0xcbc
mv64361_write
Unimplemented register write 0xcbc 0
mv64361_write
Unimplemented register write 0xf008 30011
mv64361_write
Unimplemented register write 0x1d00 801f0030
mv64361_read
Unimplemented register read 0xc80
mv64361_write
Unimplemented register write 0xc80 0
mv64361_read
Unimplemented register read 0x1424
mv64361_write
Unimplemented register write 0x1424 1000000
Releasing IDE reset 
...                                                Done.
Configuring Legacy Devices
Initializing KBD
...Invalid write at addr 0xFE0003F0size 1region '(null)'reasonrejected
Invalid write at addr 0x3F0
size 1region '(null)'reasonrejected
Invalid write at addr 0xFE0003F1
size 1region '(null)'reasonrejected
Invalid write at addr 0x3F1
size 1region '(null)'reasonrejected
                                                    Done
.
Invalid write at addr 0xFE000084size 1region '(null)'reasonrejected
Invalid write at addr 0x84
size 1region '(null)'reasonrejected
Invalid write at addr 0xFE000085
size 1region '(null)'reasonrejected
Invalid write at addr 0x85
size 1region '(null)'reasonrejected
Invalid write at addr 0xFE000086
size 1region '(null)'reasonrejected
Invalid write at addr 0x86
size 1region '(null)'reasonrejected
Invalid write at addr 0xFE000088
size 1region '(null)'reasonrejected
Invalid write at addr 0x88
size 1region '(null)'reasonrejected
Invalid write at addr 0xFE00008C
size 1region '(null)'reasonrejected
Invalid write at addr 0x8C
size 1region '(null)'reasonrejected
Invalid write at addr 0xFE00008D
size 1region '(null)'reasonrejected
Invalid write at addr 0x8D
size 1region '(null)'reasonrejected
Invalid write at addr 0xFE00008E
size 1region '(null)'reasonrejected
Invalid write at addr 0x8E
size 1region '(null)'reasonrejected
Testing 00000000 Bytes
Pass00000000 Failed00000000
RAM TEST 
(fill linear)...                                              Done.
FFFFFFFF
invalid eieio using bit 6 at 
@fff063dc

Entering IKARUS low level console


If I use:

taskset -c 1 \
 qemu
-system-ppc \
 
-M pegasos2 \
 
-m 2G \
 
-vga none \
 
-bios pegasos2.rom \
 
-drive if=none,id=cd -device ide-cd,drive=cd,bus=ide.1 \
 
-drive if=none,id=hd,file=./hdpeg.img,format=raw -device ide-hd,drive=hd,bus=ide.0 \
 
-device vfio-pci,host=3b:00.0,bus=pci.1 \
 
-rtc base=localtime,clock=rt \
 
-serial stdio \
 
-device rtl8139,netdev=nic -netdev user,hostname=pegasos-os4,hostfwd=tcp::6000-:6000,id=nic \
 
-display sdl,gl=on \
 
-d guest_errors,unimp

i'm really tired...
Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Just popping in
Just popping in


See User information
@balaton

Quote:
Can you test this QEMU patch This should fix interrupts on pci.0 while it should make no difference for pci.1 so only could iprove things when using pci.0 and should not break things when using pci.1 (or no bus=pci.0 option as default for pegasos2 is pci.1). You should be able to apply to QEMU git master with git am command.

Once more, thank you for your work and your insistence on improving QEMU PPC. I will try it and I will inform you.

Quote:
In any case si_dpm_init and radeon_pm_init in the Linux backtrace as well as the line before the Oops talking about fan control suggests it's some issue with power management of the card.


What in the world could be happening with my machine... Every power management is disabled in UEFI. And I followed instructions to disable every PCIe power management on Ubuntu 24.04. I'll investigate further though.

In the worst case, I will keep the cards and I'll throw the PC into the sea. I might get one with a Ryzen CPU.

I would like to advise me if you know what mobos + CPUs combinations serve best QEMU/KVM, QEMU PPC, and virtualization in general.

Go to top
Re: Qemu + VFIO GPU RadeonRX 550 + AmigaOS4 extremely slow
Amigans Defender
Amigans Defender


See User information
@balaton

I've tested the patch but no changes here.. even because with both pci.0 and .1 I have the same results

i'm really tired...
Go to top

  Register To Post
« 1 ... 5 6 7 (8) 9 10 11 12 »

 




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




Powered by XOOPS 2.0 © 2001-2024 The XOOPS Project