blob: d3324e4f372ec9d544f7c35a19d70f1fb679fee1 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/*
2 * include/asm-sh/machvec.h
3 *
4 * Copyright 2000 Stuart Menefy (stuart.menefy@st.com)
5 *
6 * May be copied or modified under the terms of the GNU General Public
7 * License. See linux/COPYING for more information.
8 */
9
10#ifndef _ASM_SH_MACHVEC_H
Paul Mundt2c7834a2006-09-27 18:17:31 +090011#define _ASM_SH_MACHVEC_H
Linus Torvalds1da177e2005-04-16 15:20:36 -070012
Linus Torvalds1da177e2005-04-16 15:20:36 -070013#include <linux/types.h>
14#include <linux/time.h>
Sam Ravnborg3252b112009-10-17 22:20:22 +020015#include <generated/machtypes.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -070016
Paul Mundtb66c1a32006-01-16 22:14:15 -080017struct sh_machine_vector {
Paul Mundt2c7834a2006-09-27 18:17:31 +090018 void (*mv_setup)(char **cmdline_p);
19 const char *mv_name;
Linus Torvalds1da177e2005-04-16 15:20:36 -070020
Paul Mundt86e4dd52010-05-25 20:06:13 +090021 int (*mv_irq_demux)(int irq);
22 void (*mv_init_irq)(void);
23
Uwe Kleine-Königce816fa2014-04-07 15:39:19 -070024#ifdef CONFIG_HAS_IOPORT_MAP
Paul Mundtb66c1a32006-01-16 22:14:15 -080025 void __iomem *(*mv_ioport_map)(unsigned long port, unsigned int size);
26 void (*mv_ioport_unmap)(void __iomem *);
Paul Mundt86e4dd52010-05-25 20:06:13 +090027#endif
Paul Mundt253b0882009-05-13 17:38:11 +090028
29 int (*mv_clk_init)(void);
Magnus Dammeb9b9b52009-05-28 11:51:51 +000030 int (*mv_mode_pins)(void);
Paul Mundt19d8f842010-05-10 15:39:05 +090031
32 void (*mv_mem_init)(void);
Paul Mundt2f599862011-01-07 15:19:56 +090033 void (*mv_mem_reserve)(void);
Linus Torvalds1da177e2005-04-16 15:20:36 -070034};
35
36extern struct sh_machine_vector sh_mv;
37
Paul Mundt2c7834a2006-09-27 18:17:31 +090038#define get_system_type() sh_mv.mv_name
39
Paul Mundt82f81f42007-05-15 15:19:34 +090040#define __initmv \
Adrian Bunk3ff6eec2008-01-24 22:16:20 +010041 __used __section(.machvec.init)
Paul Mundt82f81f42007-05-15 15:19:34 +090042
Linus Torvalds1da177e2005-04-16 15:20:36 -070043#endif /* _ASM_SH_MACHVEC_H */