mirror of
https://github.com/torvalds/linux.git
synced 2024-11-14 16:12:02 +00:00
6bb27d7349
Now that the only field in struct sys_timer is .init, delete the struct, and replace the machine descriptor .timer field with the initialization function itself. This will enable moving timer drivers into drivers/clocksource without having to place a public prototype of each struct sys_timer object into include/linux; the intent is to create a single of_clocksource_init() function that determines which timer driver to initialize by scanning the device dtree, much like the proposed irqchip_init() at: http://www.spinics.net/lists/arm-kernel/msg203686.html Includes mach-omap2 fixes from Igor Grinberg. Tested-by: Robert Jarzmik <robert.jarzmik@free.fr> Signed-off-by: Stephen Warren <swarren@nvidia.com>
89 lines
2.1 KiB
C
89 lines
2.1 KiB
C
/* linux/arch/arm/mach-msm/board-mahimahi.c
|
|
*
|
|
* Copyright (C) 2009 Google, Inc.
|
|
* Copyright (C) 2009 HTC Corporation.
|
|
* Author: Dima Zavin <dima@android.com>
|
|
*
|
|
* This software is licensed under the terms of the GNU General Public
|
|
* License version 2, as published by the Free Software Foundation, and
|
|
* may be copied, distributed, and modified under those terms.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
*/
|
|
|
|
#include <linux/delay.h>
|
|
#include <linux/gpio.h>
|
|
#include <linux/init.h>
|
|
#include <linux/input.h>
|
|
#include <linux/io.h>
|
|
#include <linux/kernel.h>
|
|
#include <linux/platform_device.h>
|
|
|
|
#include <asm/mach-types.h>
|
|
#include <asm/mach/arch.h>
|
|
#include <asm/mach/map.h>
|
|
#include <asm/setup.h>
|
|
|
|
#include <mach/board.h>
|
|
#include <mach/hardware.h>
|
|
|
|
#include "board-mahimahi.h"
|
|
#include "devices.h"
|
|
#include "proc_comm.h"
|
|
|
|
static uint debug_uart;
|
|
|
|
module_param_named(debug_uart, debug_uart, uint, 0);
|
|
|
|
static struct platform_device *devices[] __initdata = {
|
|
#if !defined(CONFIG_MSM_SERIAL_DEBUGGER)
|
|
&msm_device_uart1,
|
|
#endif
|
|
&msm_device_uart_dm1,
|
|
&msm_device_nand,
|
|
};
|
|
|
|
static void __init mahimahi_init(void)
|
|
{
|
|
platform_add_devices(devices, ARRAY_SIZE(devices));
|
|
}
|
|
|
|
static void __init mahimahi_fixup(struct tag *tags, char **cmdline,
|
|
struct meminfo *mi)
|
|
{
|
|
mi->nr_banks = 2;
|
|
mi->bank[0].start = PHYS_OFFSET;
|
|
mi->bank[0].node = PHYS_TO_NID(PHYS_OFFSET);
|
|
mi->bank[0].size = (219*1024*1024);
|
|
mi->bank[1].start = MSM_HIGHMEM_BASE;
|
|
mi->bank[1].node = PHYS_TO_NID(MSM_HIGHMEM_BASE);
|
|
mi->bank[1].size = MSM_HIGHMEM_SIZE;
|
|
}
|
|
|
|
static void __init mahimahi_map_io(void)
|
|
{
|
|
msm_map_common_io();
|
|
msm_clock_init();
|
|
}
|
|
|
|
static void __init mahimahi_init_late(void)
|
|
{
|
|
smd_debugfs_init();
|
|
}
|
|
|
|
void msm_timer_init(void);
|
|
|
|
MACHINE_START(MAHIMAHI, "mahimahi")
|
|
.atag_offset = 0x100,
|
|
.fixup = mahimahi_fixup,
|
|
.map_io = mahimahi_map_io,
|
|
.init_irq = msm_init_irq,
|
|
.init_machine = mahimahi_init,
|
|
.init_late = mahimahi_init_late,
|
|
.init_time = msm_timer_init,
|
|
MACHINE_END
|