GithubHelp home page GithubHelp logo

Comments (5)

wwarthen avatar wwarthen commented on September 28, 2024

Hi @hubertushirsch,

It is actually operating as intended, but I understand that it is not obvious what is going on and I did not document it well.

I am out of town until Monday and I want to fully explain what is happening. I will post a complete response on Monday.

Thank you, Wayne

from romwbw.

wwarthen avatar wwarthen commented on September 28, 2024

Hi @hubertushirsch,

OK, I have a bit more time now, so let me expand on the problem you have encountered.

With respect to the output of the DIOMEDIA function, as you observed, the function is returning with E=4 (MID_HD512) even when the disk device is partitioned as MID_HD1K. The problem occurs because the HBIOS does not know how a hard disk is partitioned. By design, it does not examine the partition table. So, it will always return MID_HD512 for all hard disk media.

The differentiation between MID_HD_512 and MID_HD1K is made by the operating systems. When the operating systems see a hard disk (MID_512), they then read and interpret the partition table of the hard disk device to further determine if the format is MID_HD512 or MID_HD1K.

I fully appreciate this is confusing and the current HBIOS documentation does not properly describe this. I will leave this issue open until I have updated the documentation.

At this point, you are proobably wondering why there is an MID_HD1K enumaration, if it is never returned by the HBIOS. It is because it is used internally by the OSes. It is not really correct that the MID_HD1K enumaration exist in the HBIOS interface and I am going to take a look at removing it.

Regarding the DIOGEOMETRY function, you are also correct that I need to document the use of the high bit of D (which indicates the device is LBA capable). I will do that as well.

Again, this issue will remain open until I have corrected the documentation. I am extremely backed up right now with some commitments I need to deal with first. So, it may take me a few days to get the documentation corrected.

Thank you!

Wayne

from romwbw.

hubertushirsch avatar hubertushirsch commented on September 28, 2024

Hi Wayne

Thanks for the explanation. From my point of view this (HBIOS) is an abstraction layer for different hardware variants.

I don't think it's helpful to rewrite the additional code for every application and every OS that a user wants to implement again and again. HD512 and HD1K are two precisely documented variants of the hard drive. The return of the recognized variant by the HBIOS would be a good basis to support the user in writing consistent programs.

Let me write about my thoughts in more detail tonight.

Greetings
Hubert

from romwbw.

hubertushirsch avatar hubertushirsch commented on September 28, 2024

Hi Wayne

I have now looked at the source code and seen that the call to the DIOMEDIA function is forwarded to the respective driver.
So several drivers would be affected by the change (sd.asm, ide.asm, hdsk.asm and others). That would be a lot of work.
Another aspect is that existing operating systems or standalone programs would have to be changed, as they do not currently expect E=10 as a result (e.g. CBIOS).
So I accept the situation as it currently is.

I also noticed that in the System Guide (3.5.0) the media IDs are named differently than in hbios.inc.
MID_HD512 => MID_HD
MID_HD1K => MID_HDNEW

Regards
Hubert

from romwbw.

wwarthen avatar wwarthen commented on September 28, 2024

I have attempted to address the documentation deficiencies in my latest checkin (e07c38d).

I will leave this issue open for a few days in case there are additional comments.

Thanks, Wayne

from romwbw.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.