x86: consolidate header guards
[GitHub/mt8127/android_kernel_alcatel_ttab.git] / include / asm-x86 / mc146818rtc.h
index cdd9f965835a66d35b3a1b8d56e43f2dd715eb83..a995f33176cd026f60f21c18008811f9a5a996a4 100644 (file)
@@ -1,8 +1,8 @@
 /*
  * Machine dependent access functions for RTC registers.
  */
-#ifndef _ASM_MC146818RTC_H
-#define _ASM_MC146818RTC_H
+#ifndef ASM_X86__MC146818RTC_H
+#define ASM_X86__MC146818RTC_H
 
 #include <asm/io.h>
 #include <asm/system.h>
@@ -42,7 +42,7 @@ extern volatile unsigned long cmos_lock;
 static inline void lock_cmos(unsigned char reg)
 {
        unsigned long new;
-       new = ((smp_processor_id()+1) << 8) | reg;
+       new = ((smp_processor_id() + 1) << 8) | reg;
        for (;;) {
                if (cmos_lock) {
                        cpu_relax();
@@ -57,22 +57,26 @@ static inline void unlock_cmos(void)
 {
        cmos_lock = 0;
 }
+
 static inline int do_i_have_lock_cmos(void)
 {
-       return (cmos_lock >> 8) == (smp_processor_id()+1);
+       return (cmos_lock >> 8) == (smp_processor_id() + 1);
 }
+
 static inline unsigned char current_lock_cmos_reg(void)
 {
        return cmos_lock & 0xff;
 }
-#define lock_cmos_prefix(reg) \
+
+#define lock_cmos_prefix(reg)                  \
        do {                                    \
                unsigned long cmos_flags;       \
                local_irq_save(cmos_flags);     \
                lock_cmos(reg)
-#define lock_cmos_suffix(reg) \
-               unlock_cmos();                  \
-               local_irq_restore(cmos_flags);  \
+
+#define lock_cmos_suffix(reg)                  \
+       unlock_cmos();                          \
+       local_irq_restore(cmos_flags);          \
        } while (0)
 #else
 #define lock_cmos_prefix(reg) do {} while (0)
@@ -97,4 +101,4 @@ extern unsigned long mach_get_cmos_time(void);
 
 #define RTC_IRQ 8
 
-#endif /* _ASM_MC146818RTC_H */
+#endif /* ASM_X86__MC146818RTC_H */