• Sam Bradshaw's avatar
    mtip32xx: mtip_async_complete() bug fixes · 5eb9291c
    Sam Bradshaw authored
    This patch fixes 2 issues in the fast completion path:
    1) Possible double completions / double dma_unmap_sg() calls due to lack
    of atomicity in the check and subsequent dereference of the upper layer
    callback function. Fixed with cmpxchg before unmap and callback.
    2) Regression in unaligned IO constraining workaround for p420m devices.
    Fixed by checking if IO is unaligned and using proper semaphore if so.
    Signed-off-by: default avatarSam Bradshaw <sbradshaw@micron.com>
    Cc: stable@kernel.org
    Signed-off-by: default avatarJens Axboe <axboe@fb.com>
    5eb9291c
mtip32xx.h 14.1 KB