Possible error in ioapic.c
Hi man, i am currently reading through your notes on osdev (it is really well done thank you for that).
And i was actually reading the keyboard interrupt chapter in order to implement it myself also using ioapic. And after reading the ioapic redirection table documentation. I was having a bit of trouble finding how to determine how some bit were supposed to be set, so i decided to read through your implentation hoping to find more informations. Sadly I didn't find what I was searching for but while searching I think I found an error in your code.
If I am not mistaken here your are reading bit 2..4 of an Interrupt Override Structure from the MADT, that are the trigger mode flags but you are writing it the the polarity flag of your entry (flag which you already set a few line above)
https://github.com/dreamos82/Dreamos64/blob/137159a7baace4947239ba05474afaf3a81e9f8c/src/kernel/arch/x86_64/cpu/ioapic.c#L136-L140
I don't know if you really expect issues from other people in this repo, but I thought I'd let you know, if it is indeed an error it may avoid you strange bug in the future.
关闭于 2024-12-13 5 条评论