UPSTREAM: jiffies.h: declare jiffies and jiffies_64 with ____cacheline_aligned_in_smp

jiffies_64 is defined in kernel/time/timer.c with
____cacheline_aligned_in_smp, however this macro is not part of the
declaration of jiffies and jiffies_64 in jiffies.h.

As a result clang generates the following warning:

  kernel/time/timer.c:57:26: error: section does not match previous declaration [-Werror,-Wsection]
  __visible u64 jiffies_64 __cacheline_aligned_in_smp = INITIAL_JIFFIES;
  include/linux/cache.h:39:36: note: expanded from macro '__cacheline_aligned_in_smp'
  include/linux/cache.h:34:4: note: expanded from macro '__cacheline_aligned'
  include/linux/jiffies.h:77:12: note: previous attribute is here
  extern u64 __jiffy_data jiffies_64;
  include/linux/jiffies.h:70:38: note: expanded from macro '__jiffy_data'

TEST=build and boot on gru

Signed-off-by: Matthias Kaehlcke <>
Cc: "Jason A . Donenfeld" <>
Cc: Grant Grundler <>
Cc: Michael Davidson <>
Cc: Greg Hackmann <>
Cc: Thomas Gleixner <>
Signed-off-by: Andrew Morton <>
Signed-off-by: Linus Torvalds <>
(cherry picked from commit 7c30f352c852bae2715ad65ac4a38ca9af7d7696)

Change-Id: I7645b60abe21b3ef72dd6bbaf53434cadf260e5c
Commit-Ready: Matthias Kaehlcke <>
Tested-by: Matthias Kaehlcke <>
Reviewed-by: Sonny Rao <>
1 file changed