On 11 July 2017 at 21:42, Philippe Mathieu-Daudé <f4...@amsat.org> wrote: > Hi Peter, > > There is probably no need yet, but we could model a generic APB slave with > this code, as an overlapping subregion (device top 0x30 bytes). > > For now only PID0 differs, but since all ID are 8bit the device could even > instantiate the subregion with some u64 PID, 32 CID args. > > (thinking about watchdog and dualtimers).
If you look at the pl* primecell devices you'll see that's not historically how we've done them. I think it would be more code in each device to instantiate a generic device to handle the ID register section and a container to put it in than just to deal with the IDs by hand... thanks -- PMM