Re: [PATCH] iommu/amd: Fix bug in put_pasid_state_wait

From: Joerg Roedel
Date: Mon May 04 2015 - 07:22:06 EST


On Thu, Apr 16, 2015 at 05:08:44PM +0300, Oded Gabbay wrote:
> This patch fixes a bug in put_pasid_state_wait that appeared in kernel 4.0
> The bug is that pasid_state->count wasn't decremented before entering the
> wait_event. Thus, the condition in wait_event will never be true.
>
> The fix is to decrement (atomically) the pasid_state->count before the
> wait_event.

Gah! This issue was already pointed out in the original review of the
patch, looks like I applied the wrong version. Thanks for the fix, I
applied it to iommu/fixes.


Joerg

--
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/