summaryrefslogtreecommitdiff
path: root/lib_ppc/extable.c
diff options
context:
space:
mode:
authorStefan Roese <sr@denx.de>2007-04-23 15:38:17 +0200
committerStefan Roese <sr@denx.de>2007-04-23 15:38:17 +0200
commit6554ca06a8bee4317df7543f694dc39a9288ba14 (patch)
tree1ba21faad3123fd7e3c3c4cc980beac40181fa97 /lib_ppc/extable.c
parent38257988abfe74d459ca2ad748b109ca04e4efe1 (diff)
parent14da5f7675bbb427c469e3f45006e027b6e21db9 (diff)
Merge with git://www.denx.de/git/u-boot.git
Diffstat (limited to 'lib_ppc/extable.c')
-rw-r--r--lib_ppc/extable.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/lib_ppc/extable.c b/lib_ppc/extable.c
index fe856ffbb5..b14d661bbe 100644
--- a/lib_ppc/extable.c
+++ b/lib_ppc/extable.c
@@ -57,25 +57,25 @@ search_one_table(const struct exception_table_entry *first,
long diff;
mid = (last - first) / 2 + first;
- if (mid > CFG_MONITOR_BASE) {
- /* exception occurs in FLASH, before u-boot relocation.
- * No relocation offset is needed.
- */
+ if ((ulong) mid > CFG_MONITOR_BASE) {
+ /* exception occurs in FLASH, before u-boot relocation.
+ * No relocation offset is needed.
+ */
diff = mid->insn - value;
if (diff == 0)
return mid->fixup;
} else {
- /* exception occurs in RAM, after u-boot relocation.
- * A relocation offset should be added.
- */
+ /* exception occurs in RAM, after u-boot relocation.
+ * A relocation offset should be added.
+ */
diff = (mid->insn + gd->reloc_off) - value;
if (diff == 0)
return (mid->fixup + gd->reloc_off);
}
if (diff < 0)
- first = mid+1;
+ first = mid + 1;
else
- last = mid-1;
+ last = mid - 1;
}
return 0;
}