Re: [PATCH] iommu/amd: Fix amd_iommu_free_device()

From: Jesse Barnes
Date: Tue Feb 03 2015 - 12:04:18 EST


On Tue, 3 Feb 2015 13:25:51 +0100
Peter Zijlstra <peterz@xxxxxxxxxxxxx> wrote:

> On Tue, Feb 03, 2015 at 12:27:33PM +0100, Peter Zijlstra wrote:
> > drivers/iommu/amd_iommu_v2.c-static void
> > put_device_state_wait(struct device_state *dev_state)
> > drivers/iommu/amd_iommu_v2.c-{ drivers/iommu/amd_iommu_v2.c-
> > DEFINE_WAIT(wait); drivers/iommu/amd_iommu_v2.c-
> > drivers/iommu/amd_iommu_v2.c- prepare_to_wait(&dev_state->wq,
> > &wait, TASK_UNINTERRUPTIBLE); drivers/iommu/amd_iommu_v2.c- if
> > (!atomic_dec_and_test(&dev_state->count))
> > drivers/iommu/amd_iommu_v2.c: schedule();
> > drivers/iommu/amd_iommu_v2.c- finish_wait(&dev_state->wq, &wait);
> > drivers/iommu/amd_iommu_v2.c- drivers/iommu/amd_iommu_v2.c-
> > free_device_state(dev_state); drivers/iommu/amd_iommu_v2.c-}
> >
> > No loop...
>
> Jesse, any objections to this?

None from me, seems reasonable. But this is Joerg's code I think, so
he should ack.

Jesse
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/