FreeBSD on Layerscape/QorIQ LX2160X

classic Classic list List threaded Threaded
102 messages Options
1234 ... 6
Reply | Threaded
Open this post in threaded view
|

FreeBSD on Layerscape/QorIQ LX2160X

Dan Kotowski
I'm wondering if anybody knows of work being done to port FreeBSD to the Layerscape platforms?

I happen to have a SolidRun HoneyComb LX2K workstation, based on NXP's Layerscape LX2160A, next to my desk running a custom-multistrapped Debian Jessie build, but would love to get FreeBSD running instead. I have only minimal experience working down in BSD driver/kernel land and no experience at all with Crochet, but would like to learn. And while I cannot afford to donate the actual hardware I'm happy to work with others to test builds.

Fortunately SolidRun provides the full DeviceTree and firmware sources in GitHub:

https://github.com/SolidRun/lx2160a_build

And some documentation about the board from their main website:

https://developer.solid-run.com/knowledge-base/honeycomb-lx2k/

https://developer.solid-run.com/knowledge-base/lx2160a-cex7-user-manual/

https://developer.solid-run.com/knowledge-base/freebsd/

Given how much information and source SolidRun has provided this might be a very simple build and bootstrap process - I just have no idea where to begin. SolidRun has some documentation on building for their Armada A38x micro-SOMs:

https://developer.solid-run.com/knowledge-base/freebsd/

Unforunately that relies on KERNCONF=ARMADA38X and I think that's going to miss support for all the nicest parts of the Layerscape 2160X.

Dan Kotowski
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

Marcin Wojtas
Hi Dan,


czw., 14 maj 2020 o 17:32 Dan Kotowski
<[hidden email]> napisał(a):

>
> I'm wondering if anybody knows of work being done to port FreeBSD to the Layerscape platforms?
>
> I happen to have a SolidRun HoneyComb LX2K workstation, based on NXP's Layerscape LX2160A, next to my desk running a custom-multistrapped Debian Jessie build, but would love to get FreeBSD running instead. I have only minimal experience working down in BSD driver/kernel land and no experience at all with Crochet, but would like to learn. And while I cannot afford to donate the actual hardware I'm happy to work with others to test builds.
>
> Fortunately SolidRun provides the full DeviceTree and firmware sources in GitHub:
>
> https://github.com/SolidRun/lx2160a_build
>
> And some documentation about the board from their main website:
>
> https://developer.solid-run.com/knowledge-base/honeycomb-lx2k/
>
> https://developer.solid-run.com/knowledge-base/lx2160a-cex7-user-manual/
>
> https://developer.solid-run.com/knowledge-base/freebsd/
>
> Given how much information and source SolidRun has provided this might be a very simple build and bootstrap process - I just have no idea where to begin. SolidRun has some documentation on building for their Armada A38x micro-SOMs:
>
> https://developer.solid-run.com/knowledge-base/freebsd/
>
> Unforunately that relies on KERNCONF=ARMADA38X and I think that's going to miss support for all the nicest parts of the Layerscape 2160X.
>

The howto is a bit dated. Since about 2 years, Armada 38x has been
using the GENERIC config for armv7. Anyway it has nothing in common
with the arm64 LS2160X.

Best regards,
Marcin
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

myfreeweb
In reply to this post by Dan Kotowski


On May 14, 2020 3:32:13 PM UTC, Dan Kotowski <[hidden email]> wrote:
>I'm wondering if anybody knows of work being done to port FreeBSD to the Layerscape platforms?
>
>I happen to have a SolidRun HoneyComb LX2K workstation, based on NXP's Layerscape LX2160A, next to my desk running a custom-multistrapped Debian Jessie build, but would love to get FreeBSD running instead. I have only minimal experience working down in BSD driver/kernel land and no experience at all with Crochet, but would like to learn. And while I cannot afford to donate the actual hardware I'm happy to work with others to test builds.

