blob: 2b4b085e8f2195e95949e07dfd4e6c51767065f1 [file] [log] [blame]
David Brazdil0f672f62019-12-10 10:32:29 +00001/* SPDX-License-Identifier: GPL-2.0
2 *
Andrew Scullb4b6d4a2019-01-02 15:54:55 +00003 * include/asm-sh/machvec.h
4 *
5 * Copyright 2000 Stuart Menefy (stuart.menefy@st.com)
Andrew Scullb4b6d4a2019-01-02 15:54:55 +00006 */
7
8#ifndef _ASM_SH_MACHVEC_H
9#define _ASM_SH_MACHVEC_H
10
11#include <linux/types.h>
12#include <linux/time.h>
13#include <generated/machtypes.h>
14
15struct sh_machine_vector {
16 void (*mv_setup)(char **cmdline_p);
17 const char *mv_name;
18
19 int (*mv_irq_demux)(int irq);
20 void (*mv_init_irq)(void);
21
22#ifdef CONFIG_HAS_IOPORT_MAP
23 void __iomem *(*mv_ioport_map)(unsigned long port, unsigned int size);
24 void (*mv_ioport_unmap)(void __iomem *);
25#endif
26
27 int (*mv_clk_init)(void);
28 int (*mv_mode_pins)(void);
29
30 void (*mv_mem_init)(void);
31 void (*mv_mem_reserve)(void);
32};
33
34extern struct sh_machine_vector sh_mv;
35
36#define get_system_type() sh_mv.mv_name
37
38#define __initmv \
Olivier Deprez157378f2022-04-04 15:47:50 +020039 __used __section(".machvec.init")
Andrew Scullb4b6d4a2019-01-02 15:54:55 +000040
41#endif /* _ASM_SH_MACHVEC_H */