F6, INF and TXTSETUP.OEM

I have recently written a scsi miniport driver which I have been testing
on WinXP and Server 2003. Everything is going well except I have
problems installing Windows on to my device.

What works :

  1. The driver installs with no problems when added to an existing
    Windows installation using the driver wizard. This suggests that my
    .inf file is correct.

  2. When I install Windows on to my device using F6, the driver loads
    correctly and I can allocate my device as the installation drive for
    Windows. Windows proceeds to copy the Windows files from the CD on to
    my device.

What fails :

Once all the files are copied, Windows loads the initial configuration
and prepares to reboot. This never completes. Windows halts with the
following message:

Setup cannot set the required Windows XP configuration
information. This indicates a setup error.

Contact your system administrator.

Stepping through the install using WinDBG reveals that the failure is
occurring in setupdd!SpInitializeRegistry. Stepping through the code
has not yet clarified the exact cause.

My guess is that there is some issue with the registry settings included
in either TXTSETUP.OEM or my .inf file.

Q1: Does the .INF file actually get used before GUI-mode setup starts?
If it doesn’t I can narrow my focus to the .OEM file.

Q2: Does anyone have any detailed information about what Windows is
configuring or doing in setupdd!SpInitializeRegistry.

Q3: Has anyone had to solve a similar problem? If so what was the
issue.

Thanks

Julian

Since I’m currently quite involved with text mode setup, I can suggest a few
things to check.

Does you driver/device positivly work at boot time? Install it on a working
system with a sata disk. Clone the system disk to the disk controlled by
your driver, disable the sata disk, boot the cloned disk from your device.
It’s usually best to not let the pre-cloned running system see your target
disk, as it will assign it a drive letter. You can also use regedit on the
system hive of the cloned disk image and remove the mounteddisk assignments.

Is the driver service name 8 characters or less and the driver filename 8.3
name compatable?

Do you use a catalog file, is the catalog valid, as in it’s hashes match the
files?

For the initial file copy, and the text mode setup phase (are these the same
on a cd boot? They are distinct on an unattended network setup from WinPE),
the inf file is not used.

For unattended network setup, I’ve never see .dll files work in
txtsetup.oem, and have to do some sillyness with $oem$$$ to get them in the
right place for the GUI phase setup.

The setup programs are pretty picky about the simple syntax in the
txtsetup.oem, and the syntax is not exactly documented crystal clear, like
registry dword values need to be in a little different format than in the
inf (as I remember no leading 0x, and hex digits only). I would take some
known working txtsetup.oem and use EXACTLY the same syntax. The errors when
it’s wrong can be pretty mysterious. You also only get to set registry
entries under the services key, which means it may problematic installing
filter drivers during text mode setup.

If you have kernel debugging up, did your device load and start?

Booting as you know also requires a boot bios in your device to supply int
13 services (or now uefi) for the boot loader to use. Ideally your boot bios
should pass the WHQL int 13 test program.

Your device must use scsiport not storport right? As there is no XP storport
wrapper. I’m assuming your device also doesn’t use KDMF?

There is a good article in the OSR NT Insider archives about text mode
setup. A google search can find it.

Failures in the gui setup phase can write useful clues into to the .log
files under \windows, although the system will not boot so you need to
access the boot volume by some other means, like boot WinPE and use drvload
to load your drivers. This is also useful for enabling kernel debugging
during GUI phase setup. You can boot WinPE and manually edit boot.ini (I use
1394 debugging, because I like to write crash dumps from windbg before the
system disk is online).

Jan

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Julian Terry
Sent: Thursday, September 11, 2008 8:19 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] F6, INF and TXTSETUP.OEM

I have recently written a scsi miniport driver which I have
been testing on WinXP and Server 2003. Everything is going
well except I have problems installing Windows on to my device.

What works :

  1. The driver installs with no problems when added to an
    existing Windows installation using the driver wizard. This
    suggests that my .inf file is correct.

  2. When I install Windows on to my device using F6, the
    driver loads correctly and I can allocate my device as the
    installation drive for Windows. Windows proceeds to copy the
    Windows files from the CD on to my device.

What fails :

Once all the files are copied, Windows loads the initial
configuration and prepares to reboot. This never completes.
Windows halts with the following message:

Setup cannot set the required Windows XP configuration
information. This indicates a setup error.

Contact your system administrator.

Stepping through the install using WinDBG reveals that the
failure is occurring in setupdd!SpInitializeRegistry.
Stepping through the code has not yet clarified the exact cause.

My guess is that there is some issue with the registry
settings included in either TXTSETUP.OEM or my .inf file.

Q1: Does the .INF file actually get used before GUI-mode setup starts?
If it doesn’t I can narrow my focus to the .OEM file.

Q2: Does anyone have any detailed information about what
Windows is configuring or doing in setupdd!SpInitializeRegistry.

Q3: Has anyone had to solve a similar problem? If so what
was the issue.

Thanks

Julian


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online
at http://www.osronline.com/page.cfm?name=ListServer

__________ Information from ESET NOD32 Antivirus, version of
virus signature database 3436 (20080911) __________

The message was checked by ESET NOD32 Antivirus.

http://www.eset.com

__________ Information from ESET NOD32 Antivirus, version of virus signature
database 3439 (20080912) __________

The message was checked by ESET NOD32 Antivirus.

http://www.eset.com

Ju: Thanks Jan and see below

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Jan Bottorff
Sent: Saturday, September 13, 2008 3:40 AM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] F6, INF and TXTSETUP.OEM

Since I’m currently quite involved with text mode setup, I can suggest a
few
things to check.