Do not even think about crochet or device trees or any of the embedded stuff on such a machine!! ;)

Just use the latest UEFI firmware in ACPI mode to boot generic FreeBSD.

Looking at their ACPI tables, they do finally have PCIe and USB3 as generic devices, though oddly not SATA: https://github.com/SolidRun/edk2-platforms/tree/master-lx2160a/Silicon/NXP/LX2160A/AcpiTables/Dsdt
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

John-Mark Gurney-2
myfreeweb wrote this message on Thu, May 14, 2020 at 15:48 +0000:

>
>
> On May 14, 2020 3:32:13 PM UTC, Dan Kotowski <[hidden email]> wrote:
> >I'm wondering if anybody knows of work being done to port FreeBSD to the Layerscape platforms?
> >
> >I happen to have a SolidRun HoneyComb LX2K workstation, based on NXP's Layerscape LX2160A, next to my desk running a custom-multistrapped Debian Jessie build, but would love to get FreeBSD running instead. I have only minimal experience working down in BSD driver/kernel land and no experience at all with Crochet, but would like to learn. And while I cannot afford to donate the actual hardware I'm happy to work with others to test builds.
>
> Do not even think about crochet or device trees or any of the embedded stuff on such a machine!! ;)
>
> Just use the latest UEFI firmware in ACPI mode to boot generic FreeBSD.
>
> Looking at their ACPI tables, they do finally have PCIe and USB3 as generic devices, though oddly not SATA: https://github.com/SolidRun/edk2-platforms/tree/master-lx2160a/Silicon/NXP/LX2160A/AcpiTables/Dsdt

If this is the case, then the generic aarch64 images should boot on
it...  Not sure what will happen w/ the SATA though...

--
  John-Mark Gurney Voice: +1 415 225 5579

     "All that I will do, has been done, All that I have, has not."
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

Dan Kotowski
After a solid 16hrs this weekend, I can confirm that the pre-built images do NOT "just work", at least not with SolidRun's HoneyComb version rev 1.4.

The 12.1 arm7 GENERICSD image fails to boot. The included EFI/BOOT/bootarm.efi fails to load. I dropped in a copy of EFI/BOOT/bootarm64.efi from the aarch64  image, but that failed to handoff the process properly. Tested with both u-boot and UEFI.

The 12.1 aarch64 memstick installer iamge fails out trying to mount the UFS partition and drops into the mountroot> shell with error 19. Listing GEOM managed disk devices returned an empty list.

My silicon is rev 1.4 so I have to use the SD slot for the firmware layer, which is a mild inconvenience because I can't use that slot for an OS iamge (https://github.com/SolidRun/lx2160a_build/issues/36#issuecomment-629865674).

Unfortunately that's where I ran out of time. I spent most of the time tracing and tweaking SolidRun's build scripts, testing various combinations of firmware builds and boot images, and learning my way through both the u-boot and UEFI implementations.

Barring other simple ideas, my next step is to make buildworld for TARGET=arm64 TARGET_ARCH=aarch64, drop that on an NVMe gumstick, and see if I can get that booted.

More in the coming days...

Dan Kotowski

‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
On Saturday, May 16, 2020 5:12 AM, John-Mark Gurney <[hidden email]> wrote:

