How can i load the IDT?
-
- Member
- Posts: 273
- Joined: Sun Oct 09, 2016 4:38 am
- Libera.chat IRC: NunoLava1998
How can i load the IDT?
I want to load the IDT. However, i can't find a page with steps on how to do it, and i can't find what order to do it in.
How can i load the Interrupt Descriptor Table?
github at https://github.com/NunoLava1998/DixiumOS
How can i load the Interrupt Descriptor Table?
github at https://github.com/NunoLava1998/DixiumOS
Developing TRIODIUM OS. Or call it Dixium if you want. It doesn't matter.
https://github.com/NunoLava1998/DixiumOS
https://github.com/NunoLava1998/DixiumOS
-
- Member
- Posts: 273
- Joined: Sun Oct 09, 2016 4:38 am
- Libera.chat IRC: NunoLava1998
Re: How can i load the IDT?
I'm pretty sure i've read that a million times (and there is no text that shows how to do things). Not trying to offend.iansjack wrote:http://wiki.osdev.org/IDT
Developing TRIODIUM OS. Or call it Dixium if you want. It doesn't matter.
https://github.com/NunoLava1998/DixiumOS
https://github.com/NunoLava1998/DixiumOS
Re: How can i load the IDT?
You load it with "lidt" instruction. If that was your question.
OS: Basic OS
About: 32 Bit Monolithic Kernel Written in C++ and Assembly, Custom FAT 32 Bootloader
About: 32 Bit Monolithic Kernel Written in C++ and Assembly, Custom FAT 32 Bootloader
-
- Member
- Posts: 273
- Joined: Sun Oct 09, 2016 4:38 am
- Libera.chat IRC: NunoLava1998
Re: How can i load the IDT?
I meant something else. I know you have to load it with lidt.octacone wrote:You load it with "lidt" instruction. If that was your question.
I'm using C by the way. I'll use C++ when needed.
Developing TRIODIUM OS. Or call it Dixium if you want. It doesn't matter.
https://github.com/NunoLava1998/DixiumOS
https://github.com/NunoLava1998/DixiumOS
-
- Member
- Posts: 501
- Joined: Wed Jun 17, 2015 9:40 am
- Libera.chat IRC: glauxosdever
- Location: Athens, Greece
Re: How can i load the IDT?
Hi,
Since you are starting over, you should already know how to implement the features you implemented previously. Didn't you load the IDT previously? If so, why are you asking again the same question?
It's true that over time the community gets more experience as a whole, but:
Edit: Also, would you please remove the image from your signature (or at least replace it with a much smaller one)?
Regards,
glauxosdever
Since you are starting over, you should already know how to implement the features you implemented previously. Didn't you load the IDT previously? If so, why are you asking again the same question?
It's true that over time the community gets more experience as a whole, but:
- This applies to advanced topics;
- This applies over the course of years (don't let the New Year fool you, it's been just 12 days since you asked).
Edit: Also, would you please remove the image from your signature (or at least replace it with a much smaller one)?
Regards,
glauxosdever
Last edited by glauxosdever on Mon Jan 02, 2017 7:07 am, edited 1 time in total.
Re: How can i load the IDT?
Then be constructive and tell us what it is that you don't understand or are doing (show your code) which isn't working. We have limited mind reading.NunoLava1998 wrote:I meant something else.
-
- Member
- Posts: 273
- Joined: Sun Oct 09, 2016 4:38 am
- Libera.chat IRC: NunoLava1998
Re: How can i load the IDT?
I didn't really load it, just that QEMU probably was too nice and loaded it for me. And even then, it didn't work. I'm making everything (except the IDT, of course) with a pinch of salt now.glauxosdever wrote:Hi,
Since you are starting over, you should already know how to implement the features you implemented previously. Didn't you load the IDT previously? If so, why are you asking again the same question?
It's true that over time the community gets more experience as a whole, but:Also, the wiki should describe it clearly enough. If you however have issues understanding the wiki, you can try to ask.
- This applies to advanced topics;
- This applies over the course of years (don't let the New Year fool you, it's been just 12 days since you asked).
Edit: Also, would you please remove the image from your signature (or at least replace it with a much smaller one)?
Regards,
glauxosdever
To anyone asking to remove the image:
okay
To anyone asking what i mean:
I mean about what to do when loading the IDT in a lot of detail, like what order to do functions, what to do, etc., the IDT page does not offer much information (and is confusing).
I am not asking for code.
Last edited by NunoLava1998 on Mon Jan 02, 2017 7:14 am, edited 1 time in total.
Developing TRIODIUM OS. Or call it Dixium if you want. It doesn't matter.
https://github.com/NunoLava1998/DixiumOS
https://github.com/NunoLava1998/DixiumOS
Re: How can i load the IDT?
It describes the whole process of creating the IDT and loading it. What part don't you understand?NunoLava1998 wrote:I'm pretty sure i've read that a million times (and there is no text that shows how to do things). Not trying to offend.iansjack wrote:http://wiki.osdev.org/IDT
Or are you, perhaps, telling us that you don't understand the interrupt mechanism and how to write an interrupt handler?
-
- Member
- Posts: 273
- Joined: Sun Oct 09, 2016 4:38 am
- Libera.chat IRC: NunoLava1998
Re: How can i load the IDT?
Uhh, not the latter part.iansjack wrote:It describes the whole process of creating the IDT and loading it. What part don't you understand?NunoLava1998 wrote:I'm pretty sure i've read that a million times (and there is no text that shows how to do things). Not trying to offend.iansjack wrote:http://wiki.osdev.org/IDT
Or are you, perhaps, telling us that you don't understand the interrupt mechanism and how to write an interrupt handler?
I don't understand a lot how the loading IDT process is like, etc.
I just need a (lot) more detail, which order to make, what to do.
I am not asking for code, by the way.
Developing TRIODIUM OS. Or call it Dixium if you want. It doesn't matter.
https://github.com/NunoLava1998/DixiumOS
https://github.com/NunoLava1998/DixiumOS
Re: How can i load the IDT?
If you know how interrupts work and you know that the IDT must be prepared and IDTR must be loaded with LIDT prior to using interrupts, what's left that you don't understand? Do you understand how GDT, GDTR and LGDT work? This is very similar. Selectors, offsets, segment/gate types, privilege levels, etc.
Re: How can i load the IDT?
OK. So you know how to write an interrupt handler. The wiki page tells you the format of the descriptors in the IDT and how to tell the processor where the table is located.
So what don't you understand?
So what don't you understand?
-
- Member
- Posts: 501
- Joined: Wed Jun 17, 2015 9:40 am
- Libera.chat IRC: glauxosdever
- Location: Athens, Greece
Re: How can i load the IDT?
Hi,
If you don't understand something on the wiki, I'll try to rephrase it so it is more clear.
Regards,
glauxosdever
If you don't understand something on the wiki, I'll try to rephrase it so it is more clear.
Regards,
glauxosdever
-
- Member
- Posts: 273
- Joined: Sun Oct 09, 2016 4:38 am
- Libera.chat IRC: NunoLava1998
Re: How can i load the IDT?
how to actually load the IDT (what do i need to prepare, what do i put in the lidt instruction, etc.)iansjack wrote:OK. So you know how to write an interrupt handler. The wiki page tells you the format of the descriptors in the IDT and how to tell the processor where the table is located.
So what don't you understand?
I don't understand the GDT too, however GRUB already loads this.alexfru wrote:If you know how interrupts work and you know that the IDT must be prepared and IDTR must be loaded with LIDT prior to using interrupts, what's left that you don't understand? Do you understand how GDT, GDTR and LGDT work? This is very similar. Selectors, offsets, segment/gate types, privilege levels, etc.
Okay. The IDT page doesn't offer much, so you can try to add more information.glauxosdever wrote:Hi,
If you don't understand something on the wiki, I'll try to rephrase it so it is more clear.
Regards,
glauxosdever
Developing TRIODIUM OS. Or call it Dixium if you want. It doesn't matter.
https://github.com/NunoLava1998/DixiumOS
https://github.com/NunoLava1998/DixiumOS
Re: How can i load the IDT?
Perhaps, you should follow your own advice?:NunoLava1998 wrote:how to actually load the IDT (what do i need to prepare, what do i put in the lidt instruction, etc.)iansjack wrote:OK. So you know how to write an interrupt handler. The wiki page tells you the format of the descriptors in the IDT and how to tell the processor where the table is located.
So what don't you understand?
Have you downloaded the CPU manual and located the descriptions of GDT, GDTR, LGDT? Ditto for IDT, IDTR, LIDT?NunoLava1998 wrote: Read a bit more of your books and the wiki and you should be able to get it working.