aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPeter Zijlstra <a.p.zijlstra@chello.nl>2009-01-22 07:10:52 -0500
committerIngo Molnar <mingo@elte.hu>2009-02-14 17:27:51 -0500
commit4fc95e867f1e75351b89db3c68212dfcce7ea563 (patch)
tree618b2ed01d87a871f8423dd230bdb3609aa7c7f0
parentcf40bd16fdad42c053040bcd3988f5fdedbb6c57 (diff)
lockdep: sanitize bit names
s/\(LOCKF\?_ENABLED_[^ ]*\)S\(_READ\)\?\>/\1\2/g So that the USED_IN and ENABLED have the same names. Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Signed-off-by: Ingo Molnar <mingo@elte.hu>
-rw-r--r--include/linux/lockdep.h22
-rw-r--r--kernel/lockdep.c84
-rw-r--r--kernel/lockdep_proc.c12
3 files changed, 59 insertions, 59 deletions
diff --git a/include/linux/lockdep.h b/include/linux/lockdep.h
index cc97bdbc7969..da2e2b25b3b2 100644
--- a/include/linux/lockdep.h
+++ b/include/linux/lockdep.h
@@ -28,14 +28,14 @@ enum lock_usage_bit
28 LOCK_USED_IN_HARDIRQ, 28 LOCK_USED_IN_HARDIRQ,
29 LOCK_USED_IN_SOFTIRQ, 29 LOCK_USED_IN_SOFTIRQ,
30 LOCK_USED_IN_RECLAIM_FS, 30 LOCK_USED_IN_RECLAIM_FS,
31 LOCK_ENABLED_SOFTIRQS, 31 LOCK_ENABLED_SOFTIRQ,
32 LOCK_ENABLED_HARDIRQS, 32 LOCK_ENABLED_HARDIRQ,
33 LOCK_HELD_OVER_RECLAIM_FS, 33 LOCK_HELD_OVER_RECLAIM_FS,
34 LOCK_USED_IN_HARDIRQ_READ, 34 LOCK_USED_IN_HARDIRQ_READ,
35 LOCK_USED_IN_SOFTIRQ_READ, 35 LOCK_USED_IN_SOFTIRQ_READ,
36 LOCK_USED_IN_RECLAIM_FS_READ, 36 LOCK_USED_IN_RECLAIM_FS_READ,
37 LOCK_ENABLED_SOFTIRQS_READ, 37 LOCK_ENABLED_SOFTIRQ_READ,
38 LOCK_ENABLED_HARDIRQS_READ, 38 LOCK_ENABLED_HARDIRQ_READ,
39 LOCK_HELD_OVER_RECLAIM_FS_READ, 39 LOCK_HELD_OVER_RECLAIM_FS_READ,
40 LOCK_USAGE_STATES 40 LOCK_USAGE_STATES
41}; 41};
@@ -47,22 +47,22 @@ enum lock_usage_bit
47#define LOCKF_USED_IN_HARDIRQ (1 << LOCK_USED_IN_HARDIRQ) 47#define LOCKF_USED_IN_HARDIRQ (1 << LOCK_USED_IN_HARDIRQ)
48#define LOCKF_USED_IN_SOFTIRQ (1 << LOCK_USED_IN_SOFTIRQ) 48#define LOCKF_USED_IN_SOFTIRQ (1 << LOCK_USED_IN_SOFTIRQ)
49#define LOCKF_USED_IN_RECLAIM_FS (1 << LOCK_USED_IN_RECLAIM_FS) 49#define LOCKF_USED_IN_RECLAIM_FS (1 << LOCK_USED_IN_RECLAIM_FS)
50#define LOCKF_ENABLED_HARDIRQS (1 << LOCK_ENABLED_HARDIRQS) 50#define LOCKF_ENABLED_HARDIRQ (1 << LOCK_ENABLED_HARDIRQ)
51#define LOCKF_ENABLED_SOFTIRQS (1 << LOCK_ENABLED_SOFTIRQS) 51#define LOCKF_ENABLED_SOFTIRQ (1 << LOCK_ENABLED_SOFTIRQ)
52#define LOCKF_HELD_OVER_RECLAIM_FS (1 << LOCK_HELD_OVER_RECLAIM_FS) 52#define LOCKF_HELD_OVER_RECLAIM_FS (1 << LOCK_HELD_OVER_RECLAIM_FS)
53 53
54#define LOCKF_ENABLED_IRQS (LOCKF_ENABLED_HARDIRQS | LOCKF_ENABLED_SOFTIRQS) 54#define LOCKF_ENABLED_IRQ (LOCKF_ENABLED_HARDIRQ | LOCKF_ENABLED_SOFTIRQ)
55#define LOCKF_USED_IN_IRQ (LOCKF_USED_IN_HARDIRQ | LOCKF_USED_IN_SOFTIRQ) 55#define LOCKF_USED_IN_IRQ (LOCKF_USED_IN_HARDIRQ | LOCKF_USED_IN_SOFTIRQ)
56 56
57#define LOCKF_USED_IN_HARDIRQ_READ (1 << LOCK_USED_IN_HARDIRQ_READ) 57#define LOCKF_USED_IN_HARDIRQ_READ (1 << LOCK_USED_IN_HARDIRQ_READ)
58#define LOCKF_USED_IN_SOFTIRQ_READ (1 << LOCK_USED_IN_SOFTIRQ_READ) 58#define LOCKF_USED_IN_SOFTIRQ_READ (1 << LOCK_USED_IN_SOFTIRQ_READ)
59#define LOCKF_USED_IN_RECLAIM_FS_READ (1 << LOCK_USED_IN_RECLAIM_FS_READ) 59#define LOCKF_USED_IN_RECLAIM_FS_READ (1 << LOCK_USED_IN_RECLAIM_FS_READ)
60#define LOCKF_ENABLED_HARDIRQS_READ (1 << LOCK_ENABLED_HARDIRQS_READ) 60#define LOCKF_ENABLED_HARDIRQ_READ (1 << LOCK_ENABLED_HARDIRQ_READ)
61#define LOCKF_ENABLED_SOFTIRQS_READ (1 << LOCK_ENABLED_SOFTIRQS_READ) 61#define LOCKF_ENABLED_SOFTIRQ_READ (1 << LOCK_ENABLED_SOFTIRQ_READ)
62#define LOCKF_HELD_OVER_RECLAIM_FS_READ (1 << LOCK_HELD_OVER_RECLAIM_FS_READ) 62#define LOCKF_HELD_OVER_RECLAIM_FS_READ (1 << LOCK_HELD_OVER_RECLAIM_FS_READ)
63 63
64#define LOCKF_ENABLED_IRQS_READ \ 64#define LOCKF_ENABLED_IRQ_READ \
65 (LOCKF_ENABLED_HARDIRQS_READ | LOCKF_ENABLED_SOFTIRQS_READ) 65 (LOCKF_ENABLED_HARDIRQ_READ | LOCKF_ENABLED_SOFTIRQ_READ)
66#define LOCKF_USED_IN_IRQ_READ \ 66#define LOCKF_USED_IN_IRQ_READ \
67 (LOCKF_USED_IN_HARDIRQ_READ | LOCKF_USED_IN_SOFTIRQ_READ) 67 (LOCKF_USED_IN_HARDIRQ_READ | LOCKF_USED_IN_SOFTIRQ_READ)
68 68
diff --git a/kernel/lockdep.c b/kernel/lockdep.c
index 977f940fd562..32f944752b18 100644
--- a/kernel/lockdep.c
+++ b/kernel/lockdep.c
@@ -450,12 +450,12 @@ static const char *usage_str[] =
450 [LOCK_USED] = "initial-use ", 450 [LOCK_USED] = "initial-use ",
451 [LOCK_USED_IN_HARDIRQ] = "in-hardirq-W", 451 [LOCK_USED_IN_HARDIRQ] = "in-hardirq-W",
452 [LOCK_USED_IN_SOFTIRQ] = "in-softirq-W", 452 [LOCK_USED_IN_SOFTIRQ] = "in-softirq-W",
453 [LOCK_ENABLED_SOFTIRQS] = "softirq-on-W", 453 [LOCK_ENABLED_SOFTIRQ] = "softirq-on-W",
454 [LOCK_ENABLED_HARDIRQS] = "hardirq-on-W", 454 [LOCK_ENABLED_HARDIRQ] = "hardirq-on-W",
455 [LOCK_USED_IN_HARDIRQ_READ] = "in-hardirq-R", 455 [LOCK_USED_IN_HARDIRQ_READ] = "in-hardirq-R",
456 [LOCK_USED_IN_SOFTIRQ_READ] = "in-softirq-R", 456 [LOCK_USED_IN_SOFTIRQ_READ] = "in-softirq-R",
457 [LOCK_ENABLED_SOFTIRQS_READ] = "softirq-on-R", 457 [LOCK_ENABLED_SOFTIRQ_READ] = "softirq-on-R",
458 [LOCK_ENABLED_HARDIRQS_READ] = "hardirq-on-R", 458 [LOCK_ENABLED_HARDIRQ_READ] = "hardirq-on-R",
459 [LOCK_USED_IN_RECLAIM_FS] = "in-reclaim-W", 459 [LOCK_USED_IN_RECLAIM_FS] = "in-reclaim-W",
460 [LOCK_USED_IN_RECLAIM_FS_READ] = "in-reclaim-R", 460 [LOCK_USED_IN_RECLAIM_FS_READ] = "in-reclaim-R",
461 [LOCK_HELD_OVER_RECLAIM_FS] = "ov-reclaim-W", 461 [LOCK_HELD_OVER_RECLAIM_FS] = "ov-reclaim-W",
@@ -476,28 +476,28 @@ get_usage_chars(struct lock_class *class, char *c1, char *c2, char *c3,
476 if (class->usage_mask & LOCKF_USED_IN_HARDIRQ) 476 if (class->usage_mask & LOCKF_USED_IN_HARDIRQ)
477 *c1 = '+'; 477 *c1 = '+';
478 else 478 else
479 if (class->usage_mask & LOCKF_ENABLED_HARDIRQS) 479 if (class->usage_mask & LOCKF_ENABLED_HARDIRQ)
480 *c1 = '-'; 480 *c1 = '-';
481 481
482 if (class->usage_mask & LOCKF_USED_IN_SOFTIRQ) 482 if (class->usage_mask & LOCKF_USED_IN_SOFTIRQ)
483 *c2 = '+'; 483 *c2 = '+';
484 else 484 else
485 if (class->usage_mask & LOCKF_ENABLED_SOFTIRQS) 485 if (class->usage_mask & LOCKF_ENABLED_SOFTIRQ)
486 *c2 = '-'; 486 *c2 = '-';
487 487
488 if (class->usage_mask & LOCKF_ENABLED_HARDIRQS_READ) 488 if (class->usage_mask & LOCKF_ENABLED_HARDIRQ_READ)
489 *c3 = '-'; 489 *c3 = '-';
490 if (class->usage_mask & LOCKF_USED_IN_HARDIRQ_READ) { 490 if (class->usage_mask & LOCKF_USED_IN_HARDIRQ_READ) {
491 *c3 = '+'; 491 *c3 = '+';
492 if (class->usage_mask & LOCKF_ENABLED_HARDIRQS_READ) 492 if (class->usage_mask & LOCKF_ENABLED_HARDIRQ_READ)
493 *c3 = '?'; 493 *c3 = '?';
494 } 494 }
495 495
496 if (class->usage_mask & LOCKF_ENABLED_SOFTIRQS_READ) 496 if (class->usage_mask & LOCKF_ENABLED_SOFTIRQ_READ)
497 *c4 = '-'; 497 *c4 = '-';
498 if (class->usage_mask & LOCKF_USED_IN_SOFTIRQ_READ) { 498 if (class->usage_mask & LOCKF_USED_IN_SOFTIRQ_READ) {
499 *c4 = '+'; 499 *c4 = '+';
500 if (class->usage_mask & LOCKF_ENABLED_SOFTIRQS_READ) 500 if (class->usage_mask & LOCKF_ENABLED_SOFTIRQ_READ)
501 *c4 = '?'; 501 *c4 = '?';
502 } 502 }
503 503
@@ -1296,7 +1296,7 @@ check_prev_add_irq(struct task_struct *curr, struct held_lock *prev,
1296 * forwards-subgraph starting at <next>: 1296 * forwards-subgraph starting at <next>:
1297 */ 1297 */
1298 if (!check_usage(curr, prev, next, LOCK_USED_IN_HARDIRQ, 1298 if (!check_usage(curr, prev, next, LOCK_USED_IN_HARDIRQ,
1299 LOCK_ENABLED_HARDIRQS, "hard")) 1299 LOCK_ENABLED_HARDIRQ, "hard"))
1300 return 0; 1300 return 0;
1301 1301
1302 /* 1302 /*
@@ -1306,7 +1306,7 @@ check_prev_add_irq(struct task_struct *curr, struct held_lock *prev,
1306 * forwards-subgraph starting at <next>: 1306 * forwards-subgraph starting at <next>:
1307 */ 1307 */
1308 if (!check_usage(curr, prev, next, LOCK_USED_IN_HARDIRQ_READ, 1308 if (!check_usage(curr, prev, next, LOCK_USED_IN_HARDIRQ_READ,
1309 LOCK_ENABLED_HARDIRQS, "hard-read")) 1309 LOCK_ENABLED_HARDIRQ, "hard-read"))
1310 return 0; 1310 return 0;
1311 1311
1312 /* 1312 /*
@@ -1316,7 +1316,7 @@ check_prev_add_irq(struct task_struct *curr, struct held_lock *prev,
1316 * forwards-subgraph starting at <next>: 1316 * forwards-subgraph starting at <next>:
1317 */ 1317 */
1318 if (!check_usage(curr, prev, next, LOCK_USED_IN_SOFTIRQ, 1318 if (!check_usage(curr, prev, next, LOCK_USED_IN_SOFTIRQ,
1319 LOCK_ENABLED_SOFTIRQS, "soft")) 1319 LOCK_ENABLED_SOFTIRQ, "soft"))
1320 return 0; 1320 return 0;
1321 /* 1321 /*
1322 * Prove that the new dependency does not connect a softirq-safe-read 1322 * Prove that the new dependency does not connect a softirq-safe-read
@@ -1325,7 +1325,7 @@ check_prev_add_irq(struct task_struct *curr, struct held_lock *prev,
1325 * forwards-subgraph starting at <next>: 1325 * forwards-subgraph starting at <next>:
1326 */ 1326 */
1327 if (!check_usage(curr, prev, next, LOCK_USED_IN_SOFTIRQ_READ, 1327 if (!check_usage(curr, prev, next, LOCK_USED_IN_SOFTIRQ_READ,
1328 LOCK_ENABLED_SOFTIRQS, "soft")) 1328 LOCK_ENABLED_SOFTIRQ, "soft"))
1329 return 0; 1329 return 0;
1330 1330
1331 /* 1331 /*
@@ -2008,17 +2008,17 @@ static int mark_lock_irq(struct task_struct *curr, struct held_lock *this,
2008 2008
2009 switch(new_bit) { 2009 switch(new_bit) {
2010 case LOCK_USED_IN_HARDIRQ: 2010 case LOCK_USED_IN_HARDIRQ:
2011 if (!valid_state(curr, this, new_bit, LOCK_ENABLED_HARDIRQS)) 2011 if (!valid_state(curr, this, new_bit, LOCK_ENABLED_HARDIRQ))
2012 return 0; 2012 return 0;
2013 if (!valid_state(curr, this, new_bit, 2013 if (!valid_state(curr, this, new_bit,
2014 LOCK_ENABLED_HARDIRQS_READ)) 2014 LOCK_ENABLED_HARDIRQ_READ))
2015 return 0; 2015 return 0;
2016 /* 2016 /*
2017 * just marked it hardirq-safe, check that this lock 2017 * just marked it hardirq-safe, check that this lock
2018 * took no hardirq-unsafe lock in the past: 2018 * took no hardirq-unsafe lock in the past:
2019 */ 2019 */
2020 if (!check_usage_forwards(curr, this, 2020 if (!check_usage_forwards(curr, this,
2021 LOCK_ENABLED_HARDIRQS, "hard")) 2021 LOCK_ENABLED_HARDIRQ, "hard"))
2022 return 0; 2022 return 0;
2023#if STRICT_READ_CHECKS 2023#if STRICT_READ_CHECKS
2024 /* 2024 /*
@@ -2026,24 +2026,24 @@ static int mark_lock_irq(struct task_struct *curr, struct held_lock *this,
2026 * took no hardirq-unsafe-read lock in the past: 2026 * took no hardirq-unsafe-read lock in the past:
2027 */ 2027 */
2028 if (!check_usage_forwards(curr, this, 2028 if (!check_usage_forwards(curr, this,
2029 LOCK_ENABLED_HARDIRQS_READ, "hard-read")) 2029 LOCK_ENABLED_HARDIRQ_READ, "hard-read"))
2030 return 0; 2030 return 0;
2031#endif 2031#endif
2032 if (hardirq_verbose(hlock_class(this))) 2032 if (hardirq_verbose(hlock_class(this)))
2033 ret = 2; 2033 ret = 2;
2034 break; 2034 break;
2035 case LOCK_USED_IN_SOFTIRQ: 2035 case LOCK_USED_IN_SOFTIRQ:
2036 if (!valid_state(curr, this, new_bit, LOCK_ENABLED_SOFTIRQS)) 2036 if (!valid_state(curr, this, new_bit, LOCK_ENABLED_SOFTIRQ))
2037 return 0; 2037 return 0;
2038 if (!valid_state(curr, this, new_bit, 2038 if (!valid_state(curr, this, new_bit,
2039 LOCK_ENABLED_SOFTIRQS_READ)) 2039 LOCK_ENABLED_SOFTIRQ_READ))
2040 return 0; 2040 return 0;
2041 /* 2041 /*
2042 * just marked it softirq-safe, check that this lock 2042 * just marked it softirq-safe, check that this lock
2043 * took no softirq-unsafe lock in the past: 2043 * took no softirq-unsafe lock in the past:
2044 */ 2044 */
2045 if (!check_usage_forwards(curr, this, 2045 if (!check_usage_forwards(curr, this,
2046 LOCK_ENABLED_SOFTIRQS, "soft")) 2046 LOCK_ENABLED_SOFTIRQ, "soft"))
2047 return 0; 2047 return 0;
2048#if STRICT_READ_CHECKS 2048#if STRICT_READ_CHECKS
2049 /* 2049 /*
@@ -2051,7 +2051,7 @@ static int mark_lock_irq(struct task_struct *curr, struct held_lock *this,
2051 * took no softirq-unsafe-read lock in the past: 2051 * took no softirq-unsafe-read lock in the past:
2052 */ 2052 */
2053 if (!check_usage_forwards(curr, this, 2053 if (!check_usage_forwards(curr, this,
2054 LOCK_ENABLED_SOFTIRQS_READ, "soft-read")) 2054 LOCK_ENABLED_SOFTIRQ_READ, "soft-read"))
2055 return 0; 2055 return 0;
2056#endif 2056#endif
2057 if (softirq_verbose(hlock_class(this))) 2057 if (softirq_verbose(hlock_class(this)))
@@ -2083,27 +2083,27 @@ static int mark_lock_irq(struct task_struct *curr, struct held_lock *this,
2083 ret = 2; 2083 ret = 2;
2084 break; 2084 break;
2085 case LOCK_USED_IN_HARDIRQ_READ: 2085 case LOCK_USED_IN_HARDIRQ_READ:
2086 if (!valid_state(curr, this, new_bit, LOCK_ENABLED_HARDIRQS)) 2086 if (!valid_state(curr, this, new_bit, LOCK_ENABLED_HARDIRQ))
2087 return 0; 2087 return 0;
2088 /* 2088 /*
2089 * just marked it hardirq-read-safe, check that this lock 2089 * just marked it hardirq-read-safe, check that this lock
2090 * took no hardirq-unsafe lock in the past: 2090 * took no hardirq-unsafe lock in the past:
2091 */ 2091 */
2092 if (!check_usage_forwards(curr, this, 2092 if (!check_usage_forwards(curr, this,
2093 LOCK_ENABLED_HARDIRQS, "hard")) 2093 LOCK_ENABLED_HARDIRQ, "hard"))
2094 return 0; 2094 return 0;
2095 if (hardirq_verbose(hlock_class(this))) 2095 if (hardirq_verbose(hlock_class(this)))
2096 ret = 2; 2096 ret = 2;
2097 break; 2097 break;
2098 case LOCK_USED_IN_SOFTIRQ_READ: 2098 case LOCK_USED_IN_SOFTIRQ_READ:
2099 if (!valid_state(curr, this, new_bit, LOCK_ENABLED_SOFTIRQS)) 2099 if (!valid_state(curr, this, new_bit, LOCK_ENABLED_SOFTIRQ))
2100 return 0; 2100 return 0;
2101 /* 2101 /*
2102 * just marked it softirq-read-safe, check that this lock 2102 * just marked it softirq-read-safe, check that this lock
2103 * took no softirq-unsafe lock in the past: 2103 * took no softirq-unsafe lock in the past:
2104 */ 2104 */
2105 if (!check_usage_forwards(curr, this, 2105 if (!check_usage_forwards(curr, this,
2106 LOCK_ENABLED_SOFTIRQS, "soft")) 2106 LOCK_ENABLED_SOFTIRQ, "soft"))
2107 return 0; 2107 return 0;
2108 if (softirq_verbose(hlock_class(this))) 2108 if (softirq_verbose(hlock_class(this)))
2109 ret = 2; 2109 ret = 2;
@@ -2121,7 +2121,7 @@ static int mark_lock_irq(struct task_struct *curr, struct held_lock *this,
2121 if (reclaim_verbose(hlock_class(this))) 2121 if (reclaim_verbose(hlock_class(this)))
2122 ret = 2; 2122 ret = 2;
2123 break; 2123 break;
2124 case LOCK_ENABLED_HARDIRQS: 2124 case LOCK_ENABLED_HARDIRQ:
2125 if (!valid_state(curr, this, new_bit, LOCK_USED_IN_HARDIRQ)) 2125 if (!valid_state(curr, this, new_bit, LOCK_USED_IN_HARDIRQ))
2126 return 0; 2126 return 0;
2127 if (!valid_state(curr, this, new_bit, 2127 if (!valid_state(curr, this, new_bit,
@@ -2147,7 +2147,7 @@ static int mark_lock_irq(struct task_struct *curr, struct held_lock *this,
2147 if (hardirq_verbose(hlock_class(this))) 2147 if (hardirq_verbose(hlock_class(this)))
2148 ret = 2; 2148 ret = 2;
2149 break; 2149 break;
2150 case LOCK_ENABLED_SOFTIRQS: 2150 case LOCK_ENABLED_SOFTIRQ:
2151 if (!valid_state(curr, this, new_bit, LOCK_USED_IN_SOFTIRQ)) 2151 if (!valid_state(curr, this, new_bit, LOCK_USED_IN_SOFTIRQ))
2152 return 0; 2152 return 0;
2153 if (!valid_state(curr, this, new_bit, 2153 if (!valid_state(curr, this, new_bit,
@@ -2199,7 +2199,7 @@ static int mark_lock_irq(struct task_struct *curr, struct held_lock *this,
2199 if (reclaim_verbose(hlock_class(this))) 2199 if (reclaim_verbose(hlock_class(this)))
2200 ret = 2; 2200 ret = 2;
2201 break; 2201 break;
2202 case LOCK_ENABLED_HARDIRQS_READ: 2202 case LOCK_ENABLED_HARDIRQ_READ:
2203 if (!valid_state(curr, this, new_bit, LOCK_USED_IN_HARDIRQ)) 2203 if (!valid_state(curr, this, new_bit, LOCK_USED_IN_HARDIRQ))
2204 return 0; 2204 return 0;
2205#if STRICT_READ_CHECKS 2205#if STRICT_READ_CHECKS
@@ -2214,7 +2214,7 @@ static int mark_lock_irq(struct task_struct *curr, struct held_lock *this,
2214 if (hardirq_verbose(hlock_class(this))) 2214 if (hardirq_verbose(hlock_class(this)))
2215 ret = 2; 2215 ret = 2;
2216 break; 2216 break;
2217 case LOCK_ENABLED_SOFTIRQS_READ: 2217 case LOCK_ENABLED_SOFTIRQ_READ:
2218 if (!valid_state(curr, this, new_bit, LOCK_USED_IN_SOFTIRQ)) 2218 if (!valid_state(curr, this, new_bit, LOCK_USED_IN_SOFTIRQ))
2219 return 0; 2219 return 0;
2220#if STRICT_READ_CHECKS 2220#if STRICT_READ_CHECKS
@@ -2274,16 +2274,16 @@ mark_held_locks(struct task_struct *curr, enum mark_type mark)
2274 switch (mark) { 2274 switch (mark) {
2275 case HARDIRQ: 2275 case HARDIRQ:
2276 if (hlock->read) 2276 if (hlock->read)
2277 usage_bit = LOCK_ENABLED_HARDIRQS_READ; 2277 usage_bit = LOCK_ENABLED_HARDIRQ_READ;
2278 else 2278 else
2279 usage_bit = LOCK_ENABLED_HARDIRQS; 2279 usage_bit = LOCK_ENABLED_HARDIRQ;
2280 break; 2280 break;
2281 2281
2282 case SOFTIRQ: 2282 case SOFTIRQ:
2283 if (hlock->read) 2283 if (hlock->read)
2284 usage_bit = LOCK_ENABLED_SOFTIRQS_READ; 2284 usage_bit = LOCK_ENABLED_SOFTIRQ_READ;
2285 else 2285 else
2286 usage_bit = LOCK_ENABLED_SOFTIRQS; 2286 usage_bit = LOCK_ENABLED_SOFTIRQ;
2287 break; 2287 break;
2288 2288
2289 case RECLAIM_FS: 2289 case RECLAIM_FS:
@@ -2520,19 +2520,19 @@ static int mark_irqflags(struct task_struct *curr, struct held_lock *hlock)
2520 if (!hlock->hardirqs_off) { 2520 if (!hlock->hardirqs_off) {
2521 if (hlock->read) { 2521 if (hlock->read) {
2522 if (!mark_lock(curr, hlock, 2522 if (!mark_lock(curr, hlock,
2523 LOCK_ENABLED_HARDIRQS_READ)) 2523 LOCK_ENABLED_HARDIRQ_READ))
2524 return 0; 2524 return 0;
2525 if (curr->softirqs_enabled) 2525 if (curr->softirqs_enabled)
2526 if (!mark_lock(curr, hlock, 2526 if (!mark_lock(curr, hlock,
2527 LOCK_ENABLED_SOFTIRQS_READ)) 2527 LOCK_ENABLED_SOFTIRQ_READ))
2528 return 0; 2528 return 0;
2529 } else { 2529 } else {
2530 if (!mark_lock(curr, hlock, 2530 if (!mark_lock(curr, hlock,
2531 LOCK_ENABLED_HARDIRQS)) 2531 LOCK_ENABLED_HARDIRQ))
2532 return 0; 2532 return 0;
2533 if (curr->softirqs_enabled) 2533 if (curr->softirqs_enabled)
2534 if (!mark_lock(curr, hlock, 2534 if (!mark_lock(curr, hlock,
2535 LOCK_ENABLED_SOFTIRQS)) 2535 LOCK_ENABLED_SOFTIRQ))
2536 return 0; 2536 return 0;
2537 } 2537 }
2538 } 2538 }
@@ -2640,10 +2640,10 @@ static int mark_lock(struct task_struct *curr, struct held_lock *this,
2640 case LOCK_USED_IN_SOFTIRQ: 2640 case LOCK_USED_IN_SOFTIRQ:
2641 case LOCK_USED_IN_HARDIRQ_READ: 2641 case LOCK_USED_IN_HARDIRQ_READ:
2642 case LOCK_USED_IN_SOFTIRQ_READ: 2642 case LOCK_USED_IN_SOFTIRQ_READ:
2643 case LOCK_ENABLED_HARDIRQS: 2643 case LOCK_ENABLED_HARDIRQ:
2644 case LOCK_ENABLED_SOFTIRQS: 2644 case LOCK_ENABLED_SOFTIRQ:
2645 case LOCK_ENABLED_HARDIRQS_READ: 2645 case LOCK_ENABLED_HARDIRQ_READ:
2646 case LOCK_ENABLED_SOFTIRQS_READ: 2646 case LOCK_ENABLED_SOFTIRQ_READ:
2647 case LOCK_USED_IN_RECLAIM_FS: 2647 case LOCK_USED_IN_RECLAIM_FS:
2648 case LOCK_USED_IN_RECLAIM_FS_READ: 2648 case LOCK_USED_IN_RECLAIM_FS_READ:
2649 case LOCK_HELD_OVER_RECLAIM_FS: 2649 case LOCK_HELD_OVER_RECLAIM_FS:
diff --git a/kernel/lockdep_proc.c b/kernel/lockdep_proc.c
index b84a1dfa9077..bd474fd9df9d 100644
--- a/kernel/lockdep_proc.c
+++ b/kernel/lockdep_proc.c
@@ -300,27 +300,27 @@ static int lockdep_stats_show(struct seq_file *m, void *v)
300 nr_uncategorized++; 300 nr_uncategorized++;
301 if (class->usage_mask & LOCKF_USED_IN_IRQ) 301 if (class->usage_mask & LOCKF_USED_IN_IRQ)
302 nr_irq_safe++; 302 nr_irq_safe++;
303 if (class->usage_mask & LOCKF_ENABLED_IRQS) 303 if (class->usage_mask & LOCKF_ENABLED_IRQ)
304 nr_irq_unsafe++; 304 nr_irq_unsafe++;
305 if (class->usage_mask & LOCKF_USED_IN_SOFTIRQ) 305 if (class->usage_mask & LOCKF_USED_IN_SOFTIRQ)
306 nr_softirq_safe++; 306 nr_softirq_safe++;
307 if (class->usage_mask & LOCKF_ENABLED_SOFTIRQS) 307 if (class->usage_mask & LOCKF_ENABLED_SOFTIRQ)
308 nr_softirq_unsafe++; 308 nr_softirq_unsafe++;
309 if (class->usage_mask & LOCKF_USED_IN_HARDIRQ) 309 if (class->usage_mask & LOCKF_USED_IN_HARDIRQ)
310 nr_hardirq_safe++; 310 nr_hardirq_safe++;
311 if (class->usage_mask & LOCKF_ENABLED_HARDIRQS) 311 if (class->usage_mask & LOCKF_ENABLED_HARDIRQ)
312 nr_hardirq_unsafe++; 312 nr_hardirq_unsafe++;
313 if (class->usage_mask & LOCKF_USED_IN_IRQ_READ) 313 if (class->usage_mask & LOCKF_USED_IN_IRQ_READ)
314 nr_irq_read_safe++; 314 nr_irq_read_safe++;
315 if (class->usage_mask & LOCKF_ENABLED_IRQS_READ) 315 if (class->usage_mask & LOCKF_ENABLED_IRQ_READ)
316 nr_irq_read_unsafe++; 316 nr_irq_read_unsafe++;
317 if (class->usage_mask & LOCKF_USED_IN_SOFTIRQ_READ) 317 if (class->usage_mask & LOCKF_USED_IN_SOFTIRQ_READ)
318 nr_softirq_read_safe++; 318 nr_softirq_read_safe++;
319 if (class->usage_mask & LOCKF_ENABLED_SOFTIRQS_READ) 319 if (class->usage_mask & LOCKF_ENABLED_SOFTIRQ_READ)
320 nr_softirq_read_unsafe++; 320 nr_softirq_read_unsafe++;
321 if (class->usage_mask & LOCKF_USED_IN_HARDIRQ_READ) 321 if (class->usage_mask & LOCKF_USED_IN_HARDIRQ_READ)
322 nr_hardirq_read_safe++; 322 nr_hardirq_read_safe++;
323 if (class->usage_mask & LOCKF_ENABLED_HARDIRQS_READ) 323 if (class->usage_mask & LOCKF_ENABLED_HARDIRQ_READ)
324 nr_hardirq_read_unsafe++; 324 nr_hardirq_read_unsafe++;
325 325
326#ifdef CONFIG_PROVE_LOCKING 326#ifdef CONFIG_PROVE_LOCKING