> myfreeweb wrote this message on Thu, May 14, 2020 at 15:48 +0000:
>
> > On May 14, 2020 3:32:13 PM UTC, Dan Kotowski [hidden email] wrote:
> >
> > > I'm wondering if anybody knows of work being done to port FreeBSD to the Layerscape platforms?
> > > I happen to have a SolidRun HoneyComb LX2K workstation, based on NXP's Layerscape LX2160A, next to my desk running a custom-multistrapped Debian Jessie build, but would love to get FreeBSD running instead. I have only minimal experience working down in BSD driver/kernel land and no experience at all with Crochet, but would like to learn. And while I cannot afford to donate the actual hardware I'm happy to work with others to test builds.
> >
> > Do not even think about crochet or device trees or any of the embedded stuff on such a machine!! ;)
> > Just use the latest UEFI firmware in ACPI mode to boot generic FreeBSD.
> > Looking at their ACPI tables, they do finally have PCIe and USB3 as generic devices, though oddly not SATA: https://github.com/SolidRun/edk2-platforms/tree/master-lx2160a/Silicon/NXP/LX2160A/AcpiTables/Dsdt
>
> If this is the case, then the generic aarch64 images should boot on
> it... Not sure what will happen w/ the SATA though...
>
> ----------------------------------------------------------------------------------------------------------------------------
>
> John-Mark Gurney Voice: +1 415 225 5579
>
> "All that I will do, has been done, All that I have, has not."


_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

myfreeweb


On May 18, 2020 1:01:53 PM UTC, Dan Kotowski <[hidden email]> wrote:
>After a solid 16hrs this weekend, I can confirm that the pre-built images do NOT "just work", at least not with SolidRun's HoneyComb version rev 1.4.
>
>The 12.1 arm7 GENERICSD image fails to boot. The included EFI/BOOT/bootarm.efi fails to load. I dropped in a copy of EFI/BOOT/bootarm64.efi from the aarch64  image, but that failed to handoff the process properly. Tested with both u-boot and UEFI.

Why would you even try 32-bit?

>The 12.1 aarch64 memstick installer iamge fails out trying to mount the UFS partition and drops into the mountroot> shell with error 19. Listing GEOM managed disk devices returned an empty list.

What devices does the boot log show? No xhci I guess, how about pci, sdhci?

>My silicon is rev 1.4 so I have to use the SD slot for the firmware layer, which is a mild inconvenience because I can't use that slot for an OS iamge (https://github.com/SolidRun/lx2160a_build/issues/36#issuecomment-629865674).

The comment there says silicon rev 2 starts with board rev 1.5, but linux4kix on Twitter said the 1.4 board is rev 2 silicon!

>Unfortunately that's where I ran out of time. I spent most of the time tracing and tweaking SolidRun's build scripts, testing various combinations of firmware builds and boot images, and learning my way through both the u-boot and UEFI implementations.

Please don't waste time on u-boot.

>Barring other simple ideas, my next step is to make buildworld for TARGET=arm64 TARGET_ARCH=aarch64, drop that on an NVMe gumstick, and see if I can get that booted.

You can just dd the memstick to an nvme or sata drive as well.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

Dan Kotowski
> > After a solid 16hrs this weekend, I can confirm that the pre-built images do NOT "just work", at least not with SolidRun's HoneyComb version rev 1.4.
> > The 12.1 arm7 GENERICSD image fails to boot. The included EFI/BOOT/bootarm.efi fails to load. I dropped in a copy of EFI/BOOT/bootarm64.efi from the aarch64 image, but that failed to handoff the process properly. Tested with both u-boot and UEFI.
>
> Why would you even try 32-bit?

Just throwing spaghetti at the wall to see what would stick.

> > The 12.1 aarch64 memstick installer iamge fails out trying to mount the UFS partition and drops into the mountroot> shell with error 19. Listing GEOM managed disk devices returned an empty list.
>
> What devices does the boot log show? No xhci I guess, how about pci, sdhci?

Does this answer your question? https://gist.github.com/agrajag9/ce1107a1962283b64205bc8f35123a5c

If not, I'll happily run what's needed to get you something better.

> > My silicon is rev 1.4 so I have to use the SD slot for the firmware layer, which is a mild inconvenience because I can't use that slot for an OS iamge (https://github.com/SolidRun/lx2160a_build/issues/36#issuecomment-629865674).
>
> The comment there says silicon rev 2 starts with board rev 1.5, but linux4kix on Twitter said the 1.4 board is rev 2 silicon!

I did flash a known-working firmware build img to the eMMC and set the DIP switches but it did nothing, although I won't rule out Layer 8 failures as I'm still pretty fresh to playing this far down in a system.

