Re: git: f9bdaab95ec4 - main - ofwbus: remove handling of resources from ofwbus
- In reply to: John Baldwin : "Re: git: f9bdaab95ec4 - main - ofwbus: remove handling of resources from ofwbus"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 10 Feb 2023 15:28:09 UTC
On 2/9/23 13:42, John Baldwin wrote: > On 2/8/23 12:52 PM, Mitchell Horne wrote: >> The branch main has been updated by mhorne: >> >> URL: >> https://cgit.FreeBSD.org/src/commit/?id=f9bdaab95ec469738fbfc1f0edd3e8c744b7f71f >> >> commit f9bdaab95ec469738fbfc1f0edd3e8c744b7f71f >> Author: Elliott Mitchell <ehem+freebsd@m5p.com> >> AuthorDate: 2023-02-08 20:17:03 +0000 >> Commit: Mitchell Horne <mhorne@FreeBSD.org> >> CommitDate: 2023-02-08 20:50:46 +0000 >> >> ofwbus: remove handling of resources from ofwbus >> The architecture nexus should handle allocation and release of >> memory and >> interrupts. This is to ensure that system-wide resources such as >> these >> are available to all devices, not just children of ofwbus0. >> On powerpc this moves the ownership of these resources up one level, >> from ofwbus0 to nexus0. Other architectures already have the >> required >> logic in their nexus implementation, so this eliminates the >> duplication >> of resources. An implementation of nexus_adjust_resource() is >> added for >> arm, arm64, and riscv. >> As noted by ian@ in the review, resource handling was the main >> bit of >> logic distinguishing ofwbus from simplebus. With some attention to >> detail, it should be possible to merge the two in the future. >> Co-authored by: mhorne >> MFC after: 1 month >> Differential Revision: https://reviews.freebsd.org/D30554 > > Thanks! I actually had an earlier version of this but hadn't managed to > get it > tested on powerpc. I had it as part of a branch to cleanup > bus_activate_resource > methods across various architectures whcih I will now rebase and try to > finish > up. > > If you are curious: > https://github.com/freebsd/freebsd-src/compare/main...bsdjhb:freebsd:bus_map_resource_more > Hey, very nice. I definitely saw a lot of cleanup potential and it seems like your branch does a lot in that respect. I have a couple of follow-ups in the area, so I will get those up into phab shortly. Mitchell