Windows Kernel 02

Source: Internet
Author: User

Today is Saturday, and I haven't had a rest on Saturday in a few months. I even worked on two projects, three people in the first project, and one person in the second project. It's boring. At best, college students build difficult web programs that are so complicated. Okay. Now, I have to study kernel programming knowledge. I will try again in February.

This week, I checked some basic routine of the WDM driver and how the I/O Manager manages the routine. In the course of learning, I feel like writing windows drivers and ring3 layers, there are many similar upper-layer applications written in Win32. For example, the driver layer is called the dispatch, distribution or dispatch function, and the application layer also uses switch... case... to process different operations. They are also called callback functions in this way. They can also be found from a few words on the blog of experts. They are all a set of things of Microsoft and should be very similar. Therefore, in the future study, it is necessary to associate and compare learning with each other, and the efficiency may be higher.

Next, let's take a look at a small example.

DriverEntry routine

1. Find the hardware controlled by the DriverEntry routine

2. initialization. Input parameters (pointer)

3. iocreatecontroller wear a control object

4. iocreatedevice mounts a device object for the physical or logical device controlled by iocreatedevice and initializes the extension device.

5. Use the iocreatesymboliclink function to "expose" an association name for the Win32 application layer.

6. Contact the "device" and terminal object

7. Repeat steps 4-6

8. DriverEntry returns success_status

If it is a WDM driver, 1, 3-6 steps are placed in adddevice. Plug and Play.

Share a blog: http://www.zeroplace.cn/article.asp? Id = 394

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.