Networking Forums

Networking Forums > Computer Networking > Windows Networking > ntldr hangs the system when running in DOS driver

Reply
Thread Tools Display Modes

ntldr hangs the system when running in DOS driver

 
 
santosh
Guest
Posts: n/a

 
      07-06-2005, 04:25 AM
Hi All,

We are writing a 16 bit PXE driver. Our network card registers map in the 32
bit address space using the flat.asm available in net. To access the
registers from real mode we are changing the GDT limit to 4GB as a first step
in our driver. With this we are able to tftp OSChooser.com and ntldr file
with RIS. After this system hangs. Actually it is supposed to get the
winnt.sif file.

I read that during NT boot process has the following steps
4. Ntldr is loaded and initialized from the boot sector
5. Change the processor from real mode to 32-bit flat memory mode
6. Ntldr starts the appropriate minifile system drivers.

Since we have already chnaged the GDT limit to 4GB in the beginning, how
does it will affect the step 5 of NT boot process??

Our GDT table looks like this

FLAT_MODE dw 0ffffh ; Limit (bit 0..15)
db ?,?,? ; Base (bit 0..23)
db 92h ; Access rights
db 0cfh ; Page granularity + Limit(16..19)
db ? ; Base (bit 24..31)

Why ntldr hangs the system in our case?? I guess it has something to do with
our changes to GDT table?? How to overcome this problem??

Any links about the exact boot process internals we will be of great help.

Thanks
-Santosh
//NTLDR crash
 
Reply With Quote
 
 
 
 
Timothy Baldwin
Guest
Posts: n/a

 
      08-05-2005, 04:29 PM
In message <6C97C4DE-EDB4-4852-88DE-(E-Mail Removed)>, santosh
<(E-Mail Removed)> wrote:

> Hi All,
>
> We are writing a 16 bit PXE driver. Our network card registers map in the
> 32 bit address space using the flat.asm available in net. To access the
> registers from real mode we are changing the GDT limit to 4GB as a first
> step in our driver. With this we are able to tftp OSChooser.com and ntldr
> file with RIS. After this system hangs. Actually it is supposed to get the
> winnt.sif file.
>
> I read that during NT boot process has the following steps
> 4. Ntldr is loaded and initialized from the boot sector
> 5. Change the processor from real mode to 32-bit flat memory mode
> 6. Ntldr starts the appropriate minifile system drivers.
>
> Since we have already chnaged the GDT limit to 4GB in the beginning, how
> does it will affect the step 5 of NT boot process??


NTLDR needs to switch back to real mode (or VM86 mode) to call BIOS
functions (including your PXE driver), to do this it should set the segment
limits back to 64K, and I assume it does. Every time your driver is entered
in real mode you should set up the segments, and restore them on exit.

On the other hand your PXE driver can be called in 16 bit protected mode,
could there be a bug in your driver related to protected mode? I don't know
if NTLDR uses the protected mode interface of PXE.

The PXE spec is unclear if PXE APIs can be called in VM86 mode, which would
be a problem.


 
Reply With Quote
 
Jason Gurtz
Guest
Posts: n/a

 
      08-05-2005, 06:45 PM
On 7/6/2005 00:25, santosh wrote:
> Hi All,
>
> We are writing a 16 bit PXE driver. Our network card registers map in the 32
> bit address space using the flat.asm available in net.


Maybe you want to try microsoft.public.masm,
comp.os.ms-windows.programmer.nt.kernel-mode, or comp.lang.asm.x86 (the
latter is pretty active)?

Prolly a bit more help in those groups.

The only thing I can suggest is running a remote debugger over serial so
you can see exactly what's going on. Maybe softice?

~Jason

--
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
system hangs on reboot when initialising eth0..help? Steven Davies Linux Networking 3 06-14-2004 10:32 PM
system hangs on 'ifup eth0' mino Linux Networking 2 01-24-2004 05:20 PM
System Hangs at Startup when connect between ME and XP lee Windows Networking 1 01-03-2004 11:00 AM
Verizon DSL + RedHat 7.2 + RP PPPoE 3.2-3 = system hangs Alan McKenney Linux Networking 2 11-20-2003 01:39 AM
machine hangs on driver install Frank Windows Networking 3 08-27-2003 02:12 PM



1 2 3 4 5 6 7 8 9 10 11