> > Unfortunately that's where I ran out of time. I spent most of the time tracing and tweaking SolidRun's build scripts, testing various combinations of firmware builds and boot images, and learning my way through both the u-boot and UEFI implementations.
>
> Please don't waste time on u-boot.

Any particular reason? Most of SolidRun's documentation is based on u-boot, the online documentation from u-boot and the in-console help lines have been much easier to follow, and I'm finding it has a lot more capability to interact with the underlying systems - e.g. reading/writing arbitrary blobs from/to memory/disk.

> > Barring other simple ideas, my next step is to make buildworld for TARGET=arm64 TARGET_ARCH=aarch64, drop that on an NVMe gumstick, and see if I can get that booted.
>
> You can just dd the memstick to an nvme or sata drive as well.

Yep, I have a nice fresh NVMe drive now on the way to play with later this week.

Dan Kotowski
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

myfreeweb


On May 18, 2020 2:34:35 PM UTC, Dan Kotowski <[hidden email]> wrote:
>> > The 12.1 aarch64 memstick installer iamge fails out trying to mount the UFS partition and drops into the mountroot> shell with error 19. Listing GEOM managed disk devices returned an empty list.
>>
>> What devices does the boot log show? No xhci I guess, how about pci, sdhci?
>
>Does this answer your question? https://gist.github.com/agrajag9/ce1107a1962283b64205bc8f35123a5c
>
>If not, I'll happily run what's needed to get you something better.

No, the interesting part is the kernel boot log (dmesg) – the one where you saw the mountroot prompt!

> Load Device: eMMC(0xCA)

huh, wait, where was the memstick image written to again?

>> Please don't waste time on u-boot.
>
>Any particular reason? Most of SolidRun's documentation is based on u-boot, the online documentation from u-boot and the in-console help lines have been much easier to follow, and I'm finding it has a lot more capability to interact with the underlying systems - e.g. reading/writing arbitrary blobs from/to memory/disk.

u-boot does not support ACPI, and only ACPI is appropriate for running non-Linux OSes on this hardware.

Upstream development is focused on EDK2 with ACPI and approaching SBSA compliance. People have managed to run OpenBSD, NetBSD, and Windows.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

Dan Kotowski
> > > > The 12.1 aarch64 memstick installer iamge fails out trying to mount the UFS partition and drops into the mountroot> shell with error 19. Listing GEOM managed disk devices returned an empty list.
> > >
> > > What devices does the boot log show? No xhci I guess, how about pci, sdhci?
> >
> > Does this answer your question? https://gist.github.com/agrajag9/ce1107a1962283b64205bc8f35123a5c
> > If not, I'll happily run what's needed to get you something better.
>
> No, the interesting part is the kernel boot log (dmesg) – the one where you saw the mountroot prompt!

Better? https://gist.github.com/agrajag9/9a69b5baff70c8c1040fabeebd037214

2 files to truncate the >100 empty lines dumped to the console between them.

> > Load Device: eMMC(0xCA)
>
> huh, wait, where was the memstick image written to again?

Artifact of a Layer 8 failure, you can ignore that console output...

> > > Please don't waste time on u-boot.
> >
> > Any particular reason? Most of SolidRun's documentation is based on u-boot, the online documentation from u-boot and the in-console help lines have been much easier to follow, and I'm finding it has a lot more capability to interact with the underlying systems - e.g. reading/writing arbitrary blobs from/to memory/disk.
>
> u-boot does not support ACPI, and only ACPI is appropriate for running non-Linux OSes on this hardware.
>
> Upstream development is focused on EDK2 with ACPI and approaching SBSA compliance. People have managed to run OpenBSD, NetBSD, and Windows.

Noted, I'll stick to UEFI then.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

myfreeweb


On May 18, 2020 3:36:37 PM UTC, Dan Kotowski <[hidden email]> wrote:

