aboutsummaryrefslogtreecommitdiffstats
path: root/tasks/17/readme
diff options
context:
space:
mode:
authorBryan Brattlof <hello@bryanbrattlof.com>2020-07-15 17:04:22 -0400
committerBryan Brattlof <hello@bryanbrattlof.com>2020-07-15 17:04:22 -0400
commit39da62d05310ecc7cc64f8cc8665f25fc69eefe8 (patch)
tree60728a14c28fd2b4a2acafadf588c5f2cc2876dd /tasks/17/readme
parent96e2a9dbe1851c8cbb4e80511fa1d77401149101 (diff)
downloadeudyptula-challenge-39da62d05310ecc7cc64f8cc8665f25fc69eefe8.tar.gz
eudyptula-challenge-39da62d05310ecc7cc64f8cc8665f25fc69eefe8.tar.bz2
task 17: add task readme
Diffstat (limited to 'tasks/17/readme')
-rw-r--r--tasks/17/readme38
1 files changed, 38 insertions, 0 deletions
diff --git a/tasks/17/readme b/tasks/17/readme
new file mode 100644
index 0000000..ce4ced8
--- /dev/null
+++ b/tasks/17/readme
@@ -0,0 +1,38 @@
+Task 17
+=======
+
+Another patch made and sent in. See, that wasn't so hard. Keep sending
+in kernel patches outside of this challenge, those lazy kernel
+developers need all the help they can get in cleaning up their code.
+
+It is time to start putting the different pieces of what we have done in
+the past together, into a much larger module, doing more complex things.
+Much more like what a "real" kernel module has to do.
+
+Go dig up your code from task 06, the misc char device driver, and make
+the following changes:
+
+ - Delete the read function. You don't need that anymore, so make it a
+ write-only misc device and be sure to set the mode of the device to
+ be write-only, by anyone. If you do this right, udev will set up the
+ node automatically with the correct permissions.
+
+ - Create a wait queue, name it "wee_wait".
+
+ - In your module init function, create a kernel thread, named of course
+ "eudyptula".
+
+ - The thread's main function should not do anything at this point in
+ time, except make sure to shutdown if asked to, and wait on the
+ "wee_wait" waitqueue.
+
+ - In your module exit function, shut down the kernel thread you started
+ up.
+
+Load and unload the module and "prove" that it works properly (that the
+thread is created, it can be found in the process list, and that the
+device node is created with the correct permission value.) Send in the
+proof and the .c file for the module.
+
+Be sure to keep this code around, as we will be doing more with it next
+time.