BenLunt wrote:
I looked through your repo and I don't see where you have the actual binary file you are booting. Do you have it where we can download it and look? We are only getting one side here.
I deliberately didn't bundle the image file into the Git repo (having added '*.img', '*.bin', and '*.qcow2' to the
.gitignore file), as it gets automatically generated by the Makefile (which I posted earlier). I'll see about finding another place where I could save a copy to. However, I should mention that each of the test directories have their own copies of the image file, and each gets re-generated every time the it is built.
BenLunt wrote:
For example, what utility are you using to create the image? What utility writes to root directory for you?
mkfs.msdos is the formatting utility. The full lines used to create and format the file are
Code:
dd if=/dev/zero of=boot.img count=1440 bs=1k
mkfs.msdos -F 12 -n "VERBUM" boot.img
And yes, I now know that I could use
mkfs.msdos to create the file itself, but I kept this as it's been for the time being.
BenLunt wrote:
Are you using Linux and mounting the image to copy the secondary file to the image? If so, is Linux using a VFAT format? i.e.: adding long file names?
Yes to both, though I have made a point of sticking to all-caps 8.3 names.
BenLunt wrote:
Anyway, the above code, cmpsb, assumes that the filename you are searching for *and* the directory entry are 8.3 formatted. i.e.:
Code:
snd_stage_file db 'STAGE2 SYS'
I have seen utilities incorrectly place
Code:
snd_stage_file db 'STAGE2',0,0'SYS'
in the directory entry.
I've checked the image file with a hex editor (the Emacs 'hexl-mode', specifically), and the file was saved with trailing spaces, not trailing nulls. still, it may be best if I used the full eight characters instead (e.g., 'STAGETWOSYS') rather than making assumptions, or having to count out the spaces by hand.