~ubuntu-branches/ubuntu/precise/linux-ti-omap4/precise

« back to all changes in this revision

Viewing changes to arch/arm/mach-mx3/mach-bug.c

  • Committer: Bazaar Package Importer
  • Author(s): Paolo Pisati
  • Date: 2011-06-29 15:23:51 UTC
  • mfrom: (26.1.1 natty-proposed)
  • Revision ID: james.westby@ubuntu.com-20110629152351-xs96tm303d95rpbk
Tags: 3.0.0-1200.2
* Rebased against 3.0.0-6.7
* BSP from TI based on 3.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
2
 
 * Copyright (C) 2000 Deep Blue Solutions Ltd
3
 
 * Copyright (C) 2002 Shane Nay (shane@minirl.com)
4
 
 * Copyright 2005-2007 Freescale Semiconductor, Inc. All Rights Reserved.
5
 
 * Copyright 2011 Denis 'GNUtoo' Carikli <GNUtoo@no-log.org>
6
 
 *
7
 
 * This program is free software; you can redistribute it and/or modify
8
 
 * it under the terms of the GNU General Public License as published by
9
 
 * the Free Software Foundation; either version 2 of the License, or
10
 
 * (at your option) any later version.
11
 
 *
12
 
 * This program is distributed in the hope that it will be useful,
13
 
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14
 
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15
 
 * GNU General Public License for more details.
16
 
 */
17
 
 
18
 
#include <linux/kernel.h>
19
 
#include <linux/init.h>
20
 
#include <linux/platform_device.h>
21
 
 
22
 
#include <mach/iomux-mx3.h>
23
 
#include <mach/imx-uart.h>
24
 
#include <mach/hardware.h>
25
 
#include <mach/common.h>
26
 
 
27
 
#include <asm/mach/time.h>
28
 
#include <asm/mach/arch.h>
29
 
#include <asm/mach-types.h>
30
 
 
31
 
#include "devices-imx31.h"
32
 
 
33
 
static const struct imxuart_platform_data uart_pdata __initconst = {
34
 
        .flags = IMXUART_HAVE_RTSCTS,
35
 
};
36
 
 
37
 
static const unsigned int bug_pins[] __initconst = {
38
 
        MX31_PIN_PC_RST__CTS5,
39
 
        MX31_PIN_PC_VS2__RTS5,
40
 
        MX31_PIN_PC_BVD2__TXD5,
41
 
        MX31_PIN_PC_BVD1__RXD5,
42
 
};
43
 
 
44
 
static void __init bug_board_init(void)
45
 
{
46
 
        mxc_iomux_setup_multiple_pins(bug_pins,
47
 
                                      ARRAY_SIZE(bug_pins), "uart-4");
48
 
        imx31_add_imx_uart4(&uart_pdata);
49
 
}
50
 
 
51
 
static void __init bug_timer_init(void)
52
 
{
53
 
        mx31_clocks_init(26000000);
54
 
}
55
 
 
56
 
static struct sys_timer bug_timer = {
57
 
        .init = bug_timer_init,
58
 
};
59
 
 
60
 
MACHINE_START(BUG, "BugLabs BUGBase")
61
 
        .map_io = mx31_map_io,
62
 
        .init_early = imx31_init_early,
63
 
        .init_irq = mx31_init_irq,
64
 
        .timer = &bug_timer,
65
 
        .init_machine = bug_board_init,
66
 
MACHINE_END