Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
34 user(s) are online (25 user(s) are browsing Forums)

Members: 0
Guests: 34

more...

Support us!

Headlines

 
  Register To Post  

« 1 ... 22 23 24 (25) 26 27 28 ... 75 »
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@Hans
There don't seem to be much communication with the card by the AmigaOS Radeon driver before setting up CCE but I don't have time to go through each of those now but maybe somebody can spot something. I get:
ati_mm_write 4 0x230 OVR_CLR <- 0x0
ati_mm_write 4 0x234 OVR_WID_LEFT_RIGHT 
<- 0x0
ati_mm_write 4 0x238 OVR_WID_TOP_BOTTOM 
<- 0x0
ati_mm_write 4 0x420 OV0_SCALE_CNTL 
<- 0x0
ati_mm_write 4 0x1c0 MPP_TB_CONFIG 
<- 0x0
ati_mm_write 4 0x1c8 MPP_GP_CONFIG 
<- 0x0
ati_mm_write 4 0xf0 GEN_RESET_CNTL 
<- 0x0
ati_mm_write 4 0x540 SUBPIC_CNTL 
<- 0x0
ati_mm_write 4 0xc40 unknown 
<- 0x0
ati_mm_write 4 0x94 I2C_CNTL_1 
<- 0x0
ati_mm_write 4 0x950 CAP0_TRIG_CNTL 
<- 0x0
ati_mm_write 4 0x9c0 CAP1_TRIG_CNTL 
<- 0x0
ati_mm_write 4 0x224 CRTC_OFFSET 
<- 0x0
ati_mm_write 4 0x228 CRTC_OFFSET_CNTL  0x0
ati_mm_write 4 0x58 DAC_CNTL 
<- 0x100ff
ati_mm_write 4 0x22c CRTC_PITCH 
<- 0x50000000
ati_mm_write 4 0x224 CRTC_OFFSET  0x3
ati_mm_write 4 0x50 CRTC_GEN_CNTL 
<- 0x3
ati_mm_write 4 0x200 CRTC_H_TOTAL_DISP 
<- 0x63004f00
ati_mm_write 4 0x250 unknown 
<- 0x63004f00
ati_mm_write 4 0x204 CRTC_H_SYNC_STRT_WID 
<- 0x90028800
ati_mm_write 4 0x2c4 unknown 
<- 0x90028800
ati_mm_write 4 0x208 CRTC_V_TOTAL_DISP 
<- 0xf02df01
ati_mm_write 4 0x254 unknown 
<- 0xf02df01
ati_mm_write 4 0x20c CRTC_V_SYNC_STRT_WID  0x0
ati_mm_write 4 0x8 CLOCK_CNTL_INDEX 
<- 0x88000000
ati_mm_write 4 0xc CLOCK_CNTL_DATA 
<- 0x3000000
ati_mm_write 4 0xb74 unknown 
<- 0x0
ati_mm_write 4 0xb78 unknown 
<- 0xff3f0000
ati_mm_write 4 0xb7c unknown 
<- 0xa000
ati_mm_write 4 0x7d4 PM4_MICROCODE_ADDR 
<- 0x0
ati_mm_write 4 0x7dc PM4_MICROCODE_DATAH 
<- 0x0
ati_mm_write 4 0x7e0 PM4_MICROCODE_DATAL 
<- 0x700021
ati_mm_write 4 0x7dc PM4_MICROCODE_DATAH 
<- 0x0
ati_mm_write 4 0x7e0 PM4_MICROCODE_DATAL 
<- 0x700020
ati_mm_write 4 0x7dc PM4_MICROCODE_DATAH 
<- 0x4000000
ati_mm_write 4 0x7e0 PM4_MICROCODE_DATAL 
<- 0xb4000000
ati_mm_write 4 0x7dc PM4_MICROCODE_DATAH 
<- 0x4000000
ati_mm_write 4 0x7e0 PM4_MICROCODE_DATAL 
<- 0xb8000000
ati_mm_write 4 0x7dc PM4_MICROCODE_DATAH 
<- 0x0
ati_mm_write 4 0x7e0 PM4_MICROCODE_DATAL 
<- 0x4c4d5b6f

The above may be missing some lines as the forum engine just seems to drop them. Also the register names may be different from Radeon as it was originally for Rage128Pro but the addresses are mostly the same.

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
Edit: removed to avoid confusion. This methods only works on older Linux distros and pre 6.0 kernels


