From 8e969c9f1b01b35f681a68bf99e99a71a49d17f3 Mon Sep 17 00:00:00 2001 From: superconvert <48017165+superconvert@users.noreply.github.com> Date: Thu, 28 Jul 2022 22:27:31 +0800 Subject: [PATCH] Delete make_driver.sh --- make_driver.sh | 36 ------------------------------------ 1 file changed, 36 deletions(-) delete mode 100644 make_driver.sh diff --git a/make_driver.sh b/make_driver.sh deleted file mode 100644 index f02bef9..0000000 --- a/make_driver.sh +++ /dev/null @@ -1,36 +0,0 @@ -#!/bin/sh - -mkdir -pv driver && cd driver - -cat<hello_world.c -#include -#include -#include - -MODULE_LICENSE("GPL"); - -static int __init hello_world_init(void) -{ - printk(KERN_DEBUG "hello world!!!\n"); - return 0; -} - -static void __exit hello_world_exit(void) -{ - printk(KERN_DEBUG "goodbye world!!!\n"); -} - -module_init(hello_world_init); -module_exit(hello_world_exit); -EOF - -cat<Makefile -obj-m += hello_world.o -all: - make -C ../work/linux-4.14.9 M=`pwd` modules -clean: - make -C ../work/linux-4.14.9 M=`pwd` clean -EOF - -echo $1 -make && mv hello_world.ko $1 && make clean && cd .. && rm -rf driver