[PATCH] ppc32: Kill embedded system.map, use kallsyms
[linux-3.10.git] / arch / ppc64 / xmon / xmon.c
index 3c0ccb2623aeba4e89e9b43c439bf0c4ceafe1cd..7f6e13a4b71eec0c23330aaca24dcc76aa6a5971 100644 (file)
@@ -2247,7 +2247,14 @@ scanhex(unsigned long *vp)
                        tmpstr[i] = c;
                }
                tmpstr[i++] = 0;
-               *vp = kallsyms_lookup_name(tmpstr);
+               *vp = 0;
+               if (setjmp(bus_error_jmp) == 0) {
+                       catch_memory_errors = 1;
+                       sync();
+                       *vp = kallsyms_lookup_name(tmpstr);
+                       sync();
+               }
+               catch_memory_errors = 0;
                if (!(*vp)) {
                        printf("unknown symbol '%s'\n", tmpstr);
                        return 0;