Messages in this thread | | | Date | Mon, 3 Apr 2023 21:03:28 -0700 | From | Dan Williams <> | Subject | RE: [PATCH v4 2/5] perf: Allow a PMU to have a parent |
| |
Jonathan Cameron wrote: > Some PMUs have well defined parents such as PCI devices. > As the device_initialize() and device_add() are all within > pmu_dev_alloc() which is called from perf_pmu_register() > there is no opportunity to set the parent from within a driver. > > Add a struct device *parent field to struct pmu and use that > to set the parent. > > Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> > --- > v4: No change > Note that this may first merge as part of a larger series I > plan to post next week that adds parents for many of the of the > other struct pmu instances. If so please drop this patch whilst > applying.
Feel free to add my:
Reviewed-by: Dan Williams <dan.j.williams@intel.com>
...whereever this gets applied, and yes it makes sense especially as more device attached PMUs are showing up.
| |