>> > > > The 12.1 aarch64 memstick installer iamge fails out trying to mount the UFS partition and drops into the mountroot> shell with error 19. Listing GEOM managed disk devices returned an empty list.
>> > >
>> > > What devices does the boot log show? No xhci I guess, how about pci, sdhci?
>> >
>> > Does this answer your question? https://gist.github.com/agrajag9/ce1107a1962283b64205bc8f35123a5c
>> > If not, I'll happily run what's needed to get you something better.
>>
>> No, the interesting part is the kernel boot log (dmesg) – the one where you saw the mountroot prompt!
>
>Better? https://gist.github.com/agrajag9/9a69b5baff70c8c1040fabeebd037214

Oh, well that explains the lack of devices:

> Using DTB provided by EFI

Try choosing ACPI in the UEFI setup menu if that's available.
And/or setting kern.cfg.order=acpi in the FreeBSD loader menu / /boot/loader.conf
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

Dan Kotowski
> > > > > > The 12.1 aarch64 memstick installer iamge fails out trying to mount the UFS partition and drops into the mountroot> shell with error 19. Listing GEOM managed disk devices returned an empty list.
> > > > >
> > > > > What devices does the boot log show? No xhci I guess, how about pci, sdhci?
> > > >
> > > > Does this answer your question? https://gist.github.com/agrajag9/ce1107a1962283b64205bc8f35123a5c
> > > > If not, I'll happily run what's needed to get you something better.
> > >
> > > No, the interesting part is the kernel boot log (dmesg) – the one where you saw the mountroot prompt!
> >
> > Better? https://gist.github.com/agrajag9/9a69b5baff70c8c1040fabeebd037214
>
> Oh, well that explains the lack of devices:
>
> > Using DTB provided by EFI
>
> Try choosing ACPI in the UEFI setup menu if that's available.
> And/or setting kern.cfg.order=acpi in the FreeBSD loader menu / /boot/loader.conf

I couldn't find any options regarding ACPI in the UEFI menus, so I tried using `set kern.cfg.order=acpi` but that still failed in the same way.

https://gist.github.com/agrajag9/2fa73fc21bff10c9bee9eba810ea283d

I also included the output from running some of the diagnostic UEFI shell commands in case that helps. And I have the compiled DTB on hand if that helps as well.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

myfreeweb
May 18, 2020 7:11 PM, "Dan Kotowski" <[hidden email]> wrote:

