OSDev.org

The Place to Start for Operating System Developers
It is currently Mon May 20, 2024 12:11 pm

All times are UTC - 6 hours




Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: Unhandled interrupt 0x5a
PostPosted: Fri May 20, 2011 4:11 pm 
Offline
Member
Member
User avatar

Joined: Fri Jan 14, 2011 7:24 pm
Posts: 67
I'm using JamesM's tutorial, and the things I've changed are:

int 0x80 to 0x90
monitor_write -> puts
monitor_write_hex -> put_hex
monitor_write_dec -> put_dec
monitor_put -> putc
static void move_cursor -> void move_cursor(int x, int y)
monitor_clear -> clear_screen
the welcome messages
I've added some system calls.

When switching to user mode, I get this error:
Code:
Unhandled interrupt: 0x5a.


I'm not quite sure what this means. I'ver searched google but probably missed something.
Attached is a screen shot of the error.
Thanks, Matt.


Attachments:
File comment: Screenshot of the error.
Screen shot 2011-05-20 at 5.04.23 PM.png
Screen shot 2011-05-20 at 5.04.23 PM.png [ 46.48 KiB | Viewed 1301 times ]

_________________
You are a computer.
~ MCS ~
Top
 Profile  
 
 Post subject: Re: Unhandled interrupt 0x5a
PostPosted: Fri May 20, 2011 4:23 pm 
Offline
Member
Member

Joined: Thu Mar 25, 2010 11:26 pm
Posts: 1801
Location: Melbourne, Australia
Quote:
When switching to user mode, I get this error:
Code:
Unhandled interrupt: 0x5a.

Hex 0x5a is equal to Dec 90. I feel this is not a co-incidence.

_________________
If a trainstation is where trains stop, what is a workstation ?


Top
 Profile  
 
 Post subject: Re: Unhandled interrupt 0x5a
PostPosted: Fri May 20, 2011 4:49 pm 
Offline
Member
Member
User avatar

Joined: Fri Jan 14, 2011 7:24 pm
Posts: 67
isn't the instruction `int $0x90' causing interrupt 90h instead of 90 in decimal?

as in the gcc inline assembly:
Code:
int a;
__asm__ __volatile__("int $0x90" : "=a" (a) : "0" (7));
return a;


Is that
int 90h
or
int 90

I assume it's 90h...

Thanks, Matt

_________________
You are a computer.
~ MCS ~


Top
 Profile  
 
 Post subject: Re: Unhandled interrupt 0x5a
PostPosted: Fri May 20, 2011 5:02 pm 
Offline
Member
Member
User avatar

Joined: Fri Jan 14, 2011 7:24 pm
Posts: 67
Your reply hinted the answer. In the syscall_handler I had changed it to 0x90, but it was supposed to be just 90.

Hence, the 0x5a interrupt was because the interrupt number pushed into the stack when int 0x90 is called is just 90, and the handler expected 0x90. Thank you.

_________________
You are a computer.
~ MCS ~


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 21 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group