Does you driver/device positivly work at boot time? Install it on a
working
system with a sata disk. Clone the system disk to the disk controlled by
your driver, disable the sata disk, boot the cloned disk from your
device.
It’s usually best to not let the pre-cloned running system see your
target
disk, as it will assign it a drive letter. You can also use regedit on
the
system hive of the cloned disk image and remove the mounteddisk
assignments.

Ju: I don’t know if it works at boot time yet as we are still working on
the option ROM to provide int13h. However, it definitely gets files
from the CD copied to it during text mode setup so I can say that it
works then. As soon as we have working int13 I will certainly try you
suggestion of using a cloned disk.

Is the driver service name 8 characters or less and the driver filename
8.3
name compatible?

Ju: I think so, but will check again. I have noticed that geninf seems
to be quite happy to make them larger but I certainly was unable to get
txtsetup.oem to work with long names.

Do you use a catalog file, is the catalog valid, as in it’s hashes match
the
files?

Ju: Currently I do not have a catalog file. I must admit I was
concerned that this would be a problem as I have noticed some comments
suggesting that they might be required. Your comment suggests that not
having one should OK for now.

For the initial file copy, and the text mode setup phase (are these the
same
on a cd boot? They are distinct on an unattended network setup from
WinPE),
the inf file is not used.

Ju: On the CD install the system loads the text mode setup from the cd
and requests F6 for extra drivers. It loads several drivers into memory
and then requests the driver floppys from which it loads my driver. My
guess is that it is loading only the driver and the txtsetup.oem file,
but I cannot be sure. A while later it asks where I should install
windows and presents my device as one of the options ( I tell it’s the
correct device because of the volume size). Setup then creates a
Windows directory on my device and copies the many Windows files to it.

For unattended network setup, I’ve never see .dll files work in
txtsetup.oem, and have to do some sillyness with $oem$$$ to get them in
the
right place for the GUI phase setup.

Ju: Glad to say I’ve no dll’s just a .sys.

The setup programs are pretty picky about the simple syntax in the
txtsetup.oem, and the syntax is not exactly documented crystal clear,
like
registry dword values need to be in a little different format than in
the
inf (as I remember no leading 0x, and hex digits only). I would take
some
known working txtsetup.oem and use EXACTLY the same syntax. The errors
when
it’s wrong can be pretty mysterious. You also only get to set registry
entries under the services key, which means it may problematic
installing
filter drivers during text mode setup.

Ju: That’s how I got as far as I did. Interestingly, if I don’t have
any registry entries in my txtsetup.oem file the driver does not load on
the F6.

If you have kernel debugging up, did your device load and start?

Ju: As I say setup happily copies files to it and the driver is the only
way it could do that.

Booting as you know also requires a boot bios in your device to supply
int
13 services (or now uefi) for the boot loader to use. Ideally your boot
bios
should pass the WHQL int 13 test program.

Ju: see above. I actually never get far enough to need int13 as the
reboot never occurs.

Your device must use scsiport not storport right? As there is no XP
storport
wrapper. I’m assuming your device also doesn’t use KDMF?

Ju: It does use scsiport although I think storport is available on XP.

There is a good article in the OSR NT Insider archives about text mode
setup. A google search can find it.

Ju: Yes, I used that and very good it is too. It was a great help
getting the debugger to work during install.

Failures in the gui setup phase can write useful clues into to the .log
files under \windows, although the system will not boot so you need to
access the boot volume by some other means, like boot WinPE and use
drvload
to load your drivers. This is also useful for enabling kernel debugging
during GUI phase setup. You can boot WinPE and manually edit boot.ini (I
use
1394 debugging, because I like to write crash dumps from windbg before
the
system disk is online).

Ju: text setup also write the log file, however, even with debugging
level 4 enable it doesn’t seem to provide any useful clues.

Jan

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Julian Terry
Sent: Thursday, September 11, 2008 8:19 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] F6, INF and TXTSETUP.OEM

I have recently written a scsi miniport driver which I have
been testing on WinXP and Server 2003. Everything is going
well except I have problems installing Windows on to my device.

What works :

  1. The driver installs with no problems when added to an
    existing Windows installation using the driver wizard. This
    suggests that my .inf file is correct.

  2. When I install Windows on to my device using F6, the
    driver loads correctly and I can allocate my device as the
    installation drive for Windows. Windows proceeds to copy the
    Windows files from the CD on to my device.

What fails :

Once all the files are copied, Windows loads the initial
configuration and prepares to reboot. This never completes.
Windows halts with the following message:

Setup cannot set the required Windows XP configuration
information. This indicates a setup error.

Contact your system administrator.

Stepping through the install using WinDBG reveals that the
failure is occurring in setupdd!SpInitializeRegistry.
Stepping through the code has not yet clarified the exact cause.

My guess is that there is some issue with the registry
settings included in either TXTSETUP.OEM or my .inf file.

Q1: Does the .INF file actually get used before GUI-mode setup starts?
If it doesn’t I can narrow my focus to the .OEM file.

Q2: Does anyone have any detailed information about what
Windows is configuring or doing in setupdd!SpInitializeRegistry.

Q3: Has anyone had to solve a similar problem? If so what
was the issue.

Thanks

Julian


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online
at http://www.osronline.com/page.cfm?name=ListServer

__________ Information from ESET NOD32 Antivirus, version of
virus signature database 3436 (20080911) __________

The message was checked by ESET NOD32 Antivirus.

http://www.eset.com

__________ Information from ESET NOD32 Antivirus, version of virus
signature
database 3439 (20080912) __________

The message was checked by ESET NOD32 Antivirus.

http://www.eset.com


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer