RE: [PATCH 3/3] iommu/arm-smmu-v3: support suspend/resume
From: Peng Fan
Date: Mon Mar 25 2024 - 21:26:13 EST
> Subject: Re: [PATCH 3/3] iommu/arm-smmu-v3: support suspend/resume
>
> On Mon, Mar 25 2024 at 10:48, Jason Gunthorpe wrote:
> > On Sun, Mar 24, 2024 at 08:29:00PM +0800, Peng Fan (OSS) wrote:
> >> +static void arm_smmu_resume_unique_irqs(struct arm_smmu_device
> >> +*smmu) {
> >> + struct device *dev = smmu->dev;
> >> + struct msi_desc *desc;
> >> + struct msi_msg msg;
> >> +
> >> + if (!dev->msi.domain)
> >> + return;
> >> +
> >> + desc = irq_get_msi_desc(smmu->evtq.q.irq);
> >> + if (desc) {
> >> + get_cached_msi_msg(smmu->evtq.q.irq, &msg);
> >> + arm_smmu_write_msi_msg(desc, &msg);
> >> + }
> >> +
> >> + desc = irq_get_msi_desc(smmu->gerr_irq);
> >> + if (desc) {
> >> + get_cached_msi_msg(smmu->gerr_irq, &msg);
> >> + arm_smmu_write_msi_msg(desc, &msg);
> >> + }
> >> +
> >> + if (smmu->features & ARM_SMMU_FEAT_PRI) {
> >> + desc = irq_get_msi_desc(smmu->priq.q.irq);
> >> + if (desc) {
> >> + get_cached_msi_msg(smmu->priq.q.irq, &msg);
> >> + arm_smmu_write_msi_msg(desc, &msg);
> >> + }
> >> + }
> >> +}
> >
> > I wonder if this should be done instead by converting the driver away
> > from platform MSI to the new MSI mechanism?
>
> There is work in progress for that. Should come around in the next weeks.
Then I need to wait for your patches, and rebase this patchset, or could
the non-msi part be reviewed first?
Thanks,
Peng.