use tree allocator
This commit is contained in:
@ -16,4 +16,5 @@ CGA_Stream kout; // Ausgabe-Strom fuer Kernel
|
||||
Keyboard kb; // Tastatur
|
||||
unsigned int total_mem; // RAM total
|
||||
// BumpAllocator allocator;
|
||||
LinkedListAllocator allocator;
|
||||
// LinkedListAllocator allocator;
|
||||
TreeAllocator allocator;
|
||||
|
||||
@ -15,6 +15,7 @@
|
||||
#include "devices/PCSPK.h"
|
||||
#include "kernel/allocator/BumpAllocator.h"
|
||||
#include "kernel/allocator/LinkedListAllocator.h"
|
||||
#include "kernel/allocator/TreeAllocator.h"
|
||||
#include "kernel/CPU.h"
|
||||
|
||||
extern CPU cpu; // CPU-spezifische Funktionen
|
||||
@ -23,6 +24,7 @@ extern CGA_Stream kout; // Ausgabe-Strom fuer Kernel
|
||||
extern Keyboard kb; // Tastatur
|
||||
extern unsigned int total_mem; // RAM total
|
||||
// extern BumpAllocator allocator;
|
||||
extern LinkedListAllocator allocator;
|
||||
// extern LinkedListAllocator allocator;
|
||||
extern TreeAllocator allocator;
|
||||
|
||||
#endif
|
||||
|
||||
@ -24,10 +24,12 @@ void scroll_mode() {
|
||||
|
||||
switch ((char)key) {
|
||||
case 'k':
|
||||
kout.show(kout.COLUMNS - 1, 0, (char)(48 + kout.scroll_page_backward()));
|
||||
kout.scroll_page_backward();
|
||||
kout.show(kout.COLUMNS - 1, 0, (char)(48 + kout.current_page));
|
||||
break;
|
||||
case 'j':
|
||||
kout.show(kout.COLUMNS - 1, 0, (char)(48 + kout.scroll_page_forward()));
|
||||
kout.scroll_page_forward();
|
||||
kout.show(kout.COLUMNS - 1, 0, (char)(48 + kout.current_page));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user