]> git.baikalelectronics.ru Git - kernel.git/commit
ioat: close potential BUG_ON race in the descriptor cleanup path
authorDan Williams <dan.j.williams@intel.com>
Thu, 4 Mar 2010 04:21:10 +0000 (21:21 -0700)
committerDan Williams <dan.j.williams@intel.com>
Thu, 4 Mar 2010 04:21:10 +0000 (21:21 -0700)
commit3d82ebae640a8592c8993cda93eddb73f742e373
tree3e7fbb0ef4415c9f36107a81378f00bba6db9440
parenta7bae4d4912f8bc0b2bcd18dee5c16044130a9cf
ioat: close potential BUG_ON race in the descriptor cleanup path

Since ioat_cleanup_preamble() and the update of the last completed
descriptor are not synchronized there is a chance that two cleanup threads
can see descriptors to clean.  If the first cleans up all pending
descriptors then the second will trigger the BUG_ON.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
drivers/dma/ioat/dma_v2.c
drivers/dma/ioat/dma_v3.c