DDK/WDM 开发问题...驱动程序无法在 x64 windows 平台上加载

发布于 2024-08-25 03:58:45 字数 784 浏览 17 评论 0原文

我是DDK/WDM驱动开发领域的初学者。 我有一个任务涉及将虚拟设备驱动程序从 x86 移植到 x64 (intel)。 我拿到了源代码,我对其进行了一些修改,并使用DDK(构建环境)成功编译了它。但是当我尝试在 ia64 Windows7 机器上加载它时,它不想加载。 设备驱动程序的一些简单示例

然后我尝试了来自--http://www.codeproject 的 。 com/KB/system/driverdev.aspx (我输入“--”以便能够发布超链接)和其他链接,但仍然存在同样的问题。

我在论坛上听说您用来链接的某些库与新机器不兼容,并建议链接到另一个类似的库......但仍然不起作用。

当我构建时,我按照建议使用“-cefw”命令行参数。

我没有关联的 *.inf 文件,但我将其复制到 system32/drivers 中,并使用 WinObj 来查看下次重新启动时它是否已加载到内存中。

我也尝试过这个程序( http://www.codeproject.com/KB/system/ tdriver.aspx )将驱动程序加载到内存中,但仍然对我不起作用。

请帮助我...我被困在这个问题上并且我的截止日期已经过去了。 我觉得我在这里发疯了,试图发现我做错了什么。

I am a beginner at DDK/WDM driver developing field.
I have a task which involves porting a virtual device driver from x86 to x64 (intel).
I got the source code, I modified it a bit and compiled it succesfuly with DDK (build environments). But when I tried to load it on a ia64 Windows7 machine it didn't want to load.
Then I tried some simple examples of device drivers from

--http://www.codeproject.com/KB/system/driverdev.aspx (I put '--' to be able to post the hyperlink) and from other links but still the same problem.

I hear on a forum that some libraries that you use to link are not compatible with the new machines and suggested to link to another similar libraries...but still didn't worked.

When I build I use "-cefw" command line parameters as suggested.

I do not have an *.inf file asociated but I'm copying it in system32/drivers and I'm using WinObj to see if next restart it's loaded into the memory.

I also tried this program ( http://www.codeproject.com/KB/system/tdriver.aspx ) to load the driver into the memory but still didn't worked for me.

Please please help me...I'm stuck on this and my deadline already passed.
I feel I'driving nuts in here trying to discover what am I doing wrong.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

屋顶上的小猫咪 2024-09-01 03:58:45

因此,总结一下一切:

  1. 您需要构建正确的架构(针对 Intel/AMD CPU 的 x64)。
  2. 必须签署您的驱动程序。即使在测试模式下,您也必须使用自签名证书执行此操作。别无选择。
  3. 必须使用.inf 文件进行安装。如果驱动程序是非 pnp 的,则不需要 .inf 文件,但驱动程序不太可能是非 pnp 的。在这种情况下,您需要使用 sc.exe 或以编程方式使用 SCM API 在服务控制管理器中手动创建驱动程序的关联服务。如果驱动程序是 pnp(最有可能),则必须通过 .inf 文件(使用 devcon.exe 或其他方式)安装它。此外,安装它与加载它不同。为此,必须存在适当的硬件,或者您必须在软件中枚举它(例如 devcon.exe)。

So, to summarize everything:

  1. You need to build for the corect architecture (x64 for Intel/AMD CPUs).
  2. You MUST sign your driver. You must do this even in test mode with a self signed certificate. There is no alternative.
  3. You MUST use an .inf file to install. If the driver is non-pnp then you don't need an .inf file, but it is very unlikely that the driver is non-pnp. In that case you need to manually create the associated service for the driver in the service control manager with sc.exe or programmatically with the SCM API. If the driver isw pnp (most likely) you must install it via an .inf file (with devcon.exe or other way). Also, installing it is not the same as loading it. For that, the appropriate hardware must be present or you must enumerate it in software (with devcon.exe for exemple).
未央 2024-09-01 03:58:45

我没有编写驱动程序,而是根据我从同事那里听到的信息:您的驱动程序有数字签名吗?如果没有,请查找有关在 64 位系统上加载未签名驱动程序的信息。

I did not wrote a driver, but on the basis on what I hear from colleagues: Are your driver digitaly signed? If not, look for information on loading unsigned drivers on 64bit systems.

原谅过去的我 2024-09-01 03:58:45

两件事:

  1. 您提到了 x64(也称为 x86-64、AMD64 或 EMT64)和 IA64 (Itanium)。你知道它们是两种完全不同的架构,对吧?您有安腾系统吗?如果不是,则不应使用 IA-64 构建环境来编译任何内容。它无法在标准 PC(32 或 64)上运行。

  2. 在 64 位下,驱动程序必须经过数字签名才能用于生产。您需要从 Verisign 或类似机构获取 Authenticode 证书。出于测试目的,您可以在启动时按 F8 来绕过签名检查。您还可以使用测试证书进行签名。

    http://www.microsoft.com/whdc/winlogo/drvsign /drvsign.mspx

Two things:

  1. You mention both x64 (also called x86-64, AMD64, or EMT64) and IA64 (Itanium). You understand they are two completely different architectures, right? Do you have an Itanium System? If not, you should not be compiling anything using the IA-64 build environment. It won't run on a standard PC (32 or 64).

  2. Under 64-bit, the driver must digitally signed for production use. You will need to get an Authenticode certificate from Verisign or similar. For testing purposes, you can bypass the signature check by pressing F8 at boot time. You can also sign with a test certificate.

    http://www.microsoft.com/whdc/winlogo/drvsign/drvsign.mspx

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文