HDIO_SET_PIO_MODE and other IDE ioctls

From: ina (celina.miranda_at_eazix.com)
Date: 10/31/03


Date: 30 Oct 2003 18:42:14 -0800

I'm checking the IDE subsytem of a linux distribution. I've found out
that whenever I issue the ioctl HDIO_SET_PIO_MODE (hdparm -p 0
/dev/hdx) it returns an error "Function not implemented". But when i
try to issue the command hdparm -d0 -X0 /dev/hdx it reports: "setting
xfermode to 0 (default PIO mode)"

My question is: What is the difference between calling hdparm -p and
hdparm -X0 since they both set the PIO mode? How do I verify if the
desired PIO mode has been set?

Also, when i try to issue the ioctl HDIO_SET_ACOUSTIC, I get
"input/output error". Does it mean that the disk does not support
acoustic management? But when i try to query the device using hdparm
-I, it reports that it has acoustic management.

Celina Miranda



Relevant Pages

  • Re: [PATCH] barrier patch set
    ... everything is fine, RTFM (man hdparm). ... > different write cache setting. ... (uses HDIO_GET_IDENTIFY ioctl) ... send the line "unsubscribe linux-kernel" in ...
    (Linux-Kernel)
  • Re: HDIO_DRIVE_CMD and hdparm
    ... When using it on my own block device, hdparm ... When using it on an ATA or SCSI device, no such error message is printed. ... hdparm expects the HDIO_DRIVE_CMDioctl ...
    (Linux-Kernel)
  • Re: new tool: blktool
    ... all of the ATA device commands issued by hdparm ... can be supported in a driver by simply implementing the HDIO_DRIVE_CMD ... ioctl -- This is only a few lines of code in a typical SATA/SCSI driver, ... > hdparm works for some SCSI devices already, and support for ...
    (Linux-Kernel)
  • Re: hdparm almost burned my SATA disk
    ... > ioctl for device ... 100% harmless. ... passthru patches finally get released for real, I'll update hdparm to ... send the line "unsubscribe linux-kernel" in ...
    (Linux-Kernel)
  • Re: Hdparm and Acoustic Management : problem
    ... I am trying to use hdparm to set the "acoustic management" feature of my ... It works fine for one of the drives, a Maxtor Diamond, but when I try it ... BTW. I'm using a Maxtor tool Floppy also for IBM and Hitachi drives, ...
    (Ubuntu)