Hard Disc Parameters shouldn't be shown for SCSI disk

Discussion of development and patch submission.
Post Reply
Posts: 10
Joined: Thu 12 Nov, 2020 2:28 am

Hard Disc Parameters shouldn't be shown for SCSI disk

Post by DOS »

When selecting an image file for a SCSI hard disk, the "Hard Disc Parameters" dialog box appears, prompting for the "Sectors", "Heads", "Cylinders" and "Type", and the first three are stored in the .cfg file. However these don't really have the relevance that they do for ATA/IDE disks as the OS doesn't actually need to know them. I gather that there is a SCSI command that can be sent to the disk to ask for the sectors per track, heads and cylinders counts, but I think that just returns placeholder values - from the v16 sources in src/scsi_hd.c:

Code: Select all

                        add_data_len(1); add_data_len(0); /*Sectors per track*/

Code: Select all

                        add_data_len(0); add_data_len(0x10); add_data_len(0); /*Cylinder count*/
                        add_data_len(64); /*Heads*/
So three hopefully minor issues here:

1. It seems like the "Sectors", "Heads" and "Cylinders" could probably be returned fairly easily in the above code. I'm not aware of what software might actually send the SCSI command(s) to fetch those values though, and I doubt anyone cares about them returning the correct values, so I guess another option would be to just not prompt for those values.

2. I don't think the "Type" is meaningful at all and probably shouldn't be prompted for.

3. If "Sectors", "Heads" and "Cylinders" are still prompted for, it'd be nice if there was a note in the dialog pointing out that those values don't control what an operating system such as DOS sees when it makes BIOS calls, and that instead the geometry of the disk as presented to the operating system is controlled by the SCSI BIOS.

Is this something that is likely to get fixed, or if I tried fixing it myself is it likely that the patch would be accepted?
Apologies in advance for not responding, I don't check back here very often.
Posts: 38
Joined: Mon 18 Jul, 2022 9:07 pm

Re: Hard Disc Parameters shouldn't be shown for SCSI disk

Post by wishusknight »

thread necro... Different hard files can be used with different controllers. So one can use technically the same hard drive with either scsi or IDE. All hard drives are universally plugged in the virtual world.
Post Reply