aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/lockdep_proc.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/lockdep_proc.c')
-rw-r--r--kernel/lockdep_proc.c25
1 files changed, 7 insertions, 18 deletions
diff --git a/kernel/lockdep_proc.c b/kernel/lockdep_proc.c
index 59b76c8ce9d7..71edd2f60c02 100644
--- a/kernel/lockdep_proc.c
+++ b/kernel/lockdep_proc.c
@@ -225,7 +225,7 @@ static int lockdep_stats_show(struct seq_file *m, void *v)
225 nr_irq_read_safe = 0, nr_irq_read_unsafe = 0, 225 nr_irq_read_safe = 0, nr_irq_read_unsafe = 0,
226 nr_softirq_read_safe = 0, nr_softirq_read_unsafe = 0, 226 nr_softirq_read_safe = 0, nr_softirq_read_unsafe = 0,
227 nr_hardirq_read_safe = 0, nr_hardirq_read_unsafe = 0, 227 nr_hardirq_read_safe = 0, nr_hardirq_read_unsafe = 0,
228 sum_forward_deps = 0, factor = 0; 228 sum_forward_deps = 0;
229 229
230 list_for_each_entry(class, &all_lock_classes, lock_entry) { 230 list_for_each_entry(class, &all_lock_classes, lock_entry) {
231 231
@@ -283,13 +283,6 @@ static int lockdep_stats_show(struct seq_file *m, void *v)
283 nr_hardirq_unsafe * nr_hardirq_safe + 283 nr_hardirq_unsafe * nr_hardirq_safe +
284 nr_list_entries); 284 nr_list_entries);
285 285
286 /*
287 * Estimated factor between direct and indirect
288 * dependencies:
289 */
290 if (nr_list_entries)
291 factor = sum_forward_deps / nr_list_entries;
292
293#ifdef CONFIG_PROVE_LOCKING 286#ifdef CONFIG_PROVE_LOCKING
294 seq_printf(m, " dependency chains: %11lu [max: %lu]\n", 287 seq_printf(m, " dependency chains: %11lu [max: %lu]\n",
295 nr_lock_chains, MAX_LOCKDEP_CHAINS); 288 nr_lock_chains, MAX_LOCKDEP_CHAINS);
@@ -494,7 +487,6 @@ static void seq_stats(struct seq_file *m, struct lock_stat_data *data)
494 namelen += 2; 487 namelen += 2;
495 488
496 for (i = 0; i < LOCKSTAT_POINTS; i++) { 489 for (i = 0; i < LOCKSTAT_POINTS; i++) {
497 char sym[KSYM_SYMBOL_LEN];
498 char ip[32]; 490 char ip[32];
499 491
500 if (class->contention_point[i] == 0) 492 if (class->contention_point[i] == 0)
@@ -503,15 +495,13 @@ static void seq_stats(struct seq_file *m, struct lock_stat_data *data)
503 if (!i) 495 if (!i)
504 seq_line(m, '-', 40-namelen, namelen); 496 seq_line(m, '-', 40-namelen, namelen);
505 497
506 sprint_symbol(sym, class->contention_point[i]);
507 snprintf(ip, sizeof(ip), "[<%p>]", 498 snprintf(ip, sizeof(ip), "[<%p>]",
508 (void *)class->contention_point[i]); 499 (void *)class->contention_point[i]);
509 seq_printf(m, "%40s %14lu %29s %s\n", name, 500 seq_printf(m, "%40s %14lu %29s %pS\n",
510 stats->contention_point[i], 501 name, stats->contention_point[i],
511 ip, sym); 502 ip, (void *)class->contention_point[i]);
512 } 503 }
513 for (i = 0; i < LOCKSTAT_POINTS; i++) { 504 for (i = 0; i < LOCKSTAT_POINTS; i++) {
514 char sym[KSYM_SYMBOL_LEN];
515 char ip[32]; 505 char ip[32];
516 506
517 if (class->contending_point[i] == 0) 507 if (class->contending_point[i] == 0)
@@ -520,12 +510,11 @@ static void seq_stats(struct seq_file *m, struct lock_stat_data *data)
520 if (!i) 510 if (!i)
521 seq_line(m, '-', 40-namelen, namelen); 511 seq_line(m, '-', 40-namelen, namelen);
522 512
523 sprint_symbol(sym, class->contending_point[i]);
524 snprintf(ip, sizeof(ip), "[<%p>]", 513 snprintf(ip, sizeof(ip), "[<%p>]",
525 (void *)class->contending_point[i]); 514 (void *)class->contending_point[i]);
526 seq_printf(m, "%40s %14lu %29s %s\n", name, 515 seq_printf(m, "%40s %14lu %29s %pS\n",
527 stats->contending_point[i], 516 name, stats->contending_point[i],
528 ip, sym); 517 ip, (void *)class->contending_point[i]);
529 } 518 }
530 if (i) { 519 if (i) {
531 seq_puts(m, "\n"); 520 seq_puts(m, "\n");