Console messages when copying file to SATA drive

I have installed an ext4 formatted Samsung EVO SATA drive into the Apalis Evaluation board v1.1A. Here are the lines from the console during boot:

    [    5.523496] iommu: Adding device 5f020000.sata to group 0
    [    5.531241] ahci-imx 5f020000.sata: phy impedance ratio is not specified.
    [    5.538987] ahci-imx 5f020000.sata: external osc is used.
    [    5.547271] ahci-imx 5f020000.sata: no ahb clock.
    [    5.552086] Can't support > 32 bit dma.
    [    5.555971] ahci-imx 5f020000.sata: Enable 32-bit DMA instead of 64-bit.
    [    5.562756] ahci-imx 5f020000.sata: AHCI 0001.0301 32 slots 1 ports 6 Gbps 0x1 impl platform mode
    [    5.571727] ahci-imx 5f020000.sata: flags: 64bit ncq sntf pm clo only pmp fbs pio slum part ccc sadm sds apst
    [    5.583241] scsi host0: ahci-imx
    [    5.586760] ata1: SATA max UDMA/133 mmio [mem 0x5f020000-0x5f02ffff] port 0x100 irq 150
...
    [    7.490865] ata1.00: ATA-11: Samsung SSD 860 EVO mSATA 250GB, RVT41B6Q, max UDMA/133
    [    7.490872] ata1.00: 488397168 sectors, multi 1: LBA48 NCQ (depth 31/32)
    [    7.495108] ata1.00: supports DRM functions and may not be fully accessible
    [    7.497238] ata1.00: configured for UDMA/133

Executed the following command to copy the root file system on MMC to SATA drive:

rsync -avPHx --numeric-ids / /media/sda1

During the copy operation, there are many many “failed command” messages on the console:

[  287.782584] ata1.00: status: { DRDY }
[  287.786241] ata1.00: failed command: WRITE FPDMA QUEUED
[  287.791467] ata1.00: cmd 61/08:98:f0:e0:85/00:00:1c:00:00/40 tag 19 ncq dma 4096 out
[  287.791467]          res 40/00:20:00:ee:85/00:00:1b:00:00/40 Emask 0x12 (ATA bus error)
[  287.807205] ata1.00: status: { DRDY }
[  287.810871] ata1: hard resetting link
[  288.290595] ata1: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
[  288.297169] ata1.00: supports DRM functions and may not be fully accessible
[  288.306647] ata1.00: supports DRM functions and may not be fully accessible
[  288.315696] ata1.00: configured for UDMA/33
[  288.322070] ata1: EH complete
[  288.365146] ata1.00: Enabling discard_zeroes_data

I don’t recall getting these errors when I was using Toradex Apalis iMX8 QuadMax 4GB Wi-Fi / Bluetooth V1.0A / NXP i.MX Release Distro 4.9.51-mx8-beta apalis-imx8

Any ideas as to what has changed and how I can eliminate these errors?

The Apalis iMX8 V1.0B is an early access sample and uses pre-relese version of iMX8 SOC. We found that SATA on that version of silicon works unstable on high speed. It works as expected on Apalis modules starting from V1.1B.
You can try:

  • use non RT kernel
  • Limit SATA speed to 1.5Gb using libata.force=1.5G Kernel parameter.

Thanks! When will the V1.1B modules be available?

I tried limiting the SATA speed, but it made no difference.

Is there a reason you think that the non-RT kernel would be better?

 [    5.531241] ahci-imx 5f020000.sata: phy impedance ratio is not specified.

Does the above line in the console log mean anything with respect to this problem?

Hi, I was told you get a latest version of Apalis iMX8 module. Is SATA issue still present or it works as expected?

Thanks

Yes, SATA is working with the new module. Thanks!

Thanks for update!