OSDev.org

The Place to Start for Operating System Developers
It is currently Fri Apr 19, 2024 10:05 pm

All times are UTC - 6 hours




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: ATA DASP- signal
PostPosted: Sat Nov 09, 2013 4:40 pm 
Offline
Member
Member

Joined: Sun May 27, 2012 1:00 am
Posts: 45
Location: Russia
I read (on http://www.pcguide.com/ref/hdd/if/ide) that ATA cable was almost directly connected to ISA bus. More precisely - through thin buffer logic. i.e. all ISA signals were transmitted to ATA cable. And from ATA cable to ISA (e.g. IRQ demand). So, I can simply read/write registers of currently selected disk. Where "disk" I mean disk controller on bottom of IDE HDD.

But next I read about DASP- signal (Disk Active/Slave Present). ATA spec says that this signal asserted by currently selected disk when it is active(busy) and used by master (Disk 0) to detect slave (Disk 1) presence (after reset, power on or execute device diagnostic). Hmmm.... This totally confused me. Why master need to detect slave and why separate line/signal are need for signalling busy state? Host can simply read device status register and see busy bit only (other bits may be in unspecified condition when busy=1)...

About master/slave relations I found only:
Quote:
From: Hale Landis
Subject: Master/Slave Handshaking
...
One of the problems with ATA-1 is the unclear way that
master/slave handshaking is described and how the results of this
activity affect following operations. This is really unfortunate
since there are more pages of the ATA-1 document devoted to this
topic than to any other part of the ATA interface.
Lets review the background... The only reasons that this
handshaking is needed is to make ATA devices "look" like a single
device controller with one or two devices, or in other words, to
"look" like an MFM controller with one or two drives. Why do
this? Only one reason: software compatibility -- making two
controllers "look" like one controller.
There are three events that invoke master/slave handshaking
(master is also known as drive 0, slave is also known as drive
1):
- after power on or hardware reset, drive 0’s controller sets
BSY=0 when the reset function is completed by both
controllers.
- after software reset, drive 0’s controller sets BSY=0 when the
reset function is completed by both controllers.
- after a Diagnostic command, drive 0’s controller sets BSY=0
when the diagnostic command is completed by both controllers.
The master/slave handshaking is uni-directional: the slave sends
signals to the master so that the master can determine when the
slave has completed one of these three functions.

So, I need help in clarification of DASP- signal purpose and master/slave relations/handshaking...

P.S: so, all this mess with "reset of both devices on cable only", "unable to select other device when current selected is busy", "master/slave handshaking" is due to it is needed to make ATA devices "look" like a single device controller with one or two devices, or in other words, to "look" like an MFM controller with one or two drives. When you see weird thing in PC (like keyboard controller since AT, ATA interface, ...) then the reason is backwads compatibility... Without this I can simply select what device on cable I want to communicate with and control it by usual way: reading/writing its registers.

P.P.S: Communication with device is prohibited while BSY=1. So I even can't select other device when current device is busy. Thanks to intention to represent 2 controllers on each disk as one controller and 2 disks: this makes BSY to be a busy signal of this virtual controller. But it is logical to have possibility to select or reset one device when you need independently from other device.

Am I right?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 83 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group