Edited by geennaam on 2023/6/29 15:06:15
Edited by geennaam on 2023/6/29 15:08:08
Edited by geennaam on 2023/6/29 15:08:46
Edited by geennaam on 2023/6/29 15:11:12
Edited by geennaam on 2023/6/29 15:25:05
Edited by geennaam on 2023/6/29 15:56:09
Edited by geennaam on 2023/7/3 19:00:51
Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@Hans
MorphOS pokes the regs much more, it even seems to do weird stuff like accessing VGA paged memory for some reason but ends up doing similar things eventually:
ati_mm_read 4 0x158 MEM_SDRAM_MODE_REG -> 0x10100000
ati_mm_write 4 0x284 unknown 
<- 0x0
ati_mm_write 4 0x228 CRTC_OFFSET_CNTL 
<- 0x0
ati_mm_write 4 0x328 CRTC2_OFFSET_CNTL  0x0
ati_mm_write 4 0x64 GPIO_DVI_DDC 
<- 0x30000
-- lots of DDC to read EDID
ati_mm_write 1 0x23 unknown 
<- 0x2
ati_mm_write 1 0x23 unknown 
<- 0x0
ati_mm_write 1 0x23 unknown 
<- 0x2
ati_mm_write 2 0x28e unknown 
<- 0x8000
ati_mm_write 1 0x5b DAC_CNTL 
<- 0xff
ati_mm_write 1 0x59 DAC_CNTL 
<- 0x40
ati_mm_write 2 0x28e unknown 
<- 0x8000
ati_mm_write 1 0x10 BIOS_0_SCRATCH 
<- 0x4
ati_mm_write 1 0x57 CRTC_EXT_CNTL  0
ati_mm_write 1 0x57 CRTC_EXT_CNTL  0
ati_mm_write 2 0x24 unknown 
<- 0x2
ati_mm_write 1 0x24 unknown 
<- 0x2
ati_mm_write 1 0x3f8 CRTC2_GEN_CNTL 
<- 0x0
ati_mm_write 1 0x55 CRTC_EXT_CNTL  0
ati_mm_write 1 0x27c unknown 
<- 0x0
ati_mm_write 2 0x24 unknown 
<- 0x2
ati_mm_write 1 0x27c unknown 
<- 0x0
ati_mm_write 1 0x28f unknown 
<- 0x80
ati_mm_write 1 0x293 unknown 
<- 0x80
ati_mm_write 1 0x8 CLOCK_CNTL_INDEX 
<- 0x83
ati_mm_write 4 0xc CLOCK_CNTL_DATA 
<- 0x3c
ati_mm_write 1 0x8 CLOCK_CNTL_INDEX 
<- 0x84
ati_mm_write 4 0xc CLOCK_CNTL_DATA 
<- 0x301c0
-- more poking here
ati_mm_write 4 0x224 CRTC_OFFSET 
<- 0x0
ati_mm_write 4 0x22c CRTC_PITCH 
<- 0x100
14.073
RadeonFailed to initialise Radeon DMA
ati_mm_write 4 0x774 PM4_FPU_FPA 
<- 0x0
ati_mm_write 4 0x770 PM4_FPU_FPB 
<- 0x0
ati_mm_write 4 0x7d4 PM4_MICROCODE_ADDR 
<- 0x0
ati_mm_write 4 0x7dc PM4_MICROCODE_DATAH 
<- 0x0
ati_mm_write 4 0x7e0 PM4_MICROCODE_DATAL 
<- 0x21007000
ati_mm_write 4 0x7dc PM4_MICROCODE_DATAH 
<- 0x0
ati_mm_write 4 0x7e0 PM4_MICROCODE_DATAL 
<- 0x20007000
ati_mm_write 4 0x7dc PM4_MICROCODE_DATAH 
<- 0x4
ati_mm_write 4 0x7e0 PM4_MICROCODE_DATAL 
<- 0xb4
ati_mm_write 4 0x7dc PM4_MICROCODE_DATAH 
<- 0x4
ati_mm_write 4 0x7e0 PM4_MICROCODE_DATAL 
<- 0xb8
ati_mm_write 4 0x7dc PM4_MICROCODE_DATAH 
<- 0x0
ati_mm_write 4 0x7e0 PM4_MICROCODE_DATAL 
<- 0x6f5b4d4c

