Search by Tags

SATA

 
Applicable for

Tags

Compare with Revision

Subscribe for this article updates

SATA aka Serial ATA originally AT Attachment Interface

Kernel Boot Messages

With an attached SSD disk on the mSATA interface:

Apalis iMX6
[    1.719235] sata phy RX_PLL is stable!
[    1.719265] ahci: SSS flag set, parallel bus scan disabled
[    1.719295] ahci ahci: AHCI 0001.0300 32 slots 1 ports 3 Gbps 0x1 impl platform mode
[    1.719308] ahci ahci: flags: ncq sntf stag pm led clo only pmp pio slum part ccc apst
[    1.737976] scsi0 : ahci_platform
[    1.738214] ata1: SATA max UDMA/133 mmio [mem 0x02200000-0x02203fff] port 0x100 irq 71
...
[    2.280594] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
...
[    2.296130] ata1.00: ATA-8: KINGSTON SMS200S330G, 507KC4, max UDMA/133
[    2.296142] ata1.00: 58626288 sectors, multi 16: LBA48 NCQ (depth 31/32)
...
[    2.315811] ata1.00: configured for UDMA/133

Apalis T30
[    4.589972] tegra-sata tegra-sata.0: AHCI 0001.0300 32 slots 1 ports 3 Gbps 0x1 impl TEGRA-SATA mode
[    4.599387] tegra-sata tegra-sata.0: flags: 64bit ncq sntf pm led pio slum part apst
[    4.608496] scsi0 : tegra-sata
[    4.612050] ata1: SATA max UDMA/133 irq 55
...
[    4.965401] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
...
[    4.992911] ata1.00: ATA-8: KINGSTON SMS200S330G, 507KC4, max UDMA/133

Performance

root@apalis-imx6:~# hdparm -t /dev/sda

/dev/sda:
 Timing buffered disk reads: 336 MB in  3.00 seconds = 111.89 MB/sec

root@apalis_t30:~# hdparm -t /dev/sda

/dev/sda:
 Timing buffered disk reads: 138 MB in  3.03 seconds =  45.59 MB/sec

Speed Limiting

The SATA 2 link can be forced to SATA 1 speeds by adding 'libata.force=1.5Gbps' to the kernel cmdline as follows (altering kernel boot arguments from within U-Boot):

setenv defargs $defargs libata.force=1.5Gbps

Which then looks as follows during boot:

Apalis iMX6
[    1.721183] sata phy RX_PLL is stable!
[    1.721211] ahci: SSS flag set, parallel bus scan disabled
[    1.721243] ahci ahci: AHCI 0001.0300 32 slots 1 ports 3 Gbps 0x1 impl platform mode
[    1.721256] ahci ahci: flags: ncq sntf stag pm led clo only pmp pio slum part ccc apst
[    1.738069] scsi0 : ahci_platform
[    1.738303] ata1: FORCE: PHY spd limit set to 1.5Gbps
[    1.738309] ata1: SATA max UDMA/133 mmio [mem 0x02200000-0x02203fff] port 0x100 irq 71
...
[    2.280645] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
...
[    2.301559] ata1.00: ATA-8: KINGSTON SMS200S330G, 507KC4, max UDMA/133
[    2.301565] ata1.00: 58626288 sectors, multi 16: LBA48 NCQ (depth 31/32)
[    2.321251] ata1.00: configured for UDMA/133

Apalis T30
[    4.589079] tegra-sata tegra-sata.0: AHCI 0001.0300 32 slots 1 ports 3 Gbps 0x1 impl TEGRA-SATA mode
[    4.598493] tegra-sata tegra-sata.0: flags: 64bit ncq sntf pm led pio slum part apst
[    4.607584] scsi0 : tegra-sata
[    4.611131] ata1: FORCE: PHY spd limit set to 1.5Gbps
[    4.616551] ata1: SATA max UDMA/133 irq 55
...
[    4.972244] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
...
[    5.054028] ata1.00: ATA-8: KINGSTON SMS200S330G, 507KC4, max UDMA/133
[    5.054055] ata1.00: 58626288 sectors, multi 16: LBA48 NCQ (depth 31/32), AA

And performs as follows:

root@apalis-imx6:~# hdparm -t /dev/sda

/dev/sda:
 Timing buffered disk reads: 332 MB in  3.01 seconds = 110.47 MB/sec

root@apalis-t30:~# hdparm -t /dev/sda

/dev/sda:
 Timing buffered disk reads: 120 MB in  3.02 seconds =  39.78 MB/sec