Thank you, Eric!

-I will do some testing of reading the CF card outside of the FreeDOS
kernel, as you suggest.
-My BIOS supports both CHS and LBA. FreeDOS is using CHS due to the size of
the CF card (~500MB). I will try forcing LBA.
-I log interrupt calls out to my serial debugger on my 286. In execrh(), I
am not seeing any INT13H calls get called.
-I will need to learn more about disk I/O drivers. I assume for the IDE CF
Card, that driver is part of the FreeDOS kernel code. If I wanted to add
some debug code to the driver, where should I look to find the driver source
code? I see a "drivers" folder in the source, but the only thing that looks
related is floppy.asm. I can try adding some logging code in this file.
-My system does not support DMA at this stage. I am using PIO mode only.
-I have my system running quite slowly (8MHz system bus, 4MHz processor
clock) at this stage.

I have updated the following post with additional details:
https://www.rehsdonline.com/post/troubleshooting-freedos-boot-on-my-286-syst
em-hangs-on-execrh-call-in-kernel. I will continue to update this as I
(hopefully) progress in this troubleshooting.

I appreciate all the suggestions. Thank you again, Eric!

Rich


-----Original Message-----
From: Eric Auer <e.a...@jpberlin.de> 
Sent: Friday, May 5, 2023 3:07 AM
To: freedos-devel@lists.sourceforge.net
Subject: Re: [Freedos-devel] trying to understand execrh.asm -- calls to
EXECRH cause my 286 system to lock up


Hi Rich,

> I am trying to better understand the EXECRH function in execrh.asm 
> <https://github.com/FDOS/kernel/blob/66df13c4d867b49558a85929a13432df6
> 3cf5ac 0/kernel/execrh.asm> . Could someone help me understand the 
> call being made in EXECRH of "call  far[.dhp]"? To where is it 
> calling, and should I have done something in my BIOS or elsewhere to 
> support this call?
> 
> Additional Details: During boot on my 286 build the system hangs...

> *     The rqblockio() function then calls execrh() [execrh.asm].

Well, this is how the kernel calls drivers. Apart from the detail that it
does STI, CLD as a side effect, which should not disturb other parts of the
kernel, it will call some kind of disk I/O driver in the context you
describe.

You write that you use a custom built BIOS for your 286, and a compact flash
card on IDE adapter as drive. So I suggest that you do some testing of the
BIOS itself, without DOS. You could write a small test case and install it
as boot sector. Maybe the BIOS has issues with the mentioned flag changes or
maybe it simply does not yet have sufficiently foolproof disk error
handling, so it fails when there is more disk access? Does the BIOS support
both CHS and LBA? Which one is used for booting?

You can pass options to SYS to force one of the other and you can use SYS
CONFIG to patch the kernel to force that as well.
It might also be some issue related to stack usage, DMA or the address
ranges used by DOS, disk I/O and maybe other drivers?

Interesting project in any case, I like to hear about your progress when you
got FreeDOS to boot on your custom BIOS!

Regards, Eric

PS: CF cards in the past were meant to access few, large files.
So they had few I/O per seconds. Sometimes they had hiccups.




_______________________________________________
Freedos-devel mailing list
Freedos-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-devel

Reply via email to