[SeaBIOS] [PATCH] Remove CanPreempt check from pmm code.
Kevin O'Connor
kevin at koconnor.net
Thu May 31 03:08:33 CEST 2012
The CanPreempt check in pmm is a leftover from when memory could be
allocated from the 9-segment. It is no longer needed.
Signed-off-by: Kevin O'Connor <kevin at koconnor.net>
---
src/pmm.c | 10 ----------
src/util.h | 1 -
2 files changed, 0 insertions(+), 11 deletions(-)
diff --git a/src/pmm.c b/src/pmm.c
index 4cee401..5d43645 100644
--- a/src/pmm.c
+++ b/src/pmm.c
@@ -537,13 +537,6 @@ handle_pmm(u16 *args)
u16 arg1 = args[0];
dprintf(DEBUG_HDL_pmm, "pmm call arg1=%x\n", arg1);
- int oldpreempt;
- if (CONFIG_THREAD_OPTIONROMS) {
- // Not a preemption event - don't wait in wait_preempt()
- oldpreempt = CanPreempt;
- CanPreempt = 0;
- }
-
u32 ret;
switch (arg1) {
case 0x00: ret = handle_pmm00(args); break;
@@ -552,9 +545,6 @@ handle_pmm(u16 *args)
default: ret = handle_pmmXX(args); break;
}
- if (CONFIG_THREAD_OPTIONROMS)
- CanPreempt = oldpreempt;
-
return ret;
}
diff --git a/src/util.h b/src/util.h
index 0d41785..e5d494e 100644
--- a/src/util.h
+++ b/src/util.h
@@ -225,7 +225,6 @@ void wait_threads(void);
struct mutex_s { u32 isLocked; };
void mutex_lock(struct mutex_s *mutex);
void mutex_unlock(struct mutex_s *mutex);
-extern int CanPreempt;
void start_preempt(void);
void finish_preempt(void);
int wait_preempt(void);
--
1.7.6.5
More information about the SeaBIOS
mailing list