lkml.org 
[lkml]   [2011]   [Jun]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    Subject[tip:timers/cleanup] i8253: Cleanup outb/inb magic
    Commit-ID:  51928d12a6e07a1bd7b38d8b151a50cb24175dd3
    Gitweb: http://git.kernel.org/tip/51928d12a6e07a1bd7b38d8b151a50cb24175dd3
    Author: Thomas Gleixner <tglx@linutronix.de>
    AuthorDate: Thu, 9 Jun 2011 13:08:30 +0000
    Committer: Thomas Gleixner <tglx@linutronix.de>
    CommitDate: Fri, 24 Jun 2011 16:22:55 +0200

    i8253: Cleanup outb/inb magic

    Remove the hysterical outb/inb_pit defines and use outb_p/inb_p in the
    code.

    Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
    Cc: Russell King <linux@arm.linux.org.uk>
    Cc: Ralf Baechle <ralf@linux-mips.org>
    Cc: John Stultz <john.stultz@linaro.org>
    Link: http://lkml.kernel.org/r/20110609130622.348437125@linutronix.de
    ---
    arch/x86/kernel/apm_32.c | 6 +++---
    include/linux/i8253.h | 3 ---
    2 files changed, 3 insertions(+), 6 deletions(-)

    diff --git a/arch/x86/kernel/apm_32.c b/arch/x86/kernel/apm_32.c
    index a30740e..0371c48 100644
    --- a/arch/x86/kernel/apm_32.c
    +++ b/arch/x86/kernel/apm_32.c
    @@ -1220,11 +1220,11 @@ static void reinit_timer(void)

    raw_spin_lock_irqsave(&i8253_lock, flags);
    /* set the clock to HZ */
    - outb_pit(0x34, PIT_MODE); /* binary, mode 2, LSB/MSB, ch 0 */
    + outb_p(0x34, PIT_MODE); /* binary, mode 2, LSB/MSB, ch 0 */
    udelay(10);
    - outb_pit(LATCH & 0xff, PIT_CH0); /* LSB */
    + outb_p(LATCH & 0xff, PIT_CH0); /* LSB */
    udelay(10);
    - outb_pit(LATCH >> 8, PIT_CH0); /* MSB */
    + outb_p(LATCH >> 8, PIT_CH0); /* MSB */
    udelay(10);
    raw_spin_unlock_irqrestore(&i8253_lock, flags);
    #endif
    diff --git a/include/linux/i8253.h b/include/linux/i8253.h
    index 76039c8..0770fc5 100644
    --- a/include/linux/i8253.h
    +++ b/include/linux/i8253.h
    @@ -20,9 +20,6 @@

    #define PIT_LATCH ((PIT_TICK_RATE + HZ/2) / HZ)

    -#define inb_pit inb_p
    -#define outb_pit outb_p
    -
    extern raw_spinlock_t i8253_lock;

    extern void setup_pit_timer(void);

    \
     
     \ /
      Last update: 2011-06-24 16:41    [W:0.032 / U:86.540 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site