From: Jan Engelhardt Date: Tue, 17 Jul 2007 11:03:53 +0000 (-0700) Subject: make timespec_equal() take const arguments X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5b78cc9ac8602baafebb75a09025ffb17d1aebc2;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git make timespec_equal() take const arguments Make arguments of timespec_equal() const struct timespec. Signed-off-by: Jan Engelhardt Cc: Thomas Gleixner Cc: john stultz Cc: Roman Zippel Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/include/linux/time.h b/include/linux/time.h index 4bb05a829be9..ec3b0ced0afe 100644 --- a/include/linux/time.h +++ b/include/linux/time.h @@ -36,7 +36,8 @@ struct timezone { #define NSEC_PER_SEC 1000000000L #define FSEC_PER_SEC 1000000000000000L -static inline int timespec_equal(struct timespec *a, struct timespec *b) +static inline int timespec_equal(const struct timespec *a, + const struct timespec *b) { return (a->tv_sec == b->tv_sec) && (a->tv_nsec == b->tv_nsec); }