What to do with dtsi files that come from Sysconfig?

I’ve been reading both generic websites and the various posts here (FAQ about device tree) and some threads, with the most useful one seeming to be Overlays: BeagleBone AI-64 [PWM] .

However I couldn’t find a straight-forward how-to of exactly what to do and the steps to do them when it comes to incorporating a dtsi file I get from TI Sysconfig. There’s lots of scattered information you can piece together, but I didn’t find a single location that walks you through step-by-step. So I thought maybe there would be benefit in starting a thread explicitly targeting that use-case. However if there is a doc/thread somewhere that does, please link to it.

I would fill in the details I’ve learned so far, but I’m not confident on anything I know (or rather think I know) right now. So here’s yet-another device-tree thread.

So just to give the thread some context, what I’m working on requires a fair number of pins on the P8 and P9 headers be muxed to work with ICSSG0_PRU0/1 on my BBAI64.

I’ve identified which header-pins map to which physical pins on the chip using the BBAI64’s hardware doc (I used the PDF).

Then I used TI’s SysConfig to identify which of these physical pins map to which PRUs.

This allowed me to pin-select the pins that worked best once I knew the endpoints of all available pins on the headers that also can be routed to PRUs. Sysconfig also allowed me to configure whether the pins are to be outputs or inputs. And for the inputs, whether the pin is to be internally pulled up, pulled down, or float (each of my pins have different needs so this was relevant).

Once I got a configuration that worked well for me, I exported all that from SysConfig into all the file-formats it allowed (at the time, I didn’t know which I’d want to use). With a bit more understanding, I realize what I want is to perform a device-tree overlay of this configuration ontop of the existing BBAI64 device-tree. And Sysconfig supplied me with the dtsi overlay (include) file to do just that.

So, at this point, what do I do with that file? It’s an include-file so I assume it is either already named something that will overwrite an existing file on the BBAI64? Or I’ll need to modify an existing file to include my file.

Once I’ve done whatever the correct thing to do is from the above paragraph, then I assume I need to run a make command to remake my device tree with my custom overlay configuration. Where do I do that and what target do I pass into make (if any)?

Any other steps necessary at this point?

And just so I understand the order at which things will be done, when will the dtb be processed? Is it one of the early tasks of Linux? Or does Uboot actually process the dtb before launching Linux? I’ve never been quite clear on that. Last time I looked at this on the AM335x (BBB’s processor), it seemed as if all Uboot did was load the dtb into RAM for Linux to process. But I can’t remember if its a coordinated location it gets put or if the address Uboot selected was passed to the Linux kernel as an arg. Or if I’m just completely wrong on that detail.

For anybody else that finds this topic title interesting and also has the same questions, refer to this topic as it has some pretty good info about how to deal with device tree changes, specifically as it relates to PRUs, but I believe the instructions and principles are universal as they relate to device tree mods:
AI64 - PRU Basics (very)