mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-04-01 03:54:02 +00:00
Merge git://git.kvack.org/~bcrl/aio-fixes
Pull aio nested sleep annotation from Ben LaHaise, * git://git.kvack.org/~bcrl/aio-fixes: aio: annotate aio_read_event_ring for sleep patterns
This commit is contained in:
commit
cdecbb336e
1 changed files with 7 additions and 0 deletions
7
fs/aio.c
7
fs/aio.c
|
@ -1140,6 +1140,13 @@ static long aio_read_events_ring(struct kioctx *ctx,
|
||||||
long ret = 0;
|
long ret = 0;
|
||||||
int copy_ret;
|
int copy_ret;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* The mutex can block and wake us up and that will cause
|
||||||
|
* wait_event_interruptible_hrtimeout() to schedule without sleeping
|
||||||
|
* and repeat. This should be rare enough that it doesn't cause
|
||||||
|
* peformance issues. See the comment in read_events() for more detail.
|
||||||
|
*/
|
||||||
|
sched_annotate_sleep();
|
||||||
mutex_lock(&ctx->ring_lock);
|
mutex_lock(&ctx->ring_lock);
|
||||||
|
|
||||||
/* Access to ->ring_pages here is protected by ctx->ring_lock. */
|
/* Access to ->ring_pages here is protected by ctx->ring_lock. */
|
||||||
|
|
Loading…
Add table
Reference in a new issue