aboutsummaryrefslogtreecommitdiff
path: root/driver
diff options
context:
space:
mode:
Diffstat (limited to 'driver')
-rw-r--r--driver/COPYING (renamed from driver/LICENSE)0
-rw-r--r--driver/Makefile11
-rw-r--r--driver/gator_main.c2
3 files changed, 7 insertions, 6 deletions
diff --git a/driver/LICENSE b/driver/COPYING
index d159169..d159169 100644
--- a/driver/LICENSE
+++ b/driver/COPYING
diff --git a/driver/Makefile b/driver/Makefile
index c4c4e6f..d14e2a0 100644
--- a/driver/Makefile
+++ b/driver/Makefile
@@ -14,7 +14,6 @@ gator-y := gator_main.o \
gator_events_net.o \
gator_events_perf_pmu.o \
gator_events_sched.o \
- gator_src_md5.o \
# Convert the old GATOR_WITH_MALI_SUPPORT to the new kernel flags
ifneq ($(GATOR_WITH_MALI_SUPPORT),)
@@ -64,7 +63,9 @@ gator-$(CONFIG_ARM) += gator_events_armv6.o \
gator-$(CONFIG_ARM64) +=
-clean-files := gator_src_md5.c
+$(obj)/gator_main.o: $(obj)/gator_src_md5.h
+
+clean-files := gator_src_md5.h
# Note, in the recipe below we use "cd $(srctree) && cd $(src)" rather than
# "cd $(srctree)/$(src)" because under DKMS $(src) is an absolute path, and we
@@ -74,9 +75,9 @@ clean-files := gator_src_md5.c
chk_events.h = :
quiet_chk_events.h = echo ' CHK $@'
silent_chk_events.h = :
-$(obj)/gator_src_md5.c: FORCE
+$(obj)/gator_src_md5.h: FORCE
@$($(quiet)chk_events.h)
- $(Q)cd $(srctree) && cd $(src) ; $(CONFIG_SHELL) -c "echo 'char *gator_src_md5 = \"'\`ls *.c *.h mali/*.h | grep -Ev '^(gator_src_md5\.c|gator\.mod\.c)$$' | LC_ALL=C sort | xargs cat | md5sum | cut -b 1-32\`'\";'" > $(@F)
+ $(Q)cd $(srctree) && cd $(src) ; $(CONFIG_SHELL) -c "echo 'static char *gator_src_md5 = \"'\`ls *.c *.h mali/*.h | grep -Ev '^(gator_src_md5\.c|gator\.mod\.c)$$' | LC_ALL=C sort | xargs cat | md5sum | cut -b 1-32\`'\";'" > $(abspath $@)
else
@@ -88,7 +89,7 @@ all:
$(error)
clean:
- rm -f *.o .*.cmd gator_src_md5.c modules.order Module.symvers gator.ko gator.mod.c
+ rm -f *.o .*.cmd gator_src_md5.h modules.order Module.symvers gator.ko gator.mod.c
rm -rf .tmp_versions
endif
diff --git a/driver/gator_main.c b/driver/gator_main.c
index 1dcca0e..affa1dc 100644
--- a/driver/gator_main.c
+++ b/driver/gator_main.c
@@ -28,6 +28,7 @@ static unsigned long gator_protocol_version = PROTOCOL_VERSION;
#include <linux/uaccess.h>
#include "gator.h"
+#include "gator_src_md5.h"
#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 32)
#error kernels prior to 2.6.32 are not supported
@@ -264,7 +265,6 @@ GATOR_EVENTS_LIST
******************************************************************************/
MODULE_PARM_DESC(gator_src_md5, "Gator driver source code md5sum");
-extern char *gator_src_md5;
module_param_named(src_md5, gator_src_md5, charp, 0444);
static const struct gator_cpu gator_cpus[] = {