DC-IRC has quit [Remote host closed the connection]
DC-IRC has joined #armbian-amlogic
<DC-IRC> <c0rnelius77> 2f-454b-afd9-d217c0f66b8e&ref_=pd_gw_ci_mcx_mr_hp_atf_m along with an external power supply.
<DC-IRC> <vitekst> That will probably be an ASM1062 card, as my (ASM1064) is a quad port one, but it will be handled by the same driver. If you can’t find a quad port version with the ASM1064 controller, then it will probably be close enough.
<DC-IRC> <vitekst> But yeah, I also tried an external power supply while raising the voltage slightly, but to no avail.
<DC-IRC> <c0rnelius77> Have you tried an external power source?
<DC-IRC> <vitekst> Yes.
<DC-IRC> <c0rnelius77> ah
<DC-IRC> <c0rnelius77> hmm
<DC-IRC> <vitekst> …and with no drives attached while on that power supply.
<DC-IRC> <c0rnelius77> i mean attached to the drive, not the board. the board of course needs one.
<DC-IRC> <vitekst> No drives at all in the setup.
<DC-IRC> <vitekst> Just the board and the controller.
<DC-IRC> <vitekst> Just the board and the controller card.
<DC-IRC> <vitekst> Oh, sorry, I haven’t noticed the log. Oh my, the ASM1062 works.
<DC-IRC> <vitekst> Oh, sorry, I haven’t noticed the log. Oh my, the ASM1062 works at least on your board.
<DC-IRC> <vitekst> Thanks for testing at least that then. 🙂
<DC-IRC> <c0rnelius77> I went that as I can't see why two extra ports would be a game changer. If this one works in theory so should the one you have. I would think ur issue is power related.
<DC-IRC> <c0rnelius77> or lack there of
<DC-IRC> <vitekst> Well… I planned on attaching 4 drives.
<DC-IRC> <c0rnelius77> and each one would need to be properly powered by an external source I would think.
<DC-IRC> <vitekst> Is it? As I said, I tried running the setup with no drives powered on and even on a power source with U=5.25 V.
<DC-IRC> <vitekst> I’ve measured it.
<DC-IRC> <Werner> voltage can drop really fast 🙂
<DC-IRC> <tenkawa42> @vitekst you'll need a lot of current (amperage) to power 4 drives.. and you will likely run into backfeed issues if you don't have a regulator and external power
<DC-IRC> <vitekst> I actually intend to do that.
<DC-IRC> <vitekst> Well, I could add some filtering right next to the GPIO header, but it doesn't explain why the controller works just fine with a Sinovoip image.
<DC-IRC> <tenkawa42> What's it doing currently? (I missed the details)... there's many factors that could be different,,, kernel version.. connection settings
<DC-IRC> <vitekst> Same exact setup, same exact power supply, even with a single drive attached, but with running a manufacturer-supplied image with, I believe, a non-mainline `linux-aml` kernel.
<DC-IRC> <tenkawa42> Well... vendor vs mainline kernels are big in this regard a lot of the time
<DC-IRC> <vitekst> Armbian with 6.1.30, ASmedia ASM1064 mPCIe card attached, with or without any drives powered up: `ahci.ko`'s probe returns `-EINVAL`, probably because the driver for the PCIe controller didn't assign any BARs to the device.
<DC-IRC> <vitekst> Sinovoip's image (will post link soon) on the same setup: works just fine, controller shows up, I am able to use that drive just fine.
<DC-IRC> <vitekst> Armbian with 6.1.30 running on the BPi CM4IO, ASmedia ASM1064 mPCIe card attached, with or without any drives powered up: `ahci.ko`'s probe returns `-EINVAL`, probably because the driver for the PCIe controller didn't assign any BARs to the device.
<DC-IRC> <vitekst> Sinovoip's image (will post link soon) on the same setup: works just fine, controller shows up, I am able to use that drive just fine.
<DC-IRC> <vitekst> Armbian with 6.1.30 running on the BPi CM4IO, ASmedia ASM1064 mPCIe card attached, with or without any drives powered up: `ahci.ko`'s probe returns `-EINVAL`, probably because the driver for the PCIe controller didn't assign any BARs to the device, but `lspci` shows it.
<DC-IRC> <vitekst> Sinovoip's image (will post link soon) on the same setup: works just fine, controller shows up, I am able to use that drive just fine.
<DC-IRC> <vitekst> The Sinovoip's image I used is `2023-01-12-debian-10-buster-bpi-cm4-aarch64-sd-emmc.img` from: https://wiki.banana-pi.org/Banana_Pi_BPI-CM4#Linux
<DC-IRC> <tenkawa42> Comparing a buster image to anything 6.x is apples to oranges btw....
<DC-IRC> <tenkawa42> buster is very old
<DC-IRC> <vitekst> I know. I just wanted to imply that I don't really think this is a power issue.
<DC-IRC> <tenkawa42> Actually it very much could be
<DC-IRC> <vitekst> How so? What could I try?
<DC-IRC> <tenkawa42> They have changed a lot of handling in the IO handling in the kernel.... problem is... its no guarantee 6.x mainline "can" work
<DC-IRC> <vitekst> How so? What can I try?
<DC-IRC> <tenkawa42> One area to check is quirks entries for your hardware
<DC-IRC> <tenkawa42> see if they've added any
<DC-IRC> <tenkawa42> you might need to pass them at boot
<DC-IRC> <tenkawa42> I have to for NVMe with some RISC-V hardware currently in development
<DC-IRC> <vitekst> Hmm... well, it's true that the ASM1064 doesn't have any entries in the `ahci` driver, but the ASM1062, I believe, does.
<DC-IRC> <vitekst> Thanks for pointing me!
<DC-IRC> <vitekst> Thanks for pointing me! :)ú
<DC-IRC> <vitekst> Thanks for pointing me! 🙂
<DC-IRC> <tenkawa42> np... hopefully there's some useful info in that table
<DC-IRC> <tenkawa42> 6.1 was also a pai
<DC-IRC> <tenkawa42> 6.1 was also a pain
<DC-IRC> <tenkawa42> It was one of the buggiest kernel branches I've ever worked on
<DC-IRC> <tenkawa42> I'm still kind of surprised its a longterm still
<DC-IRC> <vitekst> Hmm, quick look revealed that there isn't anything special for the ASM1064.
<DC-IRC> <vitekst> ...and I've come to a realisation that the PCIe host driver enumerates the devices before the `ahci` driver kicks in.
<DC-IRC> <vitekst> The BAR should be allocated at that stage, but it isn't.
<DC-IRC> <vitekst> ...and I've come to a realisation that the PCIe host driver (`meson-pcie`?) enumerates the devices before the `ahci` driver kicks in.
<DC-IRC> <vitekst> Hmm, quick look revealed that there isn't anything special for the ASM1062.
<DC-IRC> <vitekst> The BAR(s) should be allocated at that stage, but it isn't.
<DC-IRC> <vitekst> The BAR(s) should be allocated at that stage, but it isn't / they aren't..