Page 1 of 1

Small Interrupt Problem.....?

Posted: Sat Apr 26, 2003 12:39 am
by Perica
..

Re:Small Interrupt Problem.....?

Posted: Sat Apr 26, 2003 1:28 am
by Thunder
Show us you code example,
are you working in C or asm?

Just then we'll can help you...

Re:Small Interrupt Problem.....?

Posted: Sat Apr 26, 2003 1:45 am
by Perica
..

Re:Small Interrupt Problem.....?

Posted: Sat Apr 26, 2003 4:01 am
by Tim
The error codes don't mean much on their own. You should search for that text in the Bochs source code and examine what it's doing there.

However, that "io write to address" error implies that you're writing where you shouldn't. Specifically, you're writing 4 bytes when you should probably be only writing 1.

Re:Small Interrupt Problem.....?

Posted: Sat Apr 26, 2003 4:51 am
by distantvoices
the bochs error regarding the length...

perica, as tim says, it is the length you try to write to the 0x3f2 register: do you say in your code mov eax,[value], then out 0x3f2,eax? Using smaller register will help out: ax=16 bits,ah=8 bits.

Re:Small Interrupt Problem.....?

Posted: Sat Apr 26, 2003 5:07 am
by Perica
..

Re:Small Interrupt Problem.....?

Posted: Sun Apr 27, 2003 7:21 am
by distantvoices
You output something to a port, perica, else bochs wouldn't complain about that.0x3f0 is the base of the fdc controller. stop ****ing on my back and telling me it's raining, gosh.

The second, your stack problem: I've encountered this too. I've solved it by giving the kernel a valid esp0 to push things to when an interrupt occurs.

I DOUBT, that your idt setup code is to blame for that. It rather seems as if some valid stack is missing. you can load a system tss and enter esp0 ss0 values to get this issue running.

stay safe.

Re:Small Interrupt Problem.....?

Posted: Sun Apr 27, 2003 11:45 pm
by Perica
..

Re:Small Interrupt Problem.....?

Posted: Mon Apr 28, 2003 12:43 am
by distantvoices
I don't think you are stupid, perica. take it with a grain of salt. 8)

I tell you the following: you say, you fire an interrupt and it executes. Fine. Then with your IDT-Padding, everything is ALL RIGHT. I have not tested it. It looks all right. Bochs would give you a triple fault if your idt was wrong.

You shall trace the execution of your code with bochs debug. You can send bochs debug output to a text file. It will show you where your code craps out.