aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/extable.c6
-rw-r--r--lib/smp_processor_id.c4
2 files changed, 6 insertions, 4 deletions
diff --git a/lib/extable.c b/lib/extable.c
index 463f4560f16d..179c08745595 100644
--- a/lib/extable.c
+++ b/lib/extable.c
@@ -57,10 +57,10 @@ search_extable(const struct exception_table_entry *first,
57 while (first <= last) { 57 while (first <= last) {
58 const struct exception_table_entry *mid; 58 const struct exception_table_entry *mid;
59 59
60 mid = (last - first) / 2 + first; 60 mid = ((last - first) >> 1) + first;
61 /* 61 /*
62 * careful, the distance between entries can be 62 * careful, the distance between value and insn
63 * larger than 2GB: 63 * can be larger than MAX_LONG:
64 */ 64 */
65 if (mid->insn < value) 65 if (mid->insn < value)
66 first = mid + 1; 66 first = mid + 1;
diff --git a/lib/smp_processor_id.c b/lib/smp_processor_id.c
index eddc9b3d3876..6c90fb90e19c 100644
--- a/lib/smp_processor_id.c
+++ b/lib/smp_processor_id.c
@@ -42,7 +42,9 @@ unsigned int debug_smp_processor_id(void)
42 if (!printk_ratelimit()) 42 if (!printk_ratelimit())
43 goto out_enable; 43 goto out_enable;
44 44
45 printk(KERN_ERR "BUG: using smp_processor_id() in preemptible [%08x] code: %s/%d\n", preempt_count(), current->comm, current->pid); 45 printk(KERN_ERR "BUG: using smp_processor_id() in preemptible [%08x] "
46 "code: %s/%d\n",
47 preempt_count() - 1, current->comm, current->pid);
46 print_symbol("caller is %s\n", (long)__builtin_return_address(0)); 48 print_symbol("caller is %s\n", (long)__builtin_return_address(0));
47 dump_stack(); 49 dump_stack();
48 50