Skip to content
Commit 6a36261e authored by Tejun Heo's avatar Tejun Heo
Browse files

[PATCH] libata: fix READ CAPACITY simulation



* READ CAPACITY (16) implementation fixed.  Result was shifted by two
  bytes.  Carlos Pardo spotted this problem and submitted preliminary
  patch.  Capacity => 2TB is handled correctly now.  (verifid w/ fake
  capacity)

* Use dev->n_sectors instead of re-reading directly from ID data.

* Define and use ATA_SCSI_RBUF_SET() which considers rbuf length.
  This should be done for all simulation functions.  Userland can
  issue any simulated command with arbitrary buffer length.

Signed-off-by: default avatarTejun Heo <htejun@gmail.com>
Cc: Carlos Pardo <Carlos.Pardo@siliconimage.com>
parent 3d3cca37
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment