Skip to content

Commit c611838

Browse files
committed
Enforce consistent naming scheme
ksort is only referred as the project name, and the register device name should be simply 'sort'.
1 parent 8f982de commit c611838

File tree

4 files changed

+7
-5
lines changed

4 files changed

+7
-5
lines changed

99-sort.rules

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
KERNEL=="sort", SUBSYSTEM=="sort", MODE="0777"

Makefile

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
obj-m += ksort.o
2-
ksort-objs := \
1+
obj-m += sort.o
2+
sort-objs := \
33
sort_mod.o \
4-
sort.o
4+
sort_impl.o
55

66
obj-m += xoro.o
77
xoro-objs := \
@@ -26,11 +26,11 @@ test_xoro: test_xoro.c
2626
$(CC) -o $@ $^
2727

2828
insmod: all rmmod
29-
sudo insmod ksort.ko
29+
sudo insmod sort.ko
3030
sudo insmod xoro.ko
3131

3232
rmmod:
33-
@sudo rmmod ksort 2>/dev/null || echo
33+
@sudo rmmod sort 2>/dev/null || echo
3434
@sudo rmmod xoro 2>/dev/null || echo
3535

3636
check: user test_xoro

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ In order to access the character device as a user you need to add a rule to
88
udev with the included rules file.
99
```
1010
$ sudo cp 99-xoro.rules /etc/udev/rules.d/
11+
$ sudo cp 99-sort.rules /etc/udev/rules.d/
1112
$ sudo udevadm control --reload
1213
```
1314

sort.c renamed to sort_impl.c

File renamed without changes.

0 commit comments

Comments
 (0)