Windows System Software -- Consulting, Training, Development -- Unique Expertise, Guaranteed Results

Before Posting...
Please check out the Community Guidelines in the Announcements and Administration Category.

Why does the console application crash the system?

jguo5258jguo5258 Member Posts: 22
So basically I am making a driver, and when I close the console application that interacts with the driver, it crashes the system. Why? Are there open handles? Do I have to do something about the mdl address? This happens after I perform a direct write operation to driver

Comments

  • jguo5258jguo5258 Member Posts: 22
    The system crash code is PROCESS_HAS_LOCKED_PAGES
    0x76
  • Peter_Viscarola_(OSR)Peter_Viscarola_(OSR) Administrator Posts: 7,515

    Why? Because your driver has a bug.

    What bug? I don’t know. I can’t see your code or read your mind.

    If you want help with the crash, post the output from WinDbg !analyze -v, and with the symbols properly loaded.

    Peter

    Peter Viscarola
    OSR
    @OSRDrivers

  • anton_bassovanton_bassov Member Posts: 5,065

    So basically I am making a driver, and when I close the console application that interacts with the driver, it crashes the system. Why?

    The most likely scenario is that your driver accesses the userland addresses. When your app terminates its userland address space becomes meaningless straight away, but its threads that run in the kernel mode at the moment may still be alive until they try returning to the userland. Therefore, if your driver accesses the userland in context of such a thread BSOD is simply inevitable.

    This is the very first thought that gets into my head. However, as Peter told you already, in order to get a more precise suggestion you need to post the output that you get from !analyze -v,

    Anton Bassov

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Upcoming OSR Seminars
Writing WDF Drivers 21 Oct 2019 OSR Seminar Space & ONLINE
Internals & Software Drivers 18 Nov 2019 Dulles, VA
Kernel Debugging 30 Mar 2020 OSR Seminar Space
Developing Minifilters 27 Apr 2020 OSR Seminar Space & ONLINE