LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 11-04-2010, 03:03 AM   #1
galapogos
Member
 
Registered: May 2008
Posts: 227

Rep: Reputation: 30
What ATA command does read(), write() and dd translate to?


Hi,

As per the topic, what ATA commands do they translate to? Would a write be translated to WRITE SECTOR, WRITE DMA or WRITE BUFFER or the EXT versions of these commands?
 
Old 11-04-2010, 08:22 AM   #2
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,399
Blog Entries: 2

Rep: Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908
There is no absolute answer to this, since read()s and write()s are a couple of layers removed from the low-level hardware access. Also, it would depend on the filesystem type, since the organization of data on the media (not necessarily an ATA disk) depends on the the filesystem type. The driver for the media would determine the ATA commands employed. You should be able to determine this by looking at the kernel driver source code for the hardware type you use. It may be possible to access the media from user-space using the low-level semantics of the driver, however this would be most unconventional. Applications such as dd operate at the filesystem level, and do not know about the underlying hardware.

--- rod.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Read Write access to a iso9660 filesystem..mount a .iso image as read write ceazar123 Linux - Newbie 16 09-01-2010 09:07 AM
Read Write access to a iso9660 filesystem..mount a .iso image as read write ceazar123 Linux - General 2 08-26-2010 03:32 PM
Reiserfs vs JFS base on Read, Re-read, Write, Re-write Hesi Linux - Newbie 1 03-19-2010 04:08 AM
is there any shell command to read and write data from parallel and serial port? baosheng Linux - Hardware 2 01-13-2007 08:35 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 06:24 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration