>From e428633ff0df5fe8501aaf785c6961fc766344b2 Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan <adobri...@gmail.com>
Date: Tue, 9 Feb 2021 00:31:23 +0300
Subject: [PATCH 07/11] pragma once: convert kernel/time/timeconst.bc

Generate include/generated/timeconst.h without include guard.

Signed-off-by: Alexey Dobriyan <adobri...@gmail.com>
---
 kernel/time/timeconst.bc | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/kernel/time/timeconst.bc b/kernel/time/timeconst.bc
index 7ed0e0fb5831..42b3a542e5f5 100644
--- a/kernel/time/timeconst.bc
+++ b/kernel/time/timeconst.bc
@@ -41,12 +41,9 @@ define fmuls(b,n,d) {
 }
 
 define timeconst(hz) {
+       print "#pragma once\n"
        print "/* Automatically generated by kernel/time/timeconst.bc */\n"
        print "/* Time conversion constants for HZ == ", hz, " */\n"
-       print "\n"
-
-       print "#ifndef KERNEL_TIMECONST_H\n"
-       print "#define KERNEL_TIMECONST_H\n\n"
 
        print "#include <linux/param.h>\n"
        print "#include <linux/types.h>\n\n"
@@ -106,9 +103,6 @@ define timeconst(hz) {
                print "#define HZ_TO_NSEC_DEN\t\t", hz/cd, "\n"
                print "#define NSEC_TO_HZ_NUM\t\t", hz/cd, "\n"
                print "#define NSEC_TO_HZ_DEN\t\t", 1000000000/cd, "\n"
-               print "\n"
-
-               print "#endif /* KERNEL_TIMECONST_H */\n"
        }
        halt
 }
-- 
2.29.2

Reply via email to