summaryrefslogtreecommitdiff
path: root/kern
diff options
context:
space:
mode:
authorGuillem Jover <guillem@debian.org>2009-12-09 02:30:53 +0100
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2012-03-20 02:12:41 +0100
commitba54d8a07b20916b84df1d8159fb0b50f8f692b8 (patch)
treee0f32816f251bf659bfdf8ff706681b1a39f29df /kern
parent735cf19fdebf4a3df886426a51cad78b7ef025f2 (diff)
Use compiler defined __i386__ symbol instead of use defined i386
* i386/configfrag.ac (i386): Remove definition. * i386/intel/pmap.c (pmap_update_interrupt): Rename i386 to __i386__. * i386/intel/pmap.h: Likewise. * kern/debug.c (Debugger): Likewise. * kern/lock.c (simple_lock, simple_lock_try, db_show_all_slocks): Likewise.
Diffstat (limited to 'kern')
-rw-r--r--kern/debug.c2
-rw-r--r--kern/lock.c10
2 files changed, 6 insertions, 6 deletions
diff --git a/kern/debug.c b/kern/debug.c
index 26445f8..65c43fb 100644
--- a/kern/debug.c
+++ b/kern/debug.c
@@ -100,7 +100,7 @@ void SoftDebugger(message)
gimmeabreak();
#endif
-#ifdef i386
+#if defined(__i386__)
asm("int3");
#endif
}
diff --git a/kern/lock.c b/kern/lock.c
index 0c61227..2bcfa8b 100644
--- a/kern/lock.c
+++ b/kern/lock.c
@@ -162,9 +162,9 @@ void simple_lock(
info = &simple_locks_info[simple_locks_taken++];
info->l = l;
/* XXX we want our return address, if possible */
-#ifdef i386
+#if defined(__i386__)
info->ra = *((unsigned int *)&l - 1);
-#endif /* i386 */
+#endif /* __i386__ */
}
boolean_t simple_lock_try(
@@ -180,9 +180,9 @@ boolean_t simple_lock_try(
info = &simple_locks_info[simple_locks_taken++];
info->l = l;
/* XXX we want our return address, if possible */
-#ifdef i386
+#if defined(__i386__)
info->ra = *((unsigned int *)&l - 1);
-#endif /* i386 */
+#endif /* __i386__ */
return TRUE;
}
@@ -622,7 +622,7 @@ void db_show_all_slocks(void)
info = &simple_locks_info[i];
db_printf("%d: ", i);
db_printsym(info->l, DB_STGY_ANY);
-#if i386
+#if defined(__i386__)
db_printf(" locked by ");
db_printsym(info->ra, DB_STGY_PROC);
#endif