Bug 201676 - [ahci] AHCI timeouts on Mac Mini model 7,1
Summary: [ahci] AHCI timeouts on Mac Mini model 7,1
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Some People
Assignee: Martin Wilke
Depends on:
Reported: 2015-07-18 15:44 UTC by Ruben Kerkhof
Modified: 2019-07-08 10:17 UTC (History)
1 user (show)

See Also:

Add quirk for Samsung on Mac Mini (795 bytes, application/mbox)
2015-07-18 15:44 UTC, Ruben Kerkhof
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ruben Kerkhof 2015-07-18 15:44:05 UTC
Created attachment 158944 [details]
Add quirk for Samsung on Mac Mini

Installing -CURRENT as of 20150718 on my Mac Mini immediately gives ahci timeout errors.
Disabling msi for this specific controller (vendor id 0x144d, Samsung, device 0x1600, rev 0x01) fixes this.

The Mac Mini has a PCI SSD identified as follows:

ruben@mini:~ % sudo camcontrol identify ada0
pass0: <APPLE SSD SM0256F UXM2JA1Q> ATA8-ACS SATA 3.x device
pass0: 600.000MB/s transfers (SATA 3.x, UDMA6, PIO 8192bytes)

protocol              ATA/ATAPI-8 SATA 3.x
device model          APPLE SSD SM0256F
firmware revision     UXM2JA1Q
serial number         S1K4NYAG415185
WWN                   5002538655584d30
cylinders             16383
heads                 16
sectors/track         63
sector size           logical 512, physical 4096, offset 0
LBA supported         268435455 sectors
LBA48 supported       490234752 sectors
PIO supported         PIO4
DMA supported         WDMA2 UDMA6 
media RPM             non-rotating

Feature                      Support  Enabled   Value           Vendor
read ahead                     yes	yes
write cache                    yes	yes
flush cache                    yes	yes
overlap                        no
Tagged Command Queuing (TCQ)   no	no
Native Command Queuing (NCQ)   yes		32 tags
NCQ Queue Management           no
NCQ Streaming                  no
Receive & Send FPDMA Queued    no
SMART                          yes	no
microcode download             yes	yes
security                       yes	no
power management               yes	yes
advanced power management      no	no
automatic acoustic management  yes	no	0/0x00	128/0x80
media status notification      no	no
power-up in Standby            no	no
write-read-verify              no	no
unload                         no	no
general purpose logging        yes	yes
free-fall                      no	no
Data Set Management (DSM/TRIM) yes
DSM - max 512byte blocks       yes              8
DSM - deterministic read       no
Host Protected Area (HPA)      yes      no      490234752/490234752
HPA - Security                 no

pciconf -lv shows:
ahci0@pci0:4:0:0:	class=0x010601 card=0x00000000 chip=0x1600144d rev=0x01 hdr=0x00
    vendor     = 'Samsung Electronics Co Ltd'
    class      = mass storage
    subclass   = SATA

dmesg after the attached patch is applied:

ahci0: <Samsung AHCI SATA controller> mem 0xa0800000-0xa0801fff at device 0.0 on pci4
ahci0: AHCI v1.30 with 1 6Gbps ports, Port Multiplier not supported
ahci0: quirks=0x1000<NOMSI>
ahci0: Caps: 64bit NCQ AL CLO 6Gbps PMD 32cmd CCC 1ports
ahci0: Caps2:
ahcich0: <AHCI channel> at channel 0 on ahci0
ahcich0: Caps:
Comment 1 commit-hook freebsd_committer 2018-11-02 07:48:43 UTC
A commit references this bug:

Author: miwi
Date: Fri Nov  2 07:48:23 UTC 2018
New revision: 340041
URL: https://svnweb.freebsd.org/changeset/base/340041

  - Add quirk for Samsung on Mac Mini 7,1

  PR:		201676
  Submitted by:	Ruben Kerkhof
  Approved by:	araujo (mentor)
  Obtained from:	TrueOS
  Sponsored by:	iXsystems Inc.
  Differential Revision:	https://review.freebsd.org/D17815

Comment 2 Martin Wilke freebsd_committer 2018-11-02 07:48:58 UTC
Committed, Thank you.
Comment 3 commit-hook freebsd_committer 2019-07-08 10:17:18 UTC
A commit references this bug:

Author: mav
Date: Mon Jul  8 10:17:01 UTC 2019
New revision: 349829
URL: https://svnweb.freebsd.org/changeset/base/349829

  MFC r340041 (by miwi): - Add quirk for Samsung on Mac Mini 7,1

  PR:		201676
  Submitted by:	Ruben Kerkhof

_U  stable/12/