|
@@ -4853,7 +4853,7 @@ static void add_xhlock(struct held_lock *hlock)
|
|
|
|
|
|
/* Initialize hist_lock's members */
|
|
|
xhlock->hlock = *hlock;
|
|
|
- xhlock->hist_id = current->hist_id++;
|
|
|
+ xhlock->hist_id = ++current->hist_id;
|
|
|
|
|
|
xhlock->trace.nr_entries = 0;
|
|
|
xhlock->trace.max_entries = MAX_XHLOCK_TRACE_ENTRIES;
|
|
@@ -5029,12 +5029,12 @@ static void commit_xhlocks(struct cross_lock *xlock)
|
|
|
break;
|
|
|
|
|
|
/*
|
|
|
- * Filter out the cases that the ring buffer was
|
|
|
- * overwritten and the previous entry has a bigger
|
|
|
- * hist_id than the following one, which is impossible
|
|
|
- * otherwise.
|
|
|
+ * Filter out the cases where the ring buffer was
|
|
|
+ * overwritten and the current entry has a bigger
|
|
|
+ * hist_id than the previous one, which is impossible
|
|
|
+ * otherwise:
|
|
|
*/
|
|
|
- if (unlikely(before(xhlock->hist_id, prev_hist_id)))
|
|
|
+ if (unlikely(before(prev_hist_id, xhlock->hist_id)))
|
|
|
break;
|
|
|
|
|
|
prev_hist_id = xhlock->hist_id;
|