2 * iq81340mc board support
3 * Copyright (c) 2005-2006, Intel Corporation.
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms and conditions of the GNU General Public License,
7 * version 2, as published by the Free Software Foundation.
9 * This program is distributed in the hope it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14 * You should have received a copy of the GNU General Public License along with
15 * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
16 * Place - Suite 330, Boston, MA 02111-1307 USA.
19 #include <linux/pci.h>
21 #include <asm/hardware.h>
23 #include <asm/mach/pci.h>
24 #include <asm/mach-types.h>
25 #include <asm/mach/arch.h>
26 #include <asm/arch/pci.h>
27 #include <asm/mach/time.h>
28 #include <asm/arch/time.h>
30 extern int init_atu; /* Flag to select which ATU(s) to initialize / disable */
33 iq81340mc_pcix_map_irq(struct pci_dev *dev, u8 idsel, u8 pin)
38 case 1: return ATUX_INTB;
39 case 2: return ATUX_INTC;
40 case 3: return ATUX_INTD;
41 case 4: return ATUX_INTA;
46 case 1: return ATUX_INTC;
47 case 2: return ATUX_INTD;
48 case 3: return ATUX_INTC;
49 case 4: return ATUX_INTD;
56 static struct hw_pci iq81340mc_pci __initdata = {
57 .swizzle = pci_std_swizzle,
59 .setup = iop13xx_pci_setup,
60 .map_irq = iq81340mc_pcix_map_irq,
61 .scan = iop13xx_scan_bus,
62 .preinit = iop13xx_pci_init,
65 static int __init iq81340mc_pci_init(void)
67 iop13xx_atu_select(&iq81340mc_pci);
68 pci_common_init(&iq81340mc_pci);
69 iop13xx_map_pci_memory();
74 static void __init iq81340mc_init(void)
76 iop13xx_platform_init();
80 static void __init iq81340mc_timer_init(void)
82 iop_init_time(400000000);
85 static struct sys_timer iq81340mc_timer = {
86 .init = iq81340mc_timer_init,
87 .offset = iop_gettimeoffset,
90 MACHINE_START(IQ81340MC, "Intel IQ81340MC")
91 /* Maintainer: Dan Williams <dan.j.williams@intel.com> */
92 .phys_io = IOP13XX_PMMR_PHYS_MEM_BASE,
93 .io_pg_offst = (IOP13XX_PMMR_VIRT_MEM_BASE >> 18) & 0xfffc,
94 .boot_params = 0x00000100,
95 .map_io = iop13xx_map_io,
96 .init_irq = iop13xx_init_irq,
97 .timer = &iq81340mc_timer,
98 .init_machine = iq81340mc_init,