>>>>>> The 12.1 aarch64 memstick installer iamge fails out trying to mount the UFS partition and
>> drops into the mountroot> shell with error 19. Listing GEOM managed disk devices returned an empty
>> list.
>>>>>
>>>>> What devices does the boot log show? No xhci I guess, how about pci, sdhci?
>>>>
>>>> Does this answer your question?
>> https://gist.github.com/agrajag9/ce1107a1962283b64205bc8f35123a5c
>>>> If not, I'll happily run what's needed to get you something better.
>>>
>>> No, the interesting part is the kernel boot log (dmesg) – the one where you saw the mountroot
>> prompt!
>>
>> Better? https://gist.github.com/agrajag9/9a69b5baff70c8c1040fabeebd037214
>>
>> Oh, well that explains the lack of devices:
>>
>> Using DTB provided by EFI
>>
>> Try choosing ACPI in the UEFI setup menu if that's available.
>> And/or setting kern.cfg.order=acpi in the FreeBSD loader menu / /boot/loader.conf
>
> I couldn't find any options regarding ACPI in the UEFI menus, so I tried using `set
> kern.cfg.order=acpi` but that still failed in the same way.
>
> https://gist.github.com/agrajag9/2fa73fc21bff10c9bee9eba810ea283d

Same as in it still says "using DTB"?

I wonder if that's the same weirdness I saw on the RPi4,
FreeBSD failing acpi_find_table(ACPI_SIG_SPCR) even though the SPCR table
is present and deciding we don't have ACPI..

You could try my current kernel which has has_acpi hardcoded to true
(extract into the root of the memstick's ufs partition):

https://send.firefox.com/download/c3d69444ce92d3cf/#AuYrYtDvJWNYbEeJWRX4fA
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

Marcin Wojtas
In reply to this post by Dan Kotowski
Hi Dan,

pon., 18 maj 2020 o 18:12 Dan Kotowski
<[hidden email]> napisał(a):

>
> > > > > > > The 12.1 aarch64 memstick installer iamge fails out trying to mount the UFS partition and drops into the mountroot> shell with error 19. Listing GEOM managed disk devices returned an empty list.
> > > > > >
> > > > > > What devices does the boot log show? No xhci I guess, how about pci, sdhci?
> > > > >
> > > > > Does this answer your question? https://gist.github.com/agrajag9/ce1107a1962283b64205bc8f35123a5c
> > > > > If not, I'll happily run what's needed to get you something better.
> > > >
> > > > No, the interesting part is the kernel boot log (dmesg) – the one where you saw the mountroot prompt!
> > >
> > > Better? https://gist.github.com/agrajag9/9a69b5baff70c8c1040fabeebd037214
> >
> > Oh, well that explains the lack of devices:
> >
> > > Using DTB provided by EFI
> >
> > Try choosing ACPI in the UEFI setup menu if that's available.
> > And/or setting kern.cfg.order=acpi in the FreeBSD loader menu / /boot/loader.conf
>
> I couldn't find any options regarding ACPI in the UEFI menus, so I tried using `set kern.cfg.order=acpi` but that still failed in the same way.
>
> https://gist.github.com/agrajag9/2fa73fc21bff10c9bee9eba810ea283d
>
> I also included the output from running some of the diagnostic UEFI shell commands in case that helps. And I have the compiled DTB on hand if that helps as well.
>

Did you try to change the relevant variable (responsible for switching
between ACPI and DT) via BootManager menu?
Device Manager -> O/S Hardware Description Selection -> <Device Tree/ACPI>
(F10 to save and then reset, so that it's taken into account when
loading the ACPI modules modules)?
It should work this way if it's done in a generic way, I haven't
studied SolidRun's edk2-platforms code much yet.
Please let me know if it helped.

Best regards,
Marcin
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

Dan Kotowski
> Hi Dan,
>
> pon., 18 maj 2020 o 18:12 Dan Kotowski
> [hidden email] napisał(a):
>
> > > > > > > > The 12.1 aarch64 memstick installer iamge fails out trying to mount the UFS partition and drops into the mountroot> shell with error 19. Listing GEOM managed disk devices returned an empty list.
> > > > > > >
> > > > > > > What devices does the boot log show? No xhci I guess, how about pci, sdhci?
> > > > > >
> > > > > > Does this answer your question? https://gist.github.com/agrajag9/ce1107a1962283b64205bc8f35123a5c
> > > > > > If not, I'll happily run what's needed to get you something better.
> > > > >
> > > > > No, the interesting part is the kernel boot log (dmesg) – the one where you saw the mountroot prompt!
> > > >
> > > > Better? https://gist.github.com/agrajag9/9a69b5baff70c8c1040fabeebd037214
> > >
> > > Oh, well that explains the lack of devices:
> > >
> > > > Using DTB provided by EFI
> > >
> > > Try choosing ACPI in the UEFI setup menu if that's available.
> > > And/or setting kern.cfg.order=acpi in the FreeBSD loader menu / /boot/loader.conf
> >
> > I couldn't find any options regarding ACPI in the UEFI menus, so I tried using `set kern.cfg.order=acpi` but that still failed in the same way.
> > https://gist.github.com/agrajag9/2fa73fc21bff10c9bee9eba810ea283d
> > I also included the output from running some of the diagnostic UEFI shell commands in case that helps. And I have the compiled DTB on hand if that helps as well.
>
> Did you try to change the relevant variable (responsible for switching
> between ACPI and DT) via BootManager menu?
> Device Manager -> O/S Hardware Description Selection -> <Device Tree/ACPI>
> (F10 to save and then reset, so that it's taken into account when
> loading the ACPI modules modules)?
> It should work this way if it's done in a generic way, I haven't
> studied SolidRun's edk2-platforms code much yet.
> Please let me know if it helped.
>
> Best regards,
> Marcin

Unfortunately there aren't many option in the menu system and I didn't see anything obvious like that. The Device Manager shows an empty Devices List, and the Boot Manager only lets me select FS and BLK devices. The Boot Maintenance Manager menu has sub-menus for Boot Options, Driver Options, Console Options, and Boot From File - but again no mentions of ACPI or DTBs.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

Dan Kotowski
In reply to this post by myfreeweb
> Same as in it still says "using DTB"?
>
> I wonder if that's the same weirdness I saw on the RPi4,
> FreeBSD failing acpi_find_table(ACPI_SIG_SPCR) even though the SPCR table
> is present and deciding we don't have ACPI..
>
> You could try my current kernel which has has_acpi hardcoded to true
> (extract into the root of the memstick's ufs partition):
>
> https://send.firefox.com/download/c3d69444ce92d3cf/#AuYrYtDvJWNYbEeJWRX4fA

Yes, it does still say "using DTB"

Also, your kernel works! Or at least I'm into the installer. It doesn't see the onboard eMMC in the Partition Editor, but once I have the NVMe gumstick in hand I'll pick back this back up.

Is there a reason that we can't use on the DTBs compiled from SolidRun and NXP's sources?
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

myfreeweb
May 18, 2020 10:22 PM, "Dan Kotowski" <[hidden email]> wrote:

>> Same as in it still says "using DTB"?
>>
>> I wonder if that's the same weirdness I saw on the RPi4,
>> FreeBSD failing acpi_find_table(ACPI_SIG_SPCR) even though the SPCR table
>> is present and deciding we don't have ACPI..
>>
>> You could try my current kernel which has has_acpi hardcoded to true
>> (extract into the root of the memstick's ufs partition):
>>
>> https://send.firefox.com/download/c3d69444ce92d3cf/#AuYrYtDvJWNYbEeJWRX4fA
>
> Yes, it does still say "using DTB"
>
> Also, your kernel works! Or at least I'm into the installer. It doesn't see the onboard eMMC in the
> Partition Editor, but once I have the NVMe gumstick in hand I'll pick back this back up.

Cool, please please please post a dmesg to https://dmesgd.nycbug.org :)

Created a bug for the ACPI detection issue:
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=246552

> Is there a reason that we can't use on the DTBs compiled from SolidRun and NXP's sources?

The devicetree uses NXP specific device descriptions (for USB, SATA, PCIe, all the things)
and FreeBSD doesn't understand them.

ACPI tables mostly use generic devices descriptions that all operating systems support
out of the box.

It is technically possible to make a DTB that mostly uses generic nodes and ACPI tables
full of custom vendor nodes, but almost nobody does this.
(Okay, actually, Qualcomm does ACPI with almost all vendor nodes on the Windows aarch64 laptops :D)

Generic descriptions are good. ARM systems that work in the "boring" plug&play way (with standardized
generic devices) are the ideal we all should strive for, so ACPI should always be preferred.
If you're using any DTB on a server/workstation-class system, something has gone wrong :)
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

Dan Kotowski
> Cool, please please please post a dmesg tohttps://dmesgd.nycbug.org :)
>

Done: https://dmesgd.nycbug.org/index.cgi?do=view&id=5490

> Created a bug for the ACPI detection issue:
> https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=246552
>

Thanks! I'll keep my eyes on that as well.

> > Is there a reason that we can't use on the DTBs compiled from SolidRun and NXP's sources?
>
> The devicetree uses NXP specific device descriptions (for USB, SATA, PCIe, all the things)
> and FreeBSD doesn't understand them.
>
> ACPI tables mostly use generic devices descriptions that all operating systems support
> out of the box.
>
> It is technically possible to make a DTB that mostly uses generic nodes and ACPI tables
> full of custom vendor nodes, but almost nobody does this.
> (Okay, actually, Qualcomm does ACPI with almost all vendor nodes on the Windows aarch64 laptops :D)
>
> Generic descriptions are good. ARM systems that work in the "boring" plug&play way (with standardized
> generic devices) are the ideal we all should strive for, so ACPI should always be preferred.
> If you're using any DTB on a server/workstation-class system, something has gone wrong :)

Thanks for the explanataion, it's very helpful.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

myfreeweb
May 18, 2020 11:11 PM, "Dan Kotowski" <[hidden email]> wrote:

>> Cool, please please please post a dmesg tohttps://dmesgd.nycbug.org :)
>
> Done: https://dmesgd.nycbug.org/index.cgi?do=view&id=5490

Huh, it's not working for the reason I thought it would!!

> ofwbus0: <Open Firmware Device Tree>

It is using the DTB (and so you don't see PCIe).

I guess just in -CURRENT there is generic-xhci support in devicetree,
and in whatever kernel you were using there is not.

You still should do kern.cfg.order=acpi, is it on?

btw, one firmware build I found:
https://drive.google.com/file/d/1yXSS1O1U8CmtwaIPfxNDkzhAClJGvErK/view
( from https://dev.to/lizthegrey/first-experiences-with-honeycomb-lx2k-26be )
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

Dan Kotowski
> You still should do kern.cfg.order=acpi, is it on?

Weirdly when I set that it hangs and drops into the mountroot> shell again, while leaving it unset lets me boot into the installer.

https://gist.github.com/agrajag9/171b2665c24baece898ec5ba22439a54

It hangs for about a minute at line 164 after echoing the CPU list, then fails with error 19.

> btw, one firmware build I found:
> https://drive.google.com/file/d/1yXSS1O1U8CmtwaIPfxNDkzhAClJGvErK/view
> ( from https://dev.to/lizthegrey/first-experiences-with-honeycomb-lx2k-26be )

I actually had no problems getting Debian multistrapped, flashed to the eMMC, and booted. Granted FreeBSD and GNU/Linux are wildly different beasts, but I was still surprised.
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: FreeBSD on Layerscape/QorIQ LX2160X

myfreeweb
May 19, 2020 1:29 AM, "Dan Kotowski" <[hidden email]> wrote:

>> You still should do kern.cfg.order=acpi, is it on?
>
> Weirdly when I set that it hangs and drops into the mountroot> shell again, while leaving it unset
> lets me boot into the installer.
>
> https://gist.github.com/agrajag9/171b2665c24baece898ec5ba22439a54

Okay, so now you have PCIe but not USB.

(You're reading the log, right? Not weird to see mountroot if you haven't seen USB in the log.)

Actually SATA is supposed to work too, it's odd that you're not seeing AHCI.
(I was being stupid when I said they have custom SATA, lol)
Also, there's generic PNP0D40 for SDHCI, but we don't recognize that. we should.

Make sure your firmware is up to date, is your edk2-platforms
exactly the same as master-lx2160a branch on github currently?

Specifically make sure these changes are in:

https://github.com/SolidRun/edk2-platforms/commit/97e6b0a36a925f57568d8e411666cfb5034aa38b
https://github.com/SolidRun/edk2-platforms/commit/24698f90b79facfbbfc4067b39a4ddf8c7fdfa88

Test on that linked build if the log was from your build, and vice versa.

Here's a kernel that should also recognize SDHCI (eMMC?),
with the amdgpu driver as a bonus :)
https://send.firefox.com/download/4dd9b553bfe88cb3/#URS-DESsR8WTsiGutrJlRg
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-arm
To unsubscribe, send any mail to "[hidden email]"
1234 ... 6