OSDev.org

The Place to Start for Operating System Developers
It is currently Tue Apr 23, 2024 6:45 am

All times are UTC - 6 hours




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: IDT GDT on multiproc
PostPosted: Sun Jan 17, 2010 2:27 am 
Offline

Joined: Thu Jan 07, 2010 7:29 am
Posts: 7
Greetings all,

I am a little confused about the IDT and GDT on multiproc. Do I need to do lgdt and lidt on all the CPUs or just once.


Well it looks like I am sure it should be done on all procs and I have already coding my OS that way, but I didn't find it in the multiproc initilization part of Intel proc manuals. Can you guys please put some light.



Thanks,
Puneet


Top
 Profile  
 
 Post subject: Re: IDT GDT on multiproc
PostPosted: Sun Jan 17, 2010 2:37 am 
Offline
Member
Member
User avatar

Joined: Thu Aug 11, 2005 11:00 pm
Posts: 1110
Location: Tartu, Estonia
You need to do perform lgdt and lidt on all CPUs. Each CPU has its own GDT and IDT registers, so they have to be loaded separately. But of course, you can load the same value into each of them, so you need only one copy of the GDT / IDT stored in memory.

_________________
Programmers' Hardware Database // GitHub user: xenos1984; OS project: NOS


Top
 Profile  
 
 Post subject: Re: IDT GDT on multiproc
PostPosted: Sun Jan 17, 2010 3:10 am 
Offline

Joined: Thu Jan 07, 2010 7:29 am
Posts: 7
Thanks XenOS!!

As I need different TSS for every proc, for thread jump from user to kernel so I have kept separate GDT per processor but same IDT.


Thanks again,
Puneet


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

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 119 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