2022-10-28 16:04:51 +09:00
2022-10-28 17:40:57 +09:00
2022-10-24 03:33:16 +02:00
2022-10-28 16:04:51 +09:00
2022-10-28 16:04:51 +09:00
2022-10-28 16:04:51 +09:00

Homework_Lesson_3

Assignment

Modify the kernel module you created in the #2 Homework to accommodate the functionality of a character device that puts the number of time the device file has been read from into the file. Compile and run the program. Try reading the device file through “cat /proc/devices”. Submit the source code and the screen shot of the result of execution displayed by the dmesg command. Deadline of homework: Oct 30, 2022 (in case that you cannot finish in the class)

Prerequisits

  • requires the correct linux headers to be installed
  • root access is needed
  • the Code file is NOT named module.c

how to run the kernel module

  • make to build the module
  • sudo insmod <module_name> to run the module
  • sudo rmmod <module_name> to stop the module

viewing the log

on systems that run systemd: journalctl -f -k you can also use dmesg

Description
No description provided
Readme 179 KiB
2022-10-28 10:42:46 +02:00
Languages
C 52.9%
TeX 40.6%
Shell 4.4%
Makefile 2.1%