You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This PR implements a RAM drive based on XMS memory for ELKS applications.
Based on discussion in #2256 (comment) as well as #2254, the intention is to provide a simple way forward to allow large programs, such as web browsers or text editors to quickly swap internal data to and from disk (XMS ramdisk in this case) without having to add XMS memory read/write routines directly into the application.
This option is configured in menuconfig under Filesystem Support by selecting Use XMS Memory (CONFIG_FS_XMS) and then selecting XMS RAM Disk (CONFIG_FS_XMS_RAMDISK). XMS system buffers continue to work as before, if selected.
The system doesn't currently check that there is in fact enough XMS memory (memory above 1M address) in the system, so one must be careful not to over-allocate the RAM allocation when running ramdisk.
The ramdisk utility is used to create the RAM disk (current max 16Mb), here is an example of creating and using a 3MB MINIX ramdisk:
For use in swapping memory quickly to disk, the ramdisk may want to be mounted on /tmp, or wherever is best suited for the programs that will use it.
Note that we are almost out of kernel text address space, so the regular (main memory) RAM disk (CONFIG_BLK_DEV_RAM) should not be selected. This barely leaves room for networking, UNIX sockets, and all the other functions recently being used by OpenWatcom programs. This issue will be fixed in a later PR.
Awesome!
What is "ssd" in this case? "Solid state drive" does not make enough sense.
How ramdisk /dev/ssd make 3072 knows that /dev/ssd should be linked to XMS memory exactly?
Or "/dev/ssd" is alsways the XMS memory? I think I am just confused by the name. I was expecting /dev/xms I suppose.
We can also have compressed executables cached on /tmp/swap.
We can also have an ISA card based on RaspPI for example that acts as a ramdrive for older 8086 systems for /tmp/swap.
I'm also very interested in this development, as it is really a portable way to support XMS. I'd cheer for XMS on 286 too using loadall function. Does @Mellvik TLVC support XMS on 286?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR implements a RAM drive based on XMS memory for ELKS applications.
Based on discussion in #2256 (comment) as well as #2254, the intention is to provide a simple way forward to allow large programs, such as web browsers or text editors to quickly swap internal data to and from disk (XMS ramdisk in this case) without having to add XMS memory read/write routines directly into the application.
This option is configured in menuconfig under Filesystem Support by selecting
Use XMS Memory(CONFIG_FS_XMS) and then selectingXMS RAM Disk(CONFIG_FS_XMS_RAMDISK). XMS system buffers continue to work as before, if selected.The system doesn't currently check that there is in fact enough XMS memory (memory above 1M address) in the system, so one must be careful not to over-allocate the RAM allocation when running
ramdisk.The
ramdiskutility is used to create the RAM disk (current max 16Mb), here is an example of creating and using a 3MB MINIX ramdisk:For use in swapping memory quickly to disk, the ramdisk may want to be mounted on /tmp, or wherever is best suited for the programs that will use it.
Note that we are almost out of kernel text address space, so the regular (main memory) RAM disk (CONFIG_BLK_DEV_RAM) should not be selected. This barely leaves room for networking, UNIX sockets, and all the other functions recently being used by OpenWatcom programs. This issue will be fixed in a later PR.