x86/mm: Add TLB purge to free pmd/pte page interfaces
[linux/fpc-iii.git] / arch / arc / include / asm / mach_desc.h
blobc28e6c347b4900217ad48053c69679bb3da8b607
1 /*
2 * Copyright (C) 2012 Synopsys, Inc. (www.synopsys.com)
4 * based on METAG mach/arch.h (which in turn was based on ARM)
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
9 */
11 #ifndef _ASM_ARC_MACH_DESC_H_
12 #define _ASM_ARC_MACH_DESC_H_
14 /**
15 * struct machine_desc - Board specific callbacks, called from ARC common code
16 * Provided by each ARC board using MACHINE_START()/MACHINE_END(), so
17 * a multi-platform kernel builds with array of such descriptors.
18 * We extend the early DT scan to also match the DT's "compatible" string
19 * against the @dt_compat of all such descriptors, and one with highest
20 * "DT score" is selected as global @machine_desc.
22 * @name: Board/SoC name
23 * @dt_compat: Array of device tree 'compatible' strings
24 * (XXX: although only 1st entry is looked at)
25 * @init_early: Very early callback [called from setup_arch()]
26 * @init_per_cpu: for each CPU as it is coming up (SMP as well as UP)
27 * [(M):init_IRQ(), (o):start_kernel_secondary()]
28 * @init_machine: arch initcall level callback (e.g. populate static
29 * platform devices or parse Devicetree)
30 * @init_late: Late initcall level callback
33 struct machine_desc {
34 const char *name;
35 const char **dt_compat;
36 void (*init_early)(void);
37 #ifdef CONFIG_SMP
38 void (*init_per_cpu)(unsigned int);
39 #endif
40 void (*init_machine)(void);
41 void (*init_late)(void);
46 * Current machine - only accessible during boot.
48 extern const struct machine_desc *machine_desc;
51 * Machine type table - also only accessible during boot
53 extern const struct machine_desc __arch_info_begin[], __arch_info_end[];
56 * Set of macros to define architecture features.
57 * This is built into a table by the linker.
59 #define MACHINE_START(_type, _name) \
60 static const struct machine_desc __mach_desc_##_type \
61 __used \
62 __attribute__((__section__(".arch.info.init"))) = { \
63 .name = _name,
65 #define MACHINE_END \
68 extern const struct machine_desc *setup_machine_fdt(void *dt);
70 #endif