Page 2 of 2

Re: AHCI can't read and write blocks

Posted: Sun Jun 26, 2022 5:14 pm
by prcups
Octocontrabass wrote:Really? It successfully reads the disk when I do that. Where are you allocating this memory area?

Have you tried using debug tracing? For example, try adding "-d trace:handle_cmd_*" to your QEMU command line. There's a list of available trace events here.
How do you allocating memory to AHCI_BASE?I didn't design malloc and free functions, and these in std will produce an linking error. So I create an array of uint8 and transfer its address to AHCI_BASE.

Re: AHCI can't read and write blocks

Posted: Sun Jun 26, 2022 6:50 pm
by Octocontrabass
Since you don't have an allocator yet, I picked an unused address in my VM's memory map.

How big is your array? It needs to be around 300kB since the wiki driver doesn't use any dynamic allocation.

Re: AHCI can't read and write blocks

Posted: Mon Jun 27, 2022 10:26 am
by prcups
Octocontrabass wrote:Since you don't have an allocator yet, I picked an unused address in my VM's memory map.

How big is your array? It needs to be around 300kB since the wiki driver doesn't use any dynamic allocation.
The problem has been solved. I carelessly forgot to delete AHCI_BASE macro. Thanks for your help these days. :D