Opened 18 months ago

Last modified 11 months ago

#13778 new bug

"check_sense: encountered DEFERRED ERROR - bye, bye" spams syslog

Reported by: waddlesplash Owned by: nobody
Priority: normal Milestone: Unscheduled
Component: Drivers/Disk Version: R1/Development
Keywords: Cc:
Blocked By: Blocking:
Has a Patch: no Platform: All

Description

As in title:

KERN: check_sense: encountered DEFERRED ERROR - bye, bye
KERN: Last message repeated 4 times.
KERN: Last message repeated 2 times.

Attaching syslog. Let me know if additional tracing would help in some way.

Attachments (1)

syslog (301.9 KB) - added by waddlesplash 18 months ago.
syslog

Download all attachments as: .zip

Change History (5)

Changed 18 months ago by waddlesplash

Attachment: syslog added

syslog

comment:1 Changed 18 months ago by korli

As in https://github.com/haiku/haiku/blob/master/src/add-ons/kernel/generic/scsi_periph/error_handling.cpp#L40

Seems like it's AHCI related?

KERN: ahci: Probe: port 1 link speed 1.5Gb/s
1411	KERN: ahci: sata_request::finish ATA command 0xa0 failed: status 0x51, error 0x20
1412	KERN: ahci: sata_request::finish ATAPI packet 25 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 (len 10)
1413	KERN: check_sense: encountered DEFERRED ERROR - bye, bye

comment:2 Changed 18 months ago by diver

Looks like a dupe of #13559.

comment:3 Changed 11 months ago by waddlesplash

Here's our code that runs that command: http://xref.plausible.coop/source/xref/haiku/src/add-ons/kernel/busses/scsi/ahci/sata_request.cpp#105

Here's the equivalent module from FreeBSD: http://xref.plausible.coop/source/xref/freebsd-11-stable/sys/dev/ahci/ahci.c#2385

It looks like FreeBSD sets bytes 7 and 15 also for 0xa0 (ATA_PACKET_CMD) with constants ("use LBA addressing" / "4 head bits"), and we don't. It also looks like they mask the length differently -- they just set bytes 5 and 6 to the length and length >> 8, while we also mask off 0xff.

comment:4 Changed 11 months ago by waddlesplash

<PulkoMandy> the masks make no difference if you are putting things into bytes anyways
<PulkoMandy> they do fis[1] = (ccb->ccb_h.target_id & 0x0f); and we don't
Note: See TracTickets for help on using tickets.