No functional change.
Unified · Split
| @@ -951,6 +951,10 @@ __mutex_lock_common(struct mutex *lock, unsigned int state, unsigned int subclas · 950 unmodified lines | ||
| 951 | 951 | */ |
| 952 | 952 | if (ww_ctx->acquired == 0) |
| 953 | 953 | ww_ctx->wounded = 0; |
| 954 | + | |
| 955 | +#ifdef CONFIG_DEBUG_LOCK_ALLOC | |
| 956 | + nest_lock = &ww_ctx->dep_map; | |
| 957 | +#endif | |
| 954 | 958 | } |
| 955 | 959 | |
| 956 | 960 | preempt_disable(); |
| @@ -1098,10 +1102,9 @@ __mutex_lock(struct mutex *lock, unsigned int state, unsigned int subclass, · 141 unmodified lines | ||
| 1098 | 1102 | |
| 1099 | 1103 | static int __sched |
| 1100 | 1104 | __ww_mutex_lock(struct mutex *lock, unsigned int state, unsigned int subclass, |
| 1101 | − struct lockdep_map *nest_lock, unsigned long ip, | |
| 1102 | − struct ww_acquire_ctx *ww_ctx) | |
| 1105 | + unsigned long ip, struct ww_acquire_ctx *ww_ctx) | |
| 1103 | 1106 | { |
| 1104 | − return __mutex_lock_common(lock, state, subclass, nest_lock, ip, ww_ctx, true); | |
| 1107 | + return __mutex_lock_common(lock, state, subclass, NULL, ip, ww_ctx, true); | |
| 1105 | 1108 | } |
| 1106 | 1109 | |
| 1107 | 1110 | #ifdef CONFIG_DEBUG_LOCK_ALLOC |
| @@ -1181,8 +1184,7 @@ ww_mutex_lock(struct ww_mutex *lock, struct ww_acquire_ctx *ctx) · 73 unmodified lines | ||
| 1181 | 1184 | |
| 1182 | 1185 | might_sleep(); |
| 1183 | 1186 | ret = __ww_mutex_lock(&lock->base, TASK_UNINTERRUPTIBLE, |
| 1184 | − 0, ctx ? &ctx->dep_map : NULL, _RET_IP_, | |
| 1185 | − ctx); | |
| 1187 | + 0, _RET_IP_, ctx); | |
| 1186 | 1188 | if (!ret && ctx && ctx->acquired > 1) |
| 1187 | 1189 | return ww_mutex_deadlock_injection(lock, ctx); |
| 1188 | 1190 | |
| @@ -1197,8 +1199,7 @@ ww_mutex_lock_interruptible(struct ww_mutex *lock, struct ww_acquire_ctx *ctx) · 8 unmodified lines | ||
| 1197 | 1199 | |
| 1198 | 1200 | might_sleep(); |
| 1199 | 1201 | ret = __ww_mutex_lock(&lock->base, TASK_INTERRUPTIBLE, |
| 1200 | − 0, ctx ? &ctx->dep_map : NULL, _RET_IP_, | |
| 1201 | − ctx); | |
| 1202 | + 0, _RET_IP_, ctx); | |
| 1202 | 1203 | |
| 1203 | 1204 | if (!ret && ctx && ctx->acquired > 1) |
| 1204 | 1205 | return ww_mutex_deadlock_injection(lock, ctx); |
| @@ -1364,7 +1365,7 @@ __mutex_lock_interruptible_slowpath(struct mutex *lock) · 159 unmodified lines | ||
| 1364 | 1365 | static noinline int __sched |
| 1365 | 1366 | __ww_mutex_lock_slowpath(struct ww_mutex *lock, struct ww_acquire_ctx *ctx) |
| 1366 | 1367 | { |
| 1367 | − return __ww_mutex_lock(&lock->base, TASK_UNINTERRUPTIBLE, 0, NULL, | |
| 1368 | + return __ww_mutex_lock(&lock->base, TASK_UNINTERRUPTIBLE, 0, | |
| 1368 | 1369 | _RET_IP_, ctx); |
| 1369 | 1370 | } |
| 1370 | 1371 | |
| @@ -1372,7 +1373,7 @@ static noinline int __sched · 1 unmodified line | ||
| 1372 | 1373 | __ww_mutex_lock_interruptible_slowpath(struct ww_mutex *lock, |
| 1373 | 1374 | struct ww_acquire_ctx *ctx) |
| 1374 | 1375 | { |
| 1375 | − return __ww_mutex_lock(&lock->base, TASK_INTERRUPTIBLE, 0, NULL, | |
| 1376 | + return __ww_mutex_lock(&lock->base, TASK_INTERRUPTIBLE, 0, | |
| 1376 | 1377 | _RET_IP_, ctx); |
| 1377 | 1378 | } |
| 1378 | 1379 | |