joncampbell123 / dosbox-x

DOSBox-X fork of the DOSBox project
GNU General Public License v2.0
2.57k stars 374 forks source link

Oddity with IDE 32bit and Windows 98 with large drives #1423

Open nckstwrt opened 4 years ago

nckstwrt commented 4 years ago

Apologies, as I haven't been able to find the root cause yet, but thought I should put this up before I forget.

Once we start using large HDs we hit the cylinders > 1023 issue. DOS doesn't handle that, so the code has imageDisk::Set_Geometry to fiddle with the number of heads.

Now whether I used -size 512,63,16,8126 or -size 512,63,127,1023 to mount a 4GB volume I got issues with IDE/32-bit writing in Win 98.

Strangely, the install would go fine as would many basic operations. But when I started to try and install/unzip larger things, like directx_dec2006_redist.exe, I would get errors about the cabinet being corrupt, etc.

Turning off IDE support (i.e. disabling all 32-bit protected-mode disk drivers under trouble-shooting) in Windows would fix it and I could install everything ok.

The only way I have found to fix this issue is by commenting out the code "fiddle" like so: / if(setCyl > 16384) LOG_MSG("This disk image is too big."); else if(setCyl > 8192) bigdisk_shift = 4; else if(setCyl > 4096) bigdisk_shift = 3; else if(setCyl > 2048) bigdisk_shift = 2; else if(setCyl > 1024) bigdisk_shift = 1; / Then, although I assume this would break things for having too high a cylinder count in DOS, it works fine in Win98 and using the full 4gb volume with 32 bit IDE works just fine. Not sure why yet though, as the "fiddle" seems completely valid to me.

Will investigate further - but thought I would raise as a bug/oddity in the meantime

nckstwrt commented 4 years ago

Hmmm, that change helped install directx - but didn't solve it - hmmm, something else is afoot.