From the course: Linux Device Drivers: Reading, Writing, and Debugging
Unlock this course with a free trial
Join today to access over 25,300 courses taught by industry experts.
Challenge: Modify and test a user space driver - Linux Tutorial
From the course: Linux Device Drivers: Reading, Writing, and Debugging
Challenge: Modify and test a user space driver
(bouncy electronic music) - [Instructor] Let's look at a couple challenges related to user space drivers. We have two of them, one of them for the e1000e network device, getting the Mac address like we showed in the example. So we have in the exercise directory there a file, get_mac-challenge.c and in comments, all in caps, you'll see the word challenge with the changes that you need to make. The second one is a Python program to read that bmp180 temperature sensor. So there's a challenge file for that. Again, look for challenge in caps to see what you need to change. Let's take a look. So there's the two files. Let's look in the get_mac-challenge and we search for challenge. And there we see you need to do an open with a uio device. You have to figure out what that's called, it's up above in a define. And then we have another challenge where you do the mmap. So you get a little bit of practice of opening up the device and doing an mmap. The other challenge is the Python program. And…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
-
-
(Locked)
Introduction to user space device drivers3m 34s
-
(Locked)
UIO, mapping device memory, and interrupts2m 43s
-
(Locked)
Kernel modules for user space drivers1m 31s
-
(Locked)
User space Ethernet driver1m 56s
-
(Locked)
I2C from user space1m 37s
-
(Locked)
Challenge: Modify and test a user space driver1m 51s
-
(Locked)
Solution: Modify and test a user space driver1m 41s
-
(Locked)
-