Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[directfd] Add configurable bounce and cache buffers to DF driver #2082

Merged
merged 2 commits into from
Oct 18, 2024
Merged

Conversation

ghaerr
Copy link
Owner

@ghaerr ghaerr commented Oct 18, 2024

Improvements made to DF driver along the lines of discussion in Mellvik/TLVC#88. The ELKS DF driver still performs full-track caching, but with these changes should be fairly easy to add semi-track or fixed-size cache caching.

The DF driver is now configurable to allow sharing portions of DMASEG for separate bounce and cache buffers, if desired, without having to invalidate the cache when non-overlapped. Testing has not shown a big need for this (yet), as application writes always go into the system buffer area and queue up before driver write I/O is required. However, because ELKS can be configured for BIOS hard drive access and DF floppy, DMASEG is still unprotected, and the low memory segment either needs to be separated between the drivers, or mutex protection for any shared bounce buffers.

The heap-allocated bounce buffer is now removed (which was 64k address wrap unsafe BTW).
Recalculates, yet again, the IODELAY emulation delay, my last revision was incorrect; reverted.
Doesn't restart FDC kernel timeout on cache reads.
Removed improper illegal buffer usage message.
Refactors and simplifies some code.
Renames some variables to be closer to TLVC's directfd.c.
Retabs include/fdreg.h

Tested on QEMU w/caching, no caching, XMS and EXT buffers.

@ghaerr ghaerr merged commit 6b7f16d into master Oct 18, 2024
2 checks passed
@ghaerr ghaerr deleted the df2 branch October 18, 2024 16:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant