RE: How Does a application switches from user mode to Ker nal mode

Hi Ajitabh,

              In the case of contaxt switching the interrupt generated is 0x30, Which is generated by the SDK API provided to you. Take an example of your ReadFile, as u call this API, it takes all the parameter from User Application and make a contaxt switch to the kernel mode with the generation of the INT 30 in the call NtReadFile in the standard DLL ntdll.dll, which is called from the ReadFile API.

Good Luck,

From: “Saxena, Ajitabh Prakash”

>Reply-To: “NT Developers Interest List”
>To: “NT Developers Interest List”
>Subject: [ntdev] RE: How Does a application switches from user mode to Ker nal mode
>Date: Thu, 19 Jun 2003 11:29:53 -0400
>
>Then what in the case of a call to “ReadFile” in user mode application ??
>This requires the switch from user mode to kernal mode…right?? how is this
>done??
>
>-----Original Message-----
>From: Roddy, Mark [mailto:xxxxx@stratus.com]
>Sent: Thursday, June 19, 2003 11:22 AM
>To: NT Developers Interest List
>Subject: [ntdev] RE: How Does a application switches from user mode to
>Ker nal mode
>
>
>The timer interrupt handler in the kernel starts the whole mess going.
>
>-----Original Message-----
>From: Saxena, Ajitabh Prakash [mailto:xxxxx@lsil.com]
>Sent: Thursday, June 19, 2003 11:16 AM
>To: NT Developers Interest List
>Subject: [ntdev] How Does a application switches from user mode to Kernal
>mode
>
>
>hi all,
> I read in Newcomer’s book that whenever a quantum of anythread
>expires a DISPATCH_LEVEL software interrupt is generated (using x86’s int
>instruction).
>
>My Questions are:
>1> Say if the thread is running in user mode and it’s quantum expires
>1> will
>it still call “int” from “user mode”.
>2> Don’t we have to be in kernal mode to generate a software interrupt
>2> ???
>If we have to be in kenal to use software INT instrustion then how does this
>switch takes place??
>
>Anyother details are highly appriciated.
>Thanks
>ajitabh
>
>
>
>
>
>
>
>—
>You are currently subscribed to ntdev as: xxxxx@stratus.com To
>unsubscribe send a blank email to xxxxx@lists.osr.com
>
>
>—
>You are currently subscribed to ntdev as: xxxxx@lsil.com
>To unsubscribe send a blank email to xxxxx@lists.osr.com
>
>
>—
>You are currently subscribed to ntdev as: xxxxx@hotmail.com
>To unsubscribe send a blank email to xxxxx@lists.osr.com


Attention NRIs! Send money home in a jiffy. Find out how here.

int 0x30 my ass. And dont confuse contexts with ring transitions. If you dont know what you are talking about , refrain from posting. In 3 months, a begginer will search this list and may think your answer is correct and you cause him confussion.

----- Original Message -----
From: yatindra vaishnav
To: NT Developers Interest List
Sent: Thursday, June 19, 2003 7:33 PM
Subject: [ntdev] RE: How Does a application switches from user mode to Ker nal mode

Hi Ajitabh,

In the case of contaxt switching the interrupt generated is 0x30, Which is generated by the SDK API provided to you. Take an example of your ReadFile, as u call this API, it takes all the parameter from User Application and make a contaxt switch to the kernel mode with the generation of the INT 30 in the call NtReadFile in the standard DLL ntdll.dll, which is called from the ReadFile API.

Good Luck,



>From: “Saxena, Ajitabh Prakash”
>Reply-To: “NT Developers Interest List”
>To: “NT Developers Interest List”
>Subject: [ntdev] RE: How Does a application switches from user mode to Ker nal mode
>Date: Thu, 19 Jun 2003 11:29:53 -0400
>
>Then what in the case of a call to “ReadFile” in user mode application ??
>This requires the switch from user mode to kernal mode…right?? how is this
>done??
>
>-----Original Message-----
>From: Roddy, Mark [mailto:xxxxx@stratus.com]
>Sent: Thursday, June 19, 2003 11:22 AM
>To: NT Developers Interest List
>Subject: [ntdev] RE: How Does a application switches from user mode to
>Ker nal mode
>
>
>The timer interrupt handler in the kernel starts the whole mess going.
>
>-----Original Message-----
>From: Saxena, Ajitabh Prakash [mailto:xxxxx@lsil.com]
>Sent: Thursday, June 19, 2003 11:16 AM
>To: NT Developers Interest List
>Subject: [ntdev] How Does a application switches from user mode to Kernal
>mode
>
>
>hi all,
> I read in Newcomer’s book that whenever a quantum of anythread
>expires a DISPATCH_LEVEL software interrupt is generated (using x86’s int
>instruction).
>
>My Questions are:
>1> Say if the thread is running in user mode and it’s quantum expires
>1> will
>it still call “int” from “user mode”.
>2> Don’t we have to be in kernal mode to generate a software interrupt
>2> ???
>If we have to be in kenal to use software INT instrustion then how does this
>switch takes place??
>
>Anyother details are highly appriciated.
>Thanks
>ajitabh
>
>
>
>
>
>
>
>—
>You are currently subscribed to ntdev as: xxxxx@stratus.com To
>unsubscribe send a blank email to xxxxx@lists.osr.com
>
>
>—
>You are currently subscribed to ntdev as: xxxxx@lsil.com
>To unsubscribe send a blank email to xxxxx@lists.osr.com
>
>
>—
>You are currently subscribed to ntdev as: xxxxx@hotmail.com
>To unsubscribe send a blank email to xxxxx@lists.osr.com

------------------------------------------------------------------------------
Attention NRIs! Send money home in a jiffy. Find out how here. —
You are currently subscribed to ntdev as: xxxxx@rdsor.ro
To unsubscribe send a blank email to xxxxx@lists.osr.com