Tuesday, November 15, 2005

INF files and Driver Issues

Currently I dont have a precise
method to create a component for
the nvidia (or ati) using the inf
files that come with.

Here is a pretty good online article
about inf files:
http://www.wd-3.com/archive/InfFiles.htm

Here is what he says about some
of the sections:

These are global:

Version
Control Flags
SourceDisksNames
SourceDisksFiles
DestinationDirs
Strings

These are Hierarchical:

Manufacturer
Models Section --- componet, service, .hw
InstallComponent --- add reg, copy files
InstallServices --- add service
.HW --- add reg

AddReg
CopyFiles

AddServer
AddReg

Ok lets take a look at our inf file
of instrest, an nvidia 5200 card.

Yes i do see the version section that
was previously mentioned.

[Version]
Signature = "$Windows NT$"
Provider = %NVIDIA%
ClassGUID = {4D36E968-E325-11CE-BFC1-08002BE10318}
Class = Display
CatalogFile = NV4_DISP.CAT
DriverVer = 10/10/2005, 8.1.8.5

Signature section means that this
can only be parsed by windows nt
or greater. That makes sese.
Provider is nvidia which is no
surprise.

Next look at this section extract:
---------------------------------------
[SourceDisksNames]
1 = %DiskID1%

[SourceDisksFiles]
nv4_mini.sys = 1
nvcod.dll = 1
nvsvc32.exe = 1
nv4_disp.dll = 1
nvhwvid.dll = 1
nvoglnt.dll = 1
nvcpl.dll = 1
nvmctray.dll = 1
nvcpl.hlp = 1
nvwddi.dll = 1
nvnt4cpl.dll = 1
nvwcplen.hlp = 1
nvmccs.dll = 1
nvapi.dll = 1

[Manufacturer]
%NVIDIA% = NVIDIA.Mfg
---------------------------------------

so %1% is macro for = %DiskID1%
which is later defined to be:

DiskID1 = "NVIDIA Windows 2000/XP Driver Library Installation Disk 1"

I toyed around with nvcodins.dll
Dump of file nvcodins.dll

File Type: DLL

Section contains the following exports for NVCoInstaller.dll

0 characteristics
434B52D1 time date stamp Tue Oct 11 00:51:13 2005
0.00 version
1 ordinal base
1 number of functions
1 number of names

ordinal hint RVA name

1 0 0000289A NVCoInstaller

Summary
Dump of file nvcodins.dll

File Type: DLL
----------------------------- end exports ------------------

And here are the imports from dumpbin run.
(Not all of dumpbin output is present.)
....
ADVAPI32.dll
2001000 Import Address Table
2007540 Import Name Table
0 time date stamp
0 Index of first forwarder reference

1CD RegCreateKeyExW
1C8 RegCloseKey
1EC RegQueryValueExW
1E2 RegOpenKeyExW
1F9 RegSetValueExW
...
-------------------------------------------------------------------

So this dll calls RegCreateKeyExW makes sense.
Does this single dll create the regsitry keys
needed for nvidia system?


Here are the threads going through my mind.
1) What does the install programm really do?
Is an install responsible placement of dlls
and modification of the registry or does
it call functionality built into the driver
system.
2) why cant i just call the driver installer
program from fba? make vba scrit that runs
the installer program?

0 Comments:

Post a Comment

<< Home