OSDev.org
https://forum.osdev.org/

How to access ALL the mass storage devices through BIOS?
https://forum.osdev.org/viewtopic.php?f=1&t=33442
Page 1 of 1

Author:  Kolodez [ Wed Jan 16, 2019 6:29 am ]
Post subject:  How to access ALL the mass storage devices through BIOS?

Hi!
E.g. with INT 13, AH=0x42, I can read a mass storage device. The "drive number" of the boot device is provides through DL to the bootstrap code.
But is there a way I can list all the other mass storage devices attached (HDDs, SDDs, USB drives), identify them and get their drive numbers?
It seems like a standard question, but I looked for it, and maybe I was just too stupid to find the answer?
Thank you for your help.

Author:  Octocontrabass [ Wed Jan 16, 2019 6:49 am ]
Post subject:  Re: How to access ALL the mass storage devices through BIOS?

You can't access all storage devices through the BIOS. You can only access the storage devices the BIOS knows how to access.

You can find out how many of those there are by reading the byte at address 0x475 (in the BDA). Drives are numbered sequentially, starting at 0x80.

After that, you can use whichever INT 0x13 calls you want to identify the drives.

Author:  Combuster [ Wed Jan 16, 2019 7:41 am ]
Post subject:  Re: How to access ALL the mass storage devices through BIOS?

Octocontrabass wrote:
You can only access the storage devices the BIOS knows how to access.
... and then only whatever it is willing to present to you. Expect having just your boot drive and one (other) harddisk.

Page 1 of 1 All times are UTC - 6 hours
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/