Hello
I’m new Driver programmer and I have a problem :
I have to migrate a NT-driver to XP and I should use “HalTranslateBusAddress” method (hower obsolete it is).
My problem is that this function seems not to be available even importing “ntddk.h”.
Is there any way to use this function “HalTranslateBusAddress” anyway else ?
Thank you
Guillaume
What type of driver is this? Unless you are doing something very special
you should not be using HalTranslateBusAddress but instead getting this
data as part of start device in the driver. A hardware driver using legacy
approach (such as HalTranslateBusAddress) is not assured of working on XP.
You have two choices here:
- Update your driver with Plug and Play / Power management using the
WDM model.
- Convert your driver to KMDF so that much of this magic is taken
care of for you.
Without know how complex your driver is, the “best method” is impossible to
say, but personally I would strongly recomend using KMDF since it will take
care of much of the code you otherwise will have to write.
–
Don Burn (MVP, Windows DDK)
Windows 2k/XP/2k3 Filesystem and Driver Consulting
Website: http://www.windrvr.com
Blog: http://msmvps.com/blogs/WinDrvr
Remove StopSpam to reply
wrote in message
news:xxxxx@ntdev…
> Hello
>
> I’m new Driver programmer and I have a problem :
> I have to migrate a NT-driver to XP and I should use
> “HalTranslateBusAddress” method (hower obsolete it is).
>
> My problem is that this function seems not to be available even importing
> “ntddk.h”.
> Is there any way to use this function “HalTranslateBusAddress” anyway
> else ?
>
> Thank you
>
> Guillaume
>
More information :
My driver is use for an old ISA card and I can’t update the hardware.
I have to map the memory for the user.
Thanks for your reply
Guillaume
ISA cards are still PNP, you just have to do the assignment of resources in
the INF file. Trying to use a non-PNP capable driver on XP with real
hardware is an extremely BAD IDEA. So you still have the same choice,
either add all the PNP stuff yourself constructing a complex state machine,
or rewrite your driver to KMDF and let the framework supply most of the
state machine.
–
Don Burn (MVP, Windows DDK)
Windows 2k/XP/2k3 Filesystem and Driver Consulting
Website: http://www.windrvr.com
Blog: http://msmvps.com/blogs/WinDrvr
Remove StopSpam to reply
wrote in message
news:xxxxx@ntdev…
> More information :
> My driver is use for an old ISA card and I can’t update the hardware.
> I have to map the memory for the user.
>
> Thanks for your reply
> Guillaume
>
> I have to migrate a NT-driver to XP and I should use “HalTranslateBusAddress”
You will need to rewrite the driver to WDM/PnP, possibly using KMDF. After
this, you will no more need HalTranslateBusAddress.
–
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com