Search found 92 matches
- Wed Apr 11, 2012 10:50 pm
- Forum: Beginning OS Development
- Topic: Physical Memory Manger
- Replies: 4
- Views: 37507
Re: Physical Memory Manger
As far as I understand the value of 'frame' is the number of the first free bit from the beginning of bitmap. So how does multiplying this value by block size gives the physical address of the block? Each bit in the bitmap represents a region of 4KB in memory, so multiplying the bit by the block si...
- Sun Jan 01, 2012 10:47 pm
- Forum: Lounge
- Topic: Happy new year...
- Replies: 5
- Views: 94379
Re: Happy new year...
Happy new year to all of you.
- Tue Oct 18, 2011 1:49 pm
- Forum: Site Comments, Suggestions, and Ideas
- Topic: Spam
- Replies: 5
- Views: 48568
Re: Spam
BUMP
Spam is killing these forums. Please do something about it.
Spam is killing these forums. Please do something about it.
- Thu Oct 06, 2011 10:13 am
- Forum: Beginning OS Development
- Topic: Using the VMM & Kernel load trouble
- Replies: 9
- Views: 52985
Re: Using the VMM & Kernel load trouble
DMA memory needs to be identity mapped and not cross a 64KB boundary. If you hadn't already done so, allocate a region of memory, and identity map it. To do so, I use the following code to set up a 64KB DMA memory region: // allocate 64KB DMA buffer and identity map it void* flpydsk_dma = pmmngr_all...
- Fri Sep 30, 2011 2:17 pm
- Forum: Beginning OS Development
- Topic: Using the VMM & Kernel load trouble
- Replies: 9
- Views: 52985
Re: Using the VMM & Kernel load trouble
I have the same problem with triple faulting if my kernel size exceeded 31.5 KB However, up until that point it runs just fine. Could you post the code that sets up the stack? I had a problem with the stack, as set up by the bootloader, that was overwriting parts of my kernel. I relocated the stack ...
- Wed Jun 22, 2011 11:05 pm
- Forum: General Programming
- Topic: OS Development Series code question
- Replies: 34
- Views: 162018
Re: OS Development Series code question
I might have discovered a (bug?) in the kybrd.h/.cpp code files. in the _kkybrd_scancode_std array there were 8 items missing (scancode 0x4a - 0x4f) and scancode 0x47 and 0x49 had the wrong char codes assigned. I'm using a keyboard with the US layout, in case you were curious. the old code: KEY_HOME...
- Sat Jun 11, 2011 2:15 pm
- Forum: Beginning OS Development
- Topic: Problems/Virtual PC
- Replies: 6
- Views: 44514
Re: Problems/Virtual PC
I too have problems with the floppy driver in VPC. Though I suppose it is due to the error-checking my driver does, since on real hardware, it cannot return the head to sector 0 in one try. So I retry a couple of times to get the head to where I want it. Unfortunately, that makes it hang in Virtual ...
- Tue Mar 29, 2011 9:41 pm
- Forum: General Programming
- Topic: Kernel trouble
- Replies: 19
- Views: 106051
Re: Kernel trouble
This is weird. I've been shifting around bits of code in preparation of some additions to the kernel (no change to functions, just moved some to other files). And I placed a cli/hlt pair in my code after the first call to DebugPrintf, and it runs up to that point. If I remove it, the kernel crashes ...
- Mon Mar 28, 2011 2:48 pm
- Forum: Beginning OS Development
- Topic: How to detect processor string and speed?
- Replies: 3
- Views: 12696
Re: How to detect processor string and speed?
The Processor Brand string can be accessed by CPUID, using eax = 0x80000002, 0x80000003 and 0x80000004 in sequence It's a 48 byte null-terminated string, returned in four byte sequences via eax, ebx, ecx and edx per call For more information about CPUID, read the wikipedia article at http://en.wikip...
- Mon Mar 14, 2011 9:51 pm
- Forum: General Programming
- Topic: Kernel trouble
- Replies: 19
- Views: 106051
Re: Kernel trouble
Hello, I find it suspicious that the latest chapter would work considering it does not contain the updated VMM software. The PMM is the same in both demos so I suspect it might be this update that causes the compatibility issue with your PC. Please verify if this assumption is correct by comparing ...
- Mon Mar 14, 2011 6:42 pm
- Forum: General Programming
- Topic: Kernel trouble
- Replies: 19
- Views: 106051
Re: Kernel trouble
Ignore my previous post. The problem was in a chunk of code that was supposed to gather information about the CPU. I removed it, and now it boots a little further. However, this is where I run back into an old quirk in that my kernel behaves differently in Bochs and on real hardware. In Bochs, my ke...
- Mon Mar 07, 2011 7:33 pm
- Forum: General Programming
- Topic: Kernel trouble
- Replies: 19
- Views: 106051
Re: Kernel trouble
The display should not go black after a cli+hlt is hit however emulators and virtual machines can handle this situation in different ways. In Bochs it should not. If it does it might imply a buffer overrun error. I think you meant that the display should not turn blue. Anyway, when my kernel enters...
- Sat Mar 05, 2011 1:56 pm
- Forum: General Programming
- Topic: Kernel trouble
- Replies: 19
- Views: 106051
Re: Kernel trouble
Can you post your code which declares the IDT, and the code which fills it with the relevent service routines? Sure, here's the IDT descriptor declaration: #ifdef _MSC_VER #pragma pack (push, 1) #endif //! interrupt descriptor struct idt_descriptor { //! bits 0-16 of interrupt routine (ir) address ...
- Wed Mar 02, 2011 10:22 pm
- Forum: General Programming
- Topic: Kernel trouble
- Replies: 19
- Views: 106051
Re: Kernel trouble
That means that you have your IDT correctly. Good to hear I'm at least doing something right. You have an invalid segment set as the target code segment. It should be 0x08 which is your ring0 code segment. No kidding. Just looked up the Instruction pointer, it's at 0xE001FEA6 which is about 3,5 GB ...
- Wed Mar 02, 2011 6:42 pm
- Forum: General Programming
- Topic: Kernel trouble
- Replies: 19
- Views: 106051
Re: Kernel trouble
Hmmm, I replaced a couple of for(;;); instances with __asm { cli hlt } blocks in the exception handlers, and recompiled my kernel, and now I get the following two errors when my kernel executes (one error less than before) interrupt(): gate descriptor is not valid sys seg (vector=0x0e) interrupt(): ...