Support for PocketBeagle?

Hi, I am wondering if anyone has taken a look at building support for the Pocket Beagle. I built an image for Beagle Bone Black and it works fine in a BBB, but when I try booting it in a Pocket Beagle, it dies somewhere in u-boot, something to do with a timer: "Could not initialize timer".

When I inquired in the #beagle channel, I got the following reply from zmatt:

my first guess would be that it's related to the pocketbeagle not having a 32768 Hz crystal
so possibly some clock source is being configured incorrectly for this board
on the pocketbeagle the rtc osc must be disabled (RTC_OSC_REG.OSC32K_GZ = 1) and must not be selected as clock source for the rtc (RTC_OSC_REG.SEL_32KCLK_SRC != 1), timer1 (CLKSEL_TIMER1MS_CLK.CLKSEL != 4), gpio0 debounce (CLKSEL_GPIO0_DBCLK.CLKSEL != 1), or clkout2 (CM_CLKOUT_CTRL.CLKOUT2SOURCE != 0)
it should be noted that all of these are power-on defaults, so if they're wrong then it's because u-boot configured them wrong
the internal 32768 clock source (which is the main alternative to the rtc osc clock) is generated by dividing down the 192 MHz PER_CLKOUTM2, so PLL_PER needs to be correctly initialized and locked to have it available

If this is uboot related, you should probably ask the question(s) at uboot, not here.

If clocks are set properly, either by hardware or bootloader, then the board should be able to boot kernel by setting clk_ignore_unused in kernel command line (Documentation/admin-guide/kernel-parameters.txt in kernel tree). But if You are using U-Boot for Beagle Bone Black, very likely clocks are not set properly, like said on IRC. Since there are other omap boards already supported, it would be faster to add definition for Pocket Beagle than trying to boot image for other board.

u-boot built by debian seems to work for either (i can swap their beaglebone image uSD card between BBB and pocketbeagle successfully). So I am just trying to sort out what OpenWrt is doing with its u-boot that's different.

OpenWrt does vanilla U-Boot for omap target (https://git.openwrt.org/?p=openwrt/openwrt.git;a=tree;f=package/boot/uboot-omap), check if Debian does something different. Maybe only version differs.

According to the documentation of the PocketBeagle it's using an Octavo Systems OSD3358 SoC, not the TI AM335x found on the BeagleBone Black.

This difference is more than enough to cause boot failures.

You did read the linked page with Octavo SoC, did You? That Octavo SoC is actually a System-in-Package which integrates exactly the same components (the actual RAM chip may differ) as on BeagleBone Black (https://docs.beagleboard.org/latest/boards/pocketbeagle/original/ch04.html#pocketbeagle-features-and-specification), and very likely they are wired similar.