Lubuntu

BPro mainline kernel 4.x SATA problem

3 1179
Kiruna  
Hi all,

I have a Banana Pro running the legacy kernel 3.4.103 for a long time
(using Lubuntu 14.04, but I think this plays no role for my problem)

Now I want to switch to a mainline kernel. I have compiled mainline
u-boot-2015.10 (Bananapro_defconfig) and mainline kernel 4.2.6
(sunxi_defconfig). The new system boots fine from sdcard, however, SATA ist dead.
There are no /dev/sdX devices present, I can use only sdcard
(and maybe USB, not tested).

The boot log reports a problem with the sata phy:
[    0.973481] ahci-sunxi 1c18000.sata: PHY power up failed.
[    0.979097] ahci-sunxi: probe of 1c18000.sata failed with error -5

Interestingly, u-boot shows a similar error message. Even from u-boot
I cannot access any sata drives.

I have changed the kernel configuration to have

CONFIG_SATA_AHCI_PLATFORM=y
CONFIG_AHCI_SUNXI=y

so sata is compiled into the kernel, not a module.

Neither SSD nor a magnetic disk attached to sata do work.
The drive is powered by the 2-pin header next to
the micro USB power plug.
Booting the legacy kernel again, sata works fine, so the hardware is
correct.

I have also tried mainline kernel 4.3 but with the same problem.


Maybe some helpful stuff:


-------------------------------------------------
$ uname -a
Linux coconut 4.2.6 #3 SMP Sun Nov 15 21:05:43 CET 2015 armv7l armv7l armv7l GNU/Linux

$ ll /dev/sda*
ls: cannot access /dev/sda*: No such file or directory

$ sudo fdisk -l
(shows only the mmcblk0 drives)

$ dmesg |grep sata
[    0.973481] ahci-sunxi 1c18000.sata: PHY power up failed.
[    0.979097] ahci-sunxi: probe of 1c18000.sata failed with error -5

$ cat /proc/cpuinfo
processor    : 0
[...]

processor    : 1
[...]

Hardware    : Allwinner sun7i (A20) Family
Revision    : 0000
Serial        : 165166c602c1120b
-------------------------------------------------------


Do you have any suggestions what is going wrong here?


Thank you very much
Regards
Kiruna





Hello,

My banananpi connected SATA HDD works with linux-4.4-rc2.
Are you using new sun7i-a20-bananapro.dtb in u-boot?
following my configuration and some commands result.

kernel config:
  1. CONFIG_BLK_DEV_SD=m
  2. CONFIG_CHR_DEV_SG=m
  3. CONFIG_SATA_AHCI=m
  4. CONFIG_SATA_AHCI_PLATFORM=m
  5. CONFIG_AHCI_SUNXI=y
Copy the Code

  1. $ uname -a
  2. Linux pi 4.4.0-rc2p1 #1 SMP Mon Nov 23 23:03:57 JST 2015 armv7l armv7l armv7l GNU/Linux

  3. $ dmesg
  4.   --- snip ---
  5. [    1.112679] ahci-sunxi 1c18000.sata: controller can't do PMP, turning off CAP_PMP
  6. [    1.120475] ahci-sunxi 1c18000.sata: SSS flag set, parallel bus scan disabled
  7. [    1.127851] ahci-sunxi 1c18000.sata: AHCI 0001.0100 32 slots 1 ports 3 Gbps 0x1 impl platform mode
  8. [    1.137061] ahci-sunxi 1c18000.sata: flags: ncq sntf stag pm led clo only pio slum part ccc
  9. [    1.147123] scsi host0: ahci-sunxi
  10. [    1.151106] ata1: SATA max UDMA/133 mmio [mem 0x01c18000-0x01c18fff] port 0x100 irq 32
  11.   --- snip ---
  12. [    1.480686] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
  13.   --- snip ---
  14. [    1.810301] ata1.00: ATA-8: TOSHIBA MQ01ABD100, AX001A, max UDMA/100
  15. [    1.829212] ata1.00: 1953525168 sectors, multi 16: LBA48 NCQ (depth 31/32)
  16. [    1.849951] ata1.00: configured for UDMA/100
  17. [    1.867695] scsi 0:0:0:0: Direct-Access     ATA      TOSHIBA MQ01ABD1 1A   PQ: 0 ANSI: 5
  18.   --- snip ---
  19. [    8.095825] sd 0:0:0:0: [sda] 1953525168 512-byte logical blocks: (1.00 TB/931 GiB)
  20. [    8.095834] sd 0:0:0:0: [sda] 4096-byte physical blocks
  21. [    8.096250] sd 0:0:0:0: [sda] Write Protect is off
  22. [    8.096265] sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
  23. [    8.096459] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
  24. [    8.387348] sd 0:0:0:0: [sda] Attached SCSI disk
  25.   --- snip ---
  26. [    8.398961] sd 0:0:0:0: Attached scsi generic sg0 type 0


  27. # dd if=/dev/sda bs=1M skip=409600 count=1024 of=/dev/null
  28. 1024+0 records in
  29. 1024+0 records out
  30. 1073741824 bytes (1.1 GB) copied, 11.4062 s, 94.1 MB/s
Copy the Code


Thank you,
Hiroyuki
my github, gist

Note: The author has been banned or deleted.

I have recently downloaded the software. I have also read the best essay help reviews about this software. I have clarified my doubts regarding to this error.

You have to log in before you can reply Login | Sign Up

Points Rules