# Detection trouble with ASRock A75 Extreme6 (AMD Hudson chipset?), FreeBSD 9.0



## FzZzT (Nov 10, 2012)

Hello,


```
vacutus:/mnt# uname -a
FreeBSD vacutus 9.0-RELEASE-p4 FreeBSD 9.0-RELEASE-p4 #0: Thu Aug 30 22:46:50 CEST 2012     
root@dev.nas4free:/usr/obj/nas4free/usr/src/sys/NAS4FREE-amd64  amd64
```

I have an ASRock Extreme6 A75 board:

http://www.asrock.com/mb/overview.asp?cat=Manual&Model=A75 Extreme6

It has 6 on-board SATA3 ports via a Hudson D3/AMD chipset, which work, and two "on-board" SATA3 ports via a ASMedia ASM1061 chipset (according to the manual). I don't think the latter is being detected correctly. This is what I see in dmesg:


```
ahci0: <ASMedia ASM1061 AHCI SATA controller> port 0xd050-0xd057,0xd040-0xd043,0xd030-0xd037,0xd020-
0xd023,0xd000-0xd01f mem 0xfe900000-0xfe9001ff irq 16 at device 0.0 on pci2
ahci0: AHCI v1.20 with 2 6Gbps ports, Port Multiplier supported
ahcich0: <AHCI channel> at channel 0 on ahci0
ahcich1: <AHCI channel> at channel 1 on ahci0
...
ahci1: <AHCI SATA controller> port 0xf190-0xf197,0xf180-0xf183,0xf170-0xf177,0xf160-0xf163,0xf150-0xf15f
mem 0xfeb49000-0xfeb497ff irq 19 at device 17.0 on pci0
ahci1: AHCI v1.30 with 4 6Gbps ports, Port Multiplier supported
ahcich2: <AHCI channel> at channel 0 on ahci1
ahcich3: <AHCI channel> at channel 1 on ahci1
ahcich4: <AHCI channel> at channel 2 on ahci1
ahcich5: <AHCI channel> at channel 3 on ahci1
...
atapci0: <AMD ATA controller> port 0x1f0-0x1f7,0x3f6,0x170-0x177,0x376,0xf100-0xf10f at device 20.1 on pci0
ata0: <ATA channel 0> on atapci0
ata1: <ATA channel 1> on atapci0
```

The last ataN lines are what I think is wrong. Here are the disks:


```
ada0 at ahcich0 bus 0 scbus0 target 0 lun 0
ada0: <WDC WD20EARX-008FB0 51.0AB51> ATA-8 SATA 3.x device
ada0: 600.000MB/s transfers (SATA 3.x, UDMA6, PIO 8192bytes)
ada0: Command Queueing enabled
ada0: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
ada0: Previously was known as ad4
ada1 at ahcich2 bus 0 scbus2 target 0 lun 0
ada1: <ST2000DL003-9VT166 CC32> ATA-8 SATA 3.x device
ada1: 600.000MB/s transfers (SATA 3.x, UDMA6, PIO 8192bytes)
ada1: Command Queueing enabled
ada1: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
ada1: Previously was known as ad8
ada2 at ahcich3 bus 0 scbus3 target 0 lun 0
ada2: <WDC WD20EARS-60MVWB0 51.0AB51> ATA-8 SATA 2.x device
ada2: 300.000MB/s transfers (SATA 2.x, UDMA5, PIO 8192bytes)
ada2: Command Queueing enabled
ada2: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
ada2: Previously was known as ad10
ada3 at ahcich4 bus 0 scbus4 target 0 lun 0
ada3: <WDC WD20EARS-00MVWB0 51.0AB51> ATA-8 SATA 2.x device
ada3: 300.000MB/s transfers (SATA 2.x, UDMA6, PIO 8192bytes)
ada3: Command Queueing enabled
ada3: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
ada3: Previously was known as ad12
ada4 at ahcich5 bus 0 scbus5 target 0 lun 0
ada4: <WDC WD20EARS-00MVWB0 51.0AB51> ATA-8 SATA 2.x device
ada4: 300.000MB/s transfers (SATA 2.x, UDMA6, PIO 8192bytes)
ada4: Command Queueing enabled
ada4: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
ada4: Previously was known as ad14
[b]ada5 at ata0 bus 0 scbus6 target 0 lun 0
ada5: <WDC WD20EFRX-68AX9N0 80.00A80> ATA-9 SATA 3.x device
ada5: 33.300MB/s transfers (UDMA2, PIO 8192bytes)
ada5: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
ada5: Previously was known as ad0
ada6 at ata1 bus 0 scbus7 target 0 lun 0
ada6: <WDC WD20EARS-00S8B1 80.00A80> ATA-8 SATA 2.x device
ada6: 33.300MB/s transfers (UDMA2, PIO 8192bytes)
ada6: 1907729MB (3907029168 512 byte sectors: 16H 63S/T 16383C)
ada6: Previously was known as ad2[/b]
```

It looks like it isn't detected as a SATA chipset. Is that correct? This might be why it's being limited to 33 MB/s?

This is really strange... there are 8 ports on board. Two (7/8) are "shared" with two eSATA ports, reportedly by the ASM1061 chipset. The dmesg suggests this is correct--there are only two ports. However, there are 6 other ports in that bank of 8 SATA ports, but only 4 are listed on ahci1. Maybe the other two are being seen on atapci0? These are all supposed to be from the same chipset (the Hudson D3 chipset), is that possible? Not sure if it would help, here is pciconf -lv:


```
ahci1@pci0:0:17:0:      class=0x010601 card=0x78001849 chip=0x78011022 rev=0x40 hdr=0x00
    vendor     = 'Advanced Micro Devices [AMD]'
    device     = 'Hudson SATA Controller [AHCI mode]'
    class      = mass storage
    subclass   = SATA
...
atapci0@pci0:0:20:1:    class=0x01018a card=0x780c1849 chip=0x780c1022 rev=0x00 hdr=0x00
    vendor     = 'Advanced Micro Devices [AMD]'
    device     = 'Hudson IDE Controller'
    class      = mass storage
    subclass   = ATA
...
ahci0@pci0:2:0:0:       class=0x010601 card=0x06121849 chip=0x06121b21 rev=0x01 hdr=0x00
    vendor     = 'ASMedia Technology Inc.'
    class      = mass storage
    subclass   = SATA
```

In the BIOS it's set to AHCI (not IDE or RAID), and I haven't seen any other settings relating to this...it only shows one place to change that (i.e., it doesn't have one entry for each chipset). I'll keep poking at it, but any ideas?


----------



## mav@ (Nov 11, 2012)

AMD chipsets allow to configure last two ports either as AHCI (together with the rest 4) or separately as legacy IDE. Your case seems like the last. Check your BIOS settings. Reporting speed of 33MB/s is a result of chip ID unknown to the driver. It should be fixed, but should not cause much problems.


----------



## FzZzT (Nov 11, 2012)

Yeah I actually figured that out but couldn't find this thread to update it... That fixed it though, disabling combined IDE mode. Thanks!


----------

