Import backup from 2003-11-03
This commit is contained in:
parent
ba97e8a7f0
commit
57980293e6
@ -107,6 +107,13 @@ inline void init_timer()
|
|||||||
outportb(0x40, 0x2e); //msb
|
outportb(0x40, 0x2e); //msb
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//Invalidates the page tables to re-cache the Translation Lookaside Buffer
|
||||||
|
/*inline void invlpg()
|
||||||
|
{
|
||||||
|
asm("invlpg");
|
||||||
|
}*/
|
||||||
|
|
||||||
//Signals an End Of Interrupt signal to the first PIC
|
//Signals an End Of Interrupt signal to the first PIC
|
||||||
inline void eoi()
|
inline void eoi()
|
||||||
{
|
{
|
||||||
|
@ -21,6 +21,8 @@ inline void eoi();
|
|||||||
inline void eoi2();
|
inline void eoi2();
|
||||||
inline dword kernel_size();
|
inline dword kernel_size();
|
||||||
inline void init_timer();
|
inline void init_timer();
|
||||||
|
//inline void invlpg();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
4
kernel.c
4
kernel.c
@ -45,8 +45,8 @@ void k_init()
|
|||||||
console_cls();
|
console_cls();
|
||||||
remap_pics(0x20, 0x28);
|
remap_pics(0x20, 0x28);
|
||||||
init_timer();
|
init_timer();
|
||||||
video_init((ModeInfoBlock *) 0x90306);
|
|
||||||
mm_init();
|
mm_init();
|
||||||
|
video_init((ModeInfoBlock *) 0x90306);
|
||||||
vmm_init();
|
vmm_init();
|
||||||
mouse_init();
|
mouse_init();
|
||||||
vmm_enable_paging();
|
vmm_enable_paging();
|
||||||
@ -74,7 +74,7 @@ void isr(dword num)
|
|||||||
{
|
{
|
||||||
case 0x20: // IRQ0 - timer interrupt
|
case 0x20: // IRQ0 - timer interrupt
|
||||||
timer++;
|
timer++;
|
||||||
(*(byte *)(0xb8000+3998))++;
|
(*(byte *)(0xb8000))++;
|
||||||
eoi();
|
eoi();
|
||||||
break;
|
break;
|
||||||
case 0x21: // IRQ1 - keyboard interrupt
|
case 0x21: // IRQ1 - keyboard interrupt
|
||||||
|
2
video.c
2
video.c
@ -17,6 +17,8 @@ void video_init(ModeInfoBlock *mib)
|
|||||||
case 32:
|
case 32:
|
||||||
vid_ptr32 = (dword *) video_mode.PhysBasePtr;
|
vid_ptr32 = (dword *) video_mode.PhysBasePtr;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
vid_Buffer = mm_palloc((4*video_mode.XResolution*video_mode.YResolution)/4096+1, PID_KERNEL);
|
||||||
|
|
||||||
dword tot = ((video_mode.XResolution) * (video_mode.YResolution));
|
dword tot = ((video_mode.XResolution) * (video_mode.YResolution));
|
||||||
int a;
|
int a;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user