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