BananaPi R4 SSD Sometimes not detected

I just got my BananaPi R4 and put an ADATA Legend 710(1TB) in it. Sometimes when I boot it the ssd does not get detected but if I reboot again it will get detected. Any ideas? Thanks in advance

lspci shows nothing when ssd is not detected and shows this when it’s detected:

0002:00:00.0 PCI bridge: MEDIATEK Corp. Device 7988 (rev 01) 0002:01:00.0 Non-Volatile memory controller: ADATA Technology Co., Ltd. XPG GAMMIXS1 1L, XPG GAMMIX S5, LEGEND 710 / 740, SWORDFISH NVMe SSD (DRAM-less) (rev 01)

Confirm i have similar on r3 (looks like related on sw reboot)…but have not got it nailed down further.

1 Like

Should we mention anyone that can do something about this problem?

Try a patch simular to:

But then for your card.

1 Like

Having to build a custom kernel just to have the basic features is too much of a hassle.

You can try it, if it works, have it added to standard kernel. But you do not know, unless you try…

2 Likes

Then buy any NVMe listed here, because it means that it is supported in the linux kernel (and OpenWrt) and works without problems on Banana Pi BPI-R3 / BPI-R4 and therefore you don’t have to patch the kernel to add a quirk:

Check if your BPI-R4 has the R228 and R230 resistors mentioned in this thread and if it does, remove them:

P.S. This does not happen in Windows or with Intel and Nvidia products, because they are “plug and play”.

1 Like
dmesg | grep nvme

May show something usefull…

As I have said in the post that you’ve replied to, it shows nothing. literally nothing.

When ssd is detected:

[    3.344178] nvme 0002:01:00.0: vgaarb: pci_notify
[    3.348897] nvme 0002:01:00.0: assign IRQ: got 111
[    3.353823] nvme nvme0: pci function 0002:01:00.0
[    3.358565] nvme 0002:01:00.0: enabling device (0000 -> 0002)
[    3.364307] nvme 0002:01:00.0: enabling bus mastering
[    3.377859] nvme 0002:01:00.0: save config 0x00: 0x57661cc1
[    3.383422] nvme 0002:01:00.0: save config 0x04: 0x00100406
[    3.388991] nvme 0002:01:00.0: save config 0x08: 0x01080201
[    3.394553] nvme 0002:01:00.0: save config 0x0c: 0x00000000
[    3.400121] nvme 0002:01:00.0: save config 0x10: 0x28200004
[    3.405683] nvme 0002:01:00.0: save config 0x14: 0x00000000
[    3.411250] nvme 0002:01:00.0: save config 0x18: 0x00000000
[    3.416818] nvme 0002:01:00.0: save config 0x1c: 0x00000000
[    3.422380] nvme 0002:01:00.0: save config 0x20: 0x00000000
[    3.427946] nvme 0002:01:00.0: save config 0x24: 0x28204000
[    3.433507] nvme 0002:01:00.0: save config 0x28: 0x00000000
[    3.439075] nvme 0002:01:00.0: save config 0x2c: 0x57661cc1
[    3.444637] nvme 0002:01:00.0: save config 0x30: 0x00000000
[    3.450205] nvme 0002:01:00.0: save config 0x34: 0x00000040
[    3.455766] nvme 0002:01:00.0: save config 0x38: 0x00000000
[    3.461334] nvme 0002:01:00.0: save config 0x3c: 0x0000016f
[    3.613656] nvme nvme0: allocated 64 MiB host memory buffer.
[    3.698305] nvme nvme0: 4/0/0 default/read/poll queues
[    3.712924]  nvme0n1: p1
[    3.715685] nvme 0002:01:00.0: vgaarb: pci_notify
[    7.226264] systemd[1]: Expecting device dev-nvme0n1p1.device - /dev/nvme0n1p1...
[   12.492137] EXT4-fs (nvme0n1p1): mounted filesystem 0c1c4b10-aa49-4263-a07f-c87d8a28a473 r/w with ordered data mode. Quota mode: disabled.

When it’s not detected:

[    6.727276] systemd[1]: Expecting device dev-nvme0n1p1.device - /dev/nvme0n1p1...

This line is printed because i’ve added the mentioned entry to fstab.