Here I can see these are byte swapped compared to AmigaOS log. I've also noticed that MorphOS driver waits for the CCE FIFO to have empty slots befire writing and stops there as we report 0 but AmigaOS don't seem to care just write to the FIFO anyway. Not sure it checks in a different way or could overflow the FIFO on real card.

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Not too shy to talk
Not too shy to talk


See User information
Which graphics cards are relevant here? I'm assuming if we're doing passthrough then it has to be something that OS4 natively supports? The only spare card I have, IF I can get hold of a power cable for it (thats the whole reason it's spare, I've lost it in a house move) is a Sapphire RX580 which I assume is far too modern?


Amiga x5040 ı 16GB ı RX580
GB-A1000 060@100,
A1200 PiStorm32-Lite CM4
Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@balaton

Quote:
to my understanding the above setup now works with MorophOS passing through the 9250 but does not get picture with AmigaOS.


Not quite correct.
I do get an image for AmigaOS.
The AmigaOS4.1 boot logo shows up fine. (This might be a simple framebuffer?)
The workbench screen (desktop) is corrupted and has rendering issues. Probably because memory allocations are wrong and that it uses 2D GPU accelerations which do not work correctly.

So both MorphOS and amigaOS show pixels on the screen. MorphOS output is fine. AmigaOS4 is not.

Also AmigaOS4 doesn't show an image on the DVI output. Only on the VGA output. MotphOS can handle both outputs.
I's sure that the OS4 driver can handle DVI, becausye it works for the same card in my sam440.

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@MartinW

First of all: Welcome

Depends on the emulated machine. Because its limited by the x86 emulation inside the firmware/bios

AmigaOS4 itself can handle the RX580 just fine with the RadeonRX driver from enhancer.

But for now the emulated pegasos2 cannot handle such a card with its bios.

Best chance is Radeon is Radeon 9200pro/50

When the sam460 target is more mature then is should be able to handle at least a Radeon HD cards up to r7 280.

See here for a list of supported cards Radeon HD cards: http://hdrlab.org.nz/projects/amiga-o ... r-hardware-compatibility/

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@geennaam
Thanks for gathering these in one post for convenience.
You say multifunction=on should be on function 0 but the command lines have it on function 1 (e.g. host=03:04.1,multifunction=on) which is correct? The qemu command has some garbage at the front. I did not follow what happens if you use VGA but I'd say using bochs-display and adding x-vga=on for the 9250 as well may be better otherwise there may be some mix up between the emulated VGA and the passed through card which also has VGA mode.
Edit: Unless of course x-vga=on does not work with 9250 which could be based on the comment in source but I'm not sure it's even needed by AmigaOS, probably not as that only cares about the PCI BARs

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@balaton

Ah, my mistake. The first one. Corrected the commandlines.


Edited by geennaam on 2023/6/29 15:33:49
Edited by geennaam on 2023/6/29 15:34:53
Edited by geennaam on 2023/7/3 20:03:20
Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Not too shy to talk
Not too shy to talk


See User information
@geennaam

Thanks - for now I only have OS4 CDs for classic and Pegasos2.

I'm wondering if I should try to find a second hand card and likely a bridge card as well since my PC only has PCIe. I do have an older motherboard that is I think has an i7 6700k in it. That has a PCI slot but it probably getting a bit slow and I'd have no idea if it supports pass-through. It certainly predates it being popular that's for sure.

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@MartinW

This means that you can run AmigaOS4 on an emulated Pegasos2 with SM501 GPU emulation.


Edited by geennaam on 2023/7/3 20:02:54
Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@MartinW
Quote:

I'm wondering if I should try to find a second hand card and likely a bridge card as well since my PC only has PCIe. I do have an older motherboard that is I think has an i7 6700k in it. That has a PCI slot but it probably getting a bit slow and I'd have no idea if it supports pass-through. It certainly predates it being popular that's for sure.

According to https://en.wikipedia.org/wiki/List_of_ ... ocessors#%22Skylake-S%22_(quad-core,_14_nm) i7-6700K has VT-d so it should be OK but the motherboard chipset and BIOS must also handle it. As for how fast it would be it may worth a try if you already have that machine before getting new one because if it works it might at least be a good start.

