X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=lib%2Fextable.c;h=179c0874559569bf2626cbfc70bfcfef09474097;hb=108c1961847df2a875047c0fd27b419cb817d213;hp=01c08b5836f5e8441920df88df4efc9859776efe;hpb=88e3c1da8b3258a81c5c81d4e7e22557b7d71ba7;p=linux-2.6 diff --git a/lib/extable.c b/lib/extable.c index 01c08b5836..179c087455 100644 --- a/lib/extable.c +++ b/lib/extable.c @@ -9,7 +9,6 @@ * 2 of the License, or (at your option) any later version. */ -#include #include #include #include @@ -58,10 +57,10 @@ search_extable(const struct exception_table_entry *first, while (first <= last) { const struct exception_table_entry *mid; - mid = (last - first) / 2 + first; + mid = ((last - first) >> 1) + first; /* - * careful, the distance between entries can be - * larger than 2GB: + * careful, the distance between value and insn + * can be larger than MAX_LONG: */ if (mid->insn < value) first = mid + 1;