From: bugzilla-daemon@bugzilla.kernel.org
To: linux-scsi@vger.kernel.org
Subject: [Bug 15185] New: Sending a 48bit ATA-Command with "CheckCondition" through SG_IO does not return correct 48bit sense descriptor
Date: Sun, 31 Jan 2010 11:30:00 GMT [thread overview]
Message-ID: <bug-15185-11613@http.bugzilla.kernel.org/> (raw)
http://bugzilla.kernel.org/show_bug.cgi?id=15185
Summary: Sending a 48bit ATA-Command with "CheckCondition"
through SG_IO does not return correct 48bit sense
descriptor
Product: SCSI Drivers
Version: 2.5
Kernel Version: 2.6.31
Platform: All
OS/Version: Linux
Tree: Mainline
Status: NEW
Severity: normal
Priority: P1
Component: Other
AssignedTo: scsi_drivers-other@kernel-bugs.osdl.org
ReportedBy: stefan.huebner@stud.tu-ilmenau.de
Regression: No
Example: sending a correct "READ_NATIVE_MAX_ADDRESS_EXT" to /dev/sdd (opened
O_RDWR | O_NONBLOCK) via ATA_PASSTHROUGH_16 (SCSI-Command 0x85) with the EXTEND
and the CHECK_CONDITION bits set to 1 yields sense data in descriptor-format.
Unfortunately, the descriptor does not have EXTEND set, and by that only
returns 24 Bits of LBA.
This obviously is a bug, as the SAT-2 Draft says: "If the sense data is for an
ATA PASS-THROUGH (16) command with the EXTEND bit set to one, then the SATL
shall return the 48-bit extended status and shall set the EXTEND bit to one."
Contents of important data-structures for SG_IO:
sg_io_hdr.cmdlen = 16
*sg_io_hdr.cmdp = {0x85 0x07 0x20 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00
0x00 0x00 0x27 0x00}
sense-data after command:
0x72 0x00 0x00 0x00 0x00 0x00 0x00 0x0e 0x09 0x0c 0x00 0x00 0x00 0x00 0x00 0xaf
0x00 0x6d 0x00 0x70 0x00 0x50
meaning: descriptor-sense, no error
descriptor:
code=0x09 -> ATA-Return descriptor
length=0x0c
EXTEND=0
Error = 0x00
SectorCount = 0x00
LBA_Low = 0xaf
LBA_Mid = 0x6d
LBA_High= 0x70
Device = 0
Status = DeviceReady | DeferredWriteError
The drive used should be reporting a native max lba of 0x74706daf (1.02TB), so
the expected sense data should look like:
0x72 0x00 0x00 0x00 0x00 0x00 0x00 0x0e 0x09 0x0c 0x01 0x00 0x00 0x00 0x6d 0xaf
0x74 0x70 0x00 0x00 0x00 0x50
--
Configure bugmail: http://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
next reply other threads:[~2010-01-31 11:30 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-31 11:30 bugzilla-daemon [this message]
2010-02-01 18:11 ` [Bug 15185] New: Sending a 48bit ATA-Command with "CheckCondition" through SG_IO does not return correct 48bit sense descriptor Douglas Gilbert
2010-02-01 18:25 ` Douglas Gilbert
2010-02-01 19:01 ` [Bug 15185] " bugzilla-daemon
2010-02-01 19:06 ` bugzilla-daemon
2010-02-01 21:22 ` bugzilla-daemon
2010-02-09 16:13 ` bugzilla-daemon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bug-15185-11613@http.bugzilla.kernel.org/ \
--to=bugzilla-daemon@bugzilla.kernel.org \
--cc=linux-scsi@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.