You've mentioned problems with network. What specifically? On macOS you can either use -netdev user or -netdev vmnet but the latter may need some setup or run as root, I'm not sure. I think @Maijestro had something on it in the guide published on amiga-nows.de. If you're interested in trying to write a driver looking at making an AmigaOS driver for virtio-net may be a good way to start and learn. Borh the virtio-net device and Amiga API for network drivers (is that SANA2?) should be documented and sample code should be available. Once you get understanding how this works all other virtio device use the same mechanism to talk to the device which is a memory mapped ring buffer not unlike what ATI cards use so it should be simple to interface to those.

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Not too shy to talk
Not too shy to talk


See User information
@geennaam
Sure, I'm aware. I already have OS4 fully up and running in Qemu using SM501 on a spare disk in my gaming PC and on my day-to-day Mac Mini. It runs very well mostly, better than under WinUAE or FS-UAE, but of course it runs like a snail, or not at all as soon as you hit it with something that needs real GPU capabilities.

I am indeed debating whether to follow along and experiment with GPU passthrough. When I first got my current gaming PC a few years back that's how I had it, a very slim linux boot and then either Windows or Linux via virtIO. The motherboard is extremely good at segmenting all the bits and allowing passthrough. Right now it's not setup that way.

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@geennaam
Quote:

-device VGA,romfile="" will show the Pegasos SmartFirmware output in the QEMU window

Does that mean when using this with 9250 on vfio-pci without x-vga=on you see output in the emulated VGA? That's odd because this card does not have ROM so it must be the ATI ROM that writes something there but in that case those writes should go to the ATI card so that's why I said you'd better use bochs-display,romfile="" with x-vga=on on the ATI card instead. Or I'm just completly missing what you say.

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@balaton

Quote:
Does that mean when using this with 9250 on vfio-pci without x-vga=on you see output in the emulated VGA?



Yes, see #429 But only the smartfirmware output.

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Not too shy to talk
Not too shy to talk


See User information
@balaton

You read my mind somewhat on the networking! So when I say it's problematic, the RTL device will just stop working randomly. I noted from your web page that after the OS updates you may need to downgrade back to the version on the CD but it still does it. I used bridged mode by running qemu as root. I've built Qemu from source so I'm running on master, though I'm guessing that doesn't make a huge difference.

My NAS at home has a bridged interface which was doing a good job of upsetting OS4 (Roadshow?) because the MAC address would randomnly flick between the two ports on the interface. I changed that bridge to just be in standby / failover mode instead and I haven't checked to see if that has helped. I could certainly see it being problematic if it decided to switch half way through a big transfer. If that's even something that it would do.

I did also spend time reading through various documentation and notes, some of which may well have been from you (what you said sounds familiar) and I have to say, it didn't all fly miles over my head and I did end up thinking I could possibly take a look. That was probably a week or two back? I haven't ruled out looking into it. From memory I think I forumlated a plan in my head to see if I could implement some sort of stub driver that at least spits out some logging and if I get that far go from there.

Apologies if this is de-railing the main topic here!

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@MartinW

You can solve the networking issue by using the RTL driver on the Pegasos OS4.1 install CD.

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Not too shy to talk
Not too shy to talk


See User information
Unfortunately that's not 100% the case because I'm already doing that.

Just so you know how I'm running on my Mac Mini (M1)

#!/bin/bash

QEMU_BIN=/usr/local/bin/qemu-system-ppc

###################################
#
#         Pegasos2 Config
#
###################################

QEMU_CMD="sudo $QEMU_BIN \
-L pc-bios \
-M pegasos2 \
-m 1024 \
-cpu 7447 \
-accel tcg \
-rtc base=localtime \
-serial stdio \
-bios pegasos2.rom \
-vga none \
-device sm501 \
\
-device rtl8139,netdev=mynet0 \
-netdev vmnet-bridged,id=mynet0,ifname=en0 \
\
-display cocoa \
\
-audiodev coreaudio,id=audio0,out.format=s16,out.frequency=48000 \
\
-drive if=none,id=hd0,file=os41_pegasos2.img,format=raw \
-device ide-hd,drive=hd0,bus=ide.0 \
-drive if=none,id=hd1,file=os41_data.qcow2,format=raw \
-device ide-hd,drive=hd1,bus=ide.0 \
"
# -drive if=none,id=cd0,file=Pegasos2InstallCD-53.54.iso,format=raw \
# -device ide-cd,drive=cd0,bus=ide.1 \
# -full-screen"

# ${QEMU_CMD}
empty --i in.fifo -o out.fifo -empty.pid -empty.log $QEMU_CMD
empty --i out.fifo -o in.fifo "ok" "boot hd:0 amigaboot.of\n"
empty --i out.fifo -o in.fifo "(5 sec. until autoboot)" "2\n"

[ ! -e in.fifo ] || rm in.fifo
[ ! -e out.fifo ] || rm out.fifo

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Quite a regular
Quite a regular


See User information
@MartinW
Some people reported problems with network but others not. I'm not sure why that happens or how to find out so if somebody has an idea how to debug that from the AmigaOS side that may help. I could only suggest to try emulating different network device for the guest, see -device help for what's available but I think most of those have no driver in AmigaOS. The ne2k_pci is NE2000/RTL8029 compatible but maybe the drivers are not any better. I can't do much about this problem so if anybody has any idea how to find out why it hangs please speak up.

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Not too shy to talk
Not too shy to talk


See User information
@balaton

Understood - it's not a big problem for what I'm doing with OS4 at the moment. I can experiment to see if any other kinds of card work better for me. I also like the idea of looking at a driver.

Go to top
Re: What the fastest possible x64 emulation way of OS4 today ?
Just can't stay away
Just can't stay away


See User information
@MartinWQuote:
MartinW wrote:Unfortunately that's not 100% the case because I'm already doing that.

Just so you know how I'm running on my Mac Mini (M1)

#!/bin/bash

QEMU_BIN=/usr/local/bin/qemu-system-ppc

###################################
#
#         Pegasos2 Config
#
###################################

QEMU_CMD="sudo $QEMU_BIN \
-L pc-bios \
-M pegasos2 \
-m 1024 \
-cpu 7447 \
-accel tcg \
-rtc base=localtime \
-serial stdio \
-bios pegasos2.rom \
-vga none \
-device sm501 \
\
-device rtl8139,netdev=mynet0 \
-netdev vmnet-bridged,id=mynet0,ifname=en0 \
\
-display cocoa \
\
-audiodev coreaudio,id=audio0,out.format=s16,out.frequency=48000 \
\
-drive if=none,id=hd0,file=os41_pegasos2.img,format=raw \
-device ide-hd,drive=hd0,bus=ide.0 \
-drive if=none,id=hd1,file=os41_data.qcow2,format=raw \
-device ide-hd,drive=hd1,bus=ide.0 \
"
# -drive if=none,id=cd0,file=Pegasos2InstallCD-53.54.iso,format=raw \
# -device ide-cd,drive=cd0,bus=ide.1 \
# -full-screen"

# ${QEMU_CMD}
empty --i in.fifo -o out.fifo -empty.pid -empty.log $QEMU_CMD
empty --i out.fifo -o in.fifo "ok" "boot hd:0 amigaboot.of\n"
empty --i out.fifo -o in.fifo "(5 sec. until autoboot)" "2\n"

[ ! -e in.fifo ] || rm in.fifo
[ ! -e out.fifo ] || rm out.fifo



I also use Qemu Peg2 on my Mac M1, your line looks good so far. I also experimented with VMNET, but it was more unstable with the network connection. And I went back to the normal user.

-device rtl8139,netdev=network01 -netdev user,id=network01

With this the network runs stable most of the time, but every now and then it breaks down, unfortunately the error can't be reproduced because it happens randomly.

I would like to investigate why the network connection is lost from time to time. Maybe someone can help to solve this problem?

Also their audiodev line for core audio looks a bit different...their line:

-audiodev coreaudio,id=audio0,out.format=s16,out.frequency=48000

I use this line:

-audiodev coreaudio,id=audio0,out.frequency=48000

Where is the difference here ?

***Note:However, I don't want to deviate from the last topic GPU passthrough as it is very exciting and maybe useful information will be gained for the future ati-vga emulation.


Edited by Maijestro on 2023/6/29 17:31:44
Edited by Maijestro on 2023/6/29 17:32:36
MacStudio ARM M1 Max Qemu//Pegasos2 AmigaOs4.1 FE / AmigaOne x5000/40 AmigaOs4.1 FE
Go to top

  Register To Post
« 1 ... 22 23 24 (25) 26 27 28 ... 75 »

 




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




Powered by XOOPS 2.0 © 2001-2024 The XOOPS Project