You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
This commit is contained in:
@@ -12,7 +12,7 @@ Each key is represented as a sub-node of "allwinner,sun4i-a10-lradc-keys":
|
|||||||
Required subnode-properties:
|
Required subnode-properties:
|
||||||
- label: Descriptive name of the key.
|
- label: Descriptive name of the key.
|
||||||
- linux,code: Keycode to emit.
|
- linux,code: Keycode to emit.
|
||||||
- channel: Channel this key is attached to, mut be 0 or 1.
|
- channel: Channel this key is attached to, must be 0 or 1.
|
||||||
- voltage: Voltage in µV at lradc input when this key is pressed.
|
- voltage: Voltage in µV at lradc input when this key is pressed.
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
|
|||||||
@@ -6,7 +6,9 @@ used for what purposes, but which don't use an on-flash partition table such
|
|||||||
as RedBoot.
|
as RedBoot.
|
||||||
|
|
||||||
The partition table should be a subnode of the mtd node and should be named
|
The partition table should be a subnode of the mtd node and should be named
|
||||||
'partitions'. Partitions are defined in subnodes of the partitions node.
|
'partitions'. This node should have the following property:
|
||||||
|
- compatible : (required) must be "fixed-partitions"
|
||||||
|
Partitions are then defined in subnodes of the partitions node.
|
||||||
|
|
||||||
For backwards compatibility partitions as direct subnodes of the mtd device are
|
For backwards compatibility partitions as direct subnodes of the mtd device are
|
||||||
supported. This use is discouraged.
|
supported. This use is discouraged.
|
||||||
@@ -36,6 +38,7 @@ Examples:
|
|||||||
|
|
||||||
flash@0 {
|
flash@0 {
|
||||||
partitions {
|
partitions {
|
||||||
|
compatible = "fixed-partitions";
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <1>;
|
#size-cells = <1>;
|
||||||
|
|
||||||
@@ -53,6 +56,7 @@ flash@0 {
|
|||||||
|
|
||||||
flash@1 {
|
flash@1 {
|
||||||
partitions {
|
partitions {
|
||||||
|
compatible = "fixed-partitions";
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <2>;
|
#size-cells = <2>;
|
||||||
|
|
||||||
@@ -66,6 +70,7 @@ flash@1 {
|
|||||||
|
|
||||||
flash@2 {
|
flash@2 {
|
||||||
partitions {
|
partitions {
|
||||||
|
compatible = "fixed-partitions";
|
||||||
#address-cells = <2>;
|
#address-cells = <2>;
|
||||||
#size-cells = <2>;
|
#size-cells = <2>;
|
||||||
|
|
||||||
|
|||||||
@@ -40,18 +40,18 @@ Optional properties:
|
|||||||
|
|
||||||
Slave Properties:
|
Slave Properties:
|
||||||
Required properties:
|
Required properties:
|
||||||
- phy_id : Specifies slave phy id
|
|
||||||
- phy-mode : See ethernet.txt file in the same directory
|
- phy-mode : See ethernet.txt file in the same directory
|
||||||
|
|
||||||
Optional properties:
|
Optional properties:
|
||||||
- dual_emac_res_vlan : Specifies VID to be used to segregate the ports
|
- dual_emac_res_vlan : Specifies VID to be used to segregate the ports
|
||||||
- mac-address : See ethernet.txt file in the same directory
|
- mac-address : See ethernet.txt file in the same directory
|
||||||
|
- phy_id : Specifies slave phy id
|
||||||
- phy-handle : See ethernet.txt file in the same directory
|
- phy-handle : See ethernet.txt file in the same directory
|
||||||
|
|
||||||
Slave sub-nodes:
|
Slave sub-nodes:
|
||||||
- fixed-link : See fixed-link.txt file in the same directory
|
- fixed-link : See fixed-link.txt file in the same directory
|
||||||
Either the properties phy_id and phy-mode,
|
Either the property phy_id, or the sub-node
|
||||||
or the sub-node fixed-link can be specified
|
fixed-link can be specified
|
||||||
|
|
||||||
Note: "ti,hwmods" field is used to fetch the base address and irq
|
Note: "ti,hwmods" field is used to fetch the base address and irq
|
||||||
resources from TI, omap hwmod data base during device registration.
|
resources from TI, omap hwmod data base during device registration.
|
||||||
|
|||||||
@@ -8403,6 +8403,14 @@ L: linux-samsung-soc@vger.kernel.org (moderated for non-subscribers)
|
|||||||
S: Maintained
|
S: Maintained
|
||||||
F: drivers/pinctrl/samsung/
|
F: drivers/pinctrl/samsung/
|
||||||
|
|
||||||
|
PIN CONTROLLER - SINGLE
|
||||||
|
M: Tony Lindgren <tony@atomide.com>
|
||||||
|
M: Haojian Zhuang <haojian.zhuang@linaro.org>
|
||||||
|
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||||
|
L: linux-omap@vger.kernel.org
|
||||||
|
S: Maintained
|
||||||
|
F: drivers/pinctrl/pinctrl-single.c
|
||||||
|
|
||||||
PIN CONTROLLER - ST SPEAR
|
PIN CONTROLLER - ST SPEAR
|
||||||
M: Viresh Kumar <vireshk@kernel.org>
|
M: Viresh Kumar <vireshk@kernel.org>
|
||||||
L: spear-devel@list.st.com
|
L: spear-devel@list.st.com
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
VERSION = 4
|
VERSION = 4
|
||||||
PATCHLEVEL = 4
|
PATCHLEVEL = 4
|
||||||
SUBLEVEL = 0
|
SUBLEVEL = 0
|
||||||
EXTRAVERSION = -rc5
|
EXTRAVERSION = -rc7
|
||||||
NAME = Blurry Fish Butt
|
NAME = Blurry Fish Butt
|
||||||
|
|
||||||
# *DOCUMENTATION*
|
# *DOCUMENTATION*
|
||||||
|
|||||||
@@ -445,6 +445,7 @@ config LINUX_LINK_BASE
|
|||||||
However some customers have peripherals mapped at this addr, so
|
However some customers have peripherals mapped at this addr, so
|
||||||
Linux needs to be scooted a bit.
|
Linux needs to be scooted a bit.
|
||||||
If you don't know what the above means, leave this setting alone.
|
If you don't know what the above means, leave this setting alone.
|
||||||
|
This needs to match memory start address specified in Device Tree
|
||||||
|
|
||||||
config HIGHMEM
|
config HIGHMEM
|
||||||
bool "High Memory Support"
|
bool "High Memory Support"
|
||||||
|
|||||||
+1
-1
@@ -81,7 +81,7 @@ endif
|
|||||||
LIBGCC := $(shell $(CC) $(cflags-y) --print-libgcc-file-name)
|
LIBGCC := $(shell $(CC) $(cflags-y) --print-libgcc-file-name)
|
||||||
|
|
||||||
# Modules with short calls might break for calls into builtin-kernel
|
# Modules with short calls might break for calls into builtin-kernel
|
||||||
KBUILD_CFLAGS_MODULE += -mlong-calls
|
KBUILD_CFLAGS_MODULE += -mlong-calls -mno-millicode
|
||||||
|
|
||||||
# Finally dump eveything into kernel build system
|
# Finally dump eveything into kernel build system
|
||||||
KBUILD_CFLAGS += $(cflags-y)
|
KBUILD_CFLAGS += $(cflags-y)
|
||||||
|
|||||||
@@ -46,6 +46,7 @@
|
|||||||
snps,pbl = < 32 >;
|
snps,pbl = < 32 >;
|
||||||
clocks = <&apbclk>;
|
clocks = <&apbclk>;
|
||||||
clock-names = "stmmaceth";
|
clock-names = "stmmaceth";
|
||||||
|
max-speed = <100>;
|
||||||
};
|
};
|
||||||
|
|
||||||
ehci@0x40000 {
|
ehci@0x40000 {
|
||||||
|
|||||||
@@ -17,7 +17,8 @@
|
|||||||
|
|
||||||
memory {
|
memory {
|
||||||
device_type = "memory";
|
device_type = "memory";
|
||||||
reg = <0x0 0x80000000 0x0 0x40000000 /* 1 GB low mem */
|
/* CONFIG_LINUX_LINK_BASE needs to match low mem start */
|
||||||
|
reg = <0x0 0x80000000 0x0 0x20000000 /* 512 MB low mem */
|
||||||
0x1 0x00000000 0x0 0x40000000>; /* 1 GB highmem */
|
0x1 0x00000000 0x0 0x40000000>; /* 1 GB highmem */
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -62,9 +62,7 @@ extern int ioc_exists;
|
|||||||
#define ARC_REG_IC_IVIC 0x10
|
#define ARC_REG_IC_IVIC 0x10
|
||||||
#define ARC_REG_IC_CTRL 0x11
|
#define ARC_REG_IC_CTRL 0x11
|
||||||
#define ARC_REG_IC_IVIL 0x19
|
#define ARC_REG_IC_IVIL 0x19
|
||||||
#if defined(CONFIG_ARC_MMU_V3) || defined(CONFIG_ARC_MMU_V4)
|
|
||||||
#define ARC_REG_IC_PTAG 0x1E
|
#define ARC_REG_IC_PTAG 0x1E
|
||||||
#endif
|
|
||||||
#define ARC_REG_IC_PTAG_HI 0x1F
|
#define ARC_REG_IC_PTAG_HI 0x1F
|
||||||
|
|
||||||
/* Bit val in IC_CTRL */
|
/* Bit val in IC_CTRL */
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
* @dt_compat: Array of device tree 'compatible' strings
|
* @dt_compat: Array of device tree 'compatible' strings
|
||||||
* (XXX: although only 1st entry is looked at)
|
* (XXX: although only 1st entry is looked at)
|
||||||
* @init_early: Very early callback [called from setup_arch()]
|
* @init_early: Very early callback [called from setup_arch()]
|
||||||
* @init_cpu_smp: for each CPU as it is coming up (SMP as well as UP)
|
* @init_per_cpu: for each CPU as it is coming up (SMP as well as UP)
|
||||||
* [(M):init_IRQ(), (o):start_kernel_secondary()]
|
* [(M):init_IRQ(), (o):start_kernel_secondary()]
|
||||||
* @init_machine: arch initcall level callback (e.g. populate static
|
* @init_machine: arch initcall level callback (e.g. populate static
|
||||||
* platform devices or parse Devicetree)
|
* platform devices or parse Devicetree)
|
||||||
@@ -35,7 +35,7 @@ struct machine_desc {
|
|||||||
const char **dt_compat;
|
const char **dt_compat;
|
||||||
void (*init_early)(void);
|
void (*init_early)(void);
|
||||||
#ifdef CONFIG_SMP
|
#ifdef CONFIG_SMP
|
||||||
void (*init_cpu_smp)(unsigned int);
|
void (*init_per_cpu)(unsigned int);
|
||||||
#endif
|
#endif
|
||||||
void (*init_machine)(void);
|
void (*init_machine)(void);
|
||||||
void (*init_late)(void);
|
void (*init_late)(void);
|
||||||
|
|||||||
@@ -48,7 +48,7 @@ extern int smp_ipi_irq_setup(int cpu, int irq);
|
|||||||
* @init_early_smp: A SMP specific h/w block can init itself
|
* @init_early_smp: A SMP specific h/w block can init itself
|
||||||
* Could be common across platforms so not covered by
|
* Could be common across platforms so not covered by
|
||||||
* mach_desc->init_early()
|
* mach_desc->init_early()
|
||||||
* @init_irq_cpu: Called for each core so SMP h/w block driver can do
|
* @init_per_cpu: Called for each core so SMP h/w block driver can do
|
||||||
* any needed setup per cpu (e.g. IPI request)
|
* any needed setup per cpu (e.g. IPI request)
|
||||||
* @cpu_kick: For Master to kickstart a cpu (optionally at a PC)
|
* @cpu_kick: For Master to kickstart a cpu (optionally at a PC)
|
||||||
* @ipi_send: To send IPI to a @cpu
|
* @ipi_send: To send IPI to a @cpu
|
||||||
@@ -57,7 +57,7 @@ extern int smp_ipi_irq_setup(int cpu, int irq);
|
|||||||
struct plat_smp_ops {
|
struct plat_smp_ops {
|
||||||
const char *info;
|
const char *info;
|
||||||
void (*init_early_smp)(void);
|
void (*init_early_smp)(void);
|
||||||
void (*init_irq_cpu)(int cpu);
|
void (*init_per_cpu)(int cpu);
|
||||||
void (*cpu_kick)(int cpu, unsigned long pc);
|
void (*cpu_kick)(int cpu, unsigned long pc);
|
||||||
void (*ipi_send)(int cpu);
|
void (*ipi_send)(int cpu);
|
||||||
void (*ipi_clear)(int irq);
|
void (*ipi_clear)(int irq);
|
||||||
|
|||||||
@@ -112,7 +112,6 @@ struct unwind_frame_info {
|
|||||||
|
|
||||||
extern int arc_unwind(struct unwind_frame_info *frame);
|
extern int arc_unwind(struct unwind_frame_info *frame);
|
||||||
extern void arc_unwind_init(void);
|
extern void arc_unwind_init(void);
|
||||||
extern void arc_unwind_setup(void);
|
|
||||||
extern void *unwind_add_table(struct module *module, const void *table_start,
|
extern void *unwind_add_table(struct module *module, const void *table_start,
|
||||||
unsigned long table_size);
|
unsigned long table_size);
|
||||||
extern void unwind_remove_table(void *handle, int init_only);
|
extern void unwind_remove_table(void *handle, int init_only);
|
||||||
@@ -152,9 +151,6 @@ static inline void arc_unwind_init(void)
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void arc_unwind_setup(void)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
#define unwind_add_table(a, b, c)
|
#define unwind_add_table(a, b, c)
|
||||||
#define unwind_remove_table(a, b)
|
#define unwind_remove_table(a, b)
|
||||||
|
|
||||||
|
|||||||
@@ -106,10 +106,21 @@ static struct irq_chip arcv2_irq_chip = {
|
|||||||
static int arcv2_irq_map(struct irq_domain *d, unsigned int irq,
|
static int arcv2_irq_map(struct irq_domain *d, unsigned int irq,
|
||||||
irq_hw_number_t hw)
|
irq_hw_number_t hw)
|
||||||
{
|
{
|
||||||
if (irq == TIMER0_IRQ || irq == IPI_IRQ)
|
/*
|
||||||
|
* core intc IRQs [16, 23]:
|
||||||
|
* Statically assigned always private-per-core (Timers, WDT, IPI, PCT)
|
||||||
|
*/
|
||||||
|
if (hw < 24) {
|
||||||
|
/*
|
||||||
|
* A subsequent request_percpu_irq() fails if percpu_devid is
|
||||||
|
* not set. That in turns sets NOAUTOEN, meaning each core needs
|
||||||
|
* to call enable_percpu_irq()
|
||||||
|
*/
|
||||||
|
irq_set_percpu_devid(irq);
|
||||||
irq_set_chip_and_handler(irq, &arcv2_irq_chip, handle_percpu_irq);
|
irq_set_chip_and_handler(irq, &arcv2_irq_chip, handle_percpu_irq);
|
||||||
else
|
} else {
|
||||||
irq_set_chip_and_handler(irq, &arcv2_irq_chip, handle_level_irq);
|
irq_set_chip_and_handler(irq, &arcv2_irq_chip, handle_level_irq);
|
||||||
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
+24
-9
@@ -29,11 +29,11 @@ void __init init_IRQ(void)
|
|||||||
|
|
||||||
#ifdef CONFIG_SMP
|
#ifdef CONFIG_SMP
|
||||||
/* a SMP H/w block could do IPI IRQ request here */
|
/* a SMP H/w block could do IPI IRQ request here */
|
||||||
if (plat_smp_ops.init_irq_cpu)
|
if (plat_smp_ops.init_per_cpu)
|
||||||
plat_smp_ops.init_irq_cpu(smp_processor_id());
|
plat_smp_ops.init_per_cpu(smp_processor_id());
|
||||||
|
|
||||||
if (machine_desc->init_cpu_smp)
|
if (machine_desc->init_per_cpu)
|
||||||
machine_desc->init_cpu_smp(smp_processor_id());
|
machine_desc->init_per_cpu(smp_processor_id());
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -51,6 +51,18 @@ void arch_do_IRQ(unsigned int irq, struct pt_regs *regs)
|
|||||||
set_irq_regs(old_regs);
|
set_irq_regs(old_regs);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* API called for requesting percpu interrupts - called by each CPU
|
||||||
|
* - For boot CPU, actually request the IRQ with genirq core + enables
|
||||||
|
* - For subsequent callers only enable called locally
|
||||||
|
*
|
||||||
|
* Relies on being called by boot cpu first (i.e. request called ahead) of
|
||||||
|
* any enable as expected by genirq. Hence Suitable only for TIMER, IPI
|
||||||
|
* which are guaranteed to be setup on boot core first.
|
||||||
|
* Late probed peripherals such as perf can't use this as there no guarantee
|
||||||
|
* of being called on boot CPU first.
|
||||||
|
*/
|
||||||
|
|
||||||
void arc_request_percpu_irq(int irq, int cpu,
|
void arc_request_percpu_irq(int irq, int cpu,
|
||||||
irqreturn_t (*isr)(int irq, void *dev),
|
irqreturn_t (*isr)(int irq, void *dev),
|
||||||
const char *irq_nm,
|
const char *irq_nm,
|
||||||
@@ -60,14 +72,17 @@ void arc_request_percpu_irq(int irq, int cpu,
|
|||||||
if (!cpu) {
|
if (!cpu) {
|
||||||
int rc;
|
int rc;
|
||||||
|
|
||||||
|
#ifdef CONFIG_ISA_ARCOMPACT
|
||||||
/*
|
/*
|
||||||
* These 2 calls are essential to making percpu IRQ APIs work
|
* A subsequent request_percpu_irq() fails if percpu_devid is
|
||||||
* Ideally these details could be hidden in irq chip map function
|
* not set. That in turns sets NOAUTOEN, meaning each core needs
|
||||||
* but the issue is IPIs IRQs being static (non-DT) and platform
|
* to call enable_percpu_irq()
|
||||||
* specific, so we can't identify them there.
|
*
|
||||||
|
* For ARCv2, this is done in irq map function since we know
|
||||||
|
* which irqs are strictly per cpu
|
||||||
*/
|
*/
|
||||||
irq_set_percpu_devid(irq);
|
irq_set_percpu_devid(irq);
|
||||||
irq_modify_status(irq, IRQ_NOAUTOEN, 0); /* @irq, @clr, @set */
|
#endif
|
||||||
|
|
||||||
rc = request_percpu_irq(irq, isr, irq_nm, percpu_dev);
|
rc = request_percpu_irq(irq, isr, irq_nm, percpu_dev);
|
||||||
if (rc)
|
if (rc)
|
||||||
|
|||||||
@@ -132,7 +132,7 @@ static void mcip_probe_n_setup(void)
|
|||||||
struct plat_smp_ops plat_smp_ops = {
|
struct plat_smp_ops plat_smp_ops = {
|
||||||
.info = smp_cpuinfo_buf,
|
.info = smp_cpuinfo_buf,
|
||||||
.init_early_smp = mcip_probe_n_setup,
|
.init_early_smp = mcip_probe_n_setup,
|
||||||
.init_irq_cpu = mcip_setup_per_cpu,
|
.init_per_cpu = mcip_setup_per_cpu,
|
||||||
.ipi_send = mcip_ipi_send,
|
.ipi_send = mcip_ipi_send,
|
||||||
.ipi_clear = mcip_ipi_clear,
|
.ipi_clear = mcip_ipi_clear,
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -428,12 +428,11 @@ static irqreturn_t arc_pmu_intr(int irq, void *dev)
|
|||||||
|
|
||||||
#endif /* CONFIG_ISA_ARCV2 */
|
#endif /* CONFIG_ISA_ARCV2 */
|
||||||
|
|
||||||
void arc_cpu_pmu_irq_init(void)
|
static void arc_cpu_pmu_irq_init(void *data)
|
||||||
{
|
{
|
||||||
struct arc_pmu_cpu *pmu_cpu = this_cpu_ptr(&arc_pmu_cpu);
|
int irq = *(int *)data;
|
||||||
|
|
||||||
arc_request_percpu_irq(arc_pmu->irq, smp_processor_id(), arc_pmu_intr,
|
enable_percpu_irq(irq, IRQ_TYPE_NONE);
|
||||||
"ARC perf counters", pmu_cpu);
|
|
||||||
|
|
||||||
/* Clear all pending interrupt flags */
|
/* Clear all pending interrupt flags */
|
||||||
write_aux_reg(ARC_REG_PCT_INT_ACT, 0xffffffff);
|
write_aux_reg(ARC_REG_PCT_INT_ACT, 0xffffffff);
|
||||||
@@ -515,7 +514,6 @@ static int arc_pmu_device_probe(struct platform_device *pdev)
|
|||||||
|
|
||||||
if (has_interrupts) {
|
if (has_interrupts) {
|
||||||
int irq = platform_get_irq(pdev, 0);
|
int irq = platform_get_irq(pdev, 0);
|
||||||
unsigned long flags;
|
|
||||||
|
|
||||||
if (irq < 0) {
|
if (irq < 0) {
|
||||||
pr_err("Cannot get IRQ number for the platform\n");
|
pr_err("Cannot get IRQ number for the platform\n");
|
||||||
@@ -524,24 +522,12 @@ static int arc_pmu_device_probe(struct platform_device *pdev)
|
|||||||
|
|
||||||
arc_pmu->irq = irq;
|
arc_pmu->irq = irq;
|
||||||
|
|
||||||
/*
|
/* intc map function ensures irq_set_percpu_devid() called */
|
||||||
* arc_cpu_pmu_irq_init() needs to be called on all cores for
|
request_percpu_irq(irq, arc_pmu_intr, "ARC perf counters",
|
||||||
* their respective local PMU.
|
this_cpu_ptr(&arc_pmu_cpu));
|
||||||
* However we use opencoded on_each_cpu() to ensure it is called
|
|
||||||
* on core0 first, so that arc_request_percpu_irq() sets up
|
on_each_cpu(arc_cpu_pmu_irq_init, &irq, 1);
|
||||||
* AUTOEN etc. Otherwise enable_percpu_irq() fails to enable
|
|
||||||
* perf IRQ on non master cores.
|
|
||||||
* see arc_request_percpu_irq()
|
|
||||||
*/
|
|
||||||
preempt_disable();
|
|
||||||
local_irq_save(flags);
|
|
||||||
arc_cpu_pmu_irq_init();
|
|
||||||
local_irq_restore(flags);
|
|
||||||
smp_call_function((smp_call_func_t)arc_cpu_pmu_irq_init, 0, 1);
|
|
||||||
preempt_enable();
|
|
||||||
|
|
||||||
/* Clean all pending interrupt flags */
|
|
||||||
write_aux_reg(ARC_REG_PCT_INT_ACT, 0xffffffff);
|
|
||||||
} else
|
} else
|
||||||
arc_pmu->pmu.capabilities |= PERF_PMU_CAP_NO_INTERRUPT;
|
arc_pmu->pmu.capabilities |= PERF_PMU_CAP_NO_INTERRUPT;
|
||||||
|
|
||||||
|
|||||||
@@ -429,7 +429,6 @@ void __init setup_arch(char **cmdline_p)
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
arc_unwind_init();
|
arc_unwind_init();
|
||||||
arc_unwind_setup();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int __init customize_machine(void)
|
static int __init customize_machine(void)
|
||||||
|
|||||||
@@ -132,11 +132,11 @@ void start_kernel_secondary(void)
|
|||||||
pr_info("## CPU%u LIVE ##: Executing Code...\n", cpu);
|
pr_info("## CPU%u LIVE ##: Executing Code...\n", cpu);
|
||||||
|
|
||||||
/* Some SMP H/w setup - for each cpu */
|
/* Some SMP H/w setup - for each cpu */
|
||||||
if (plat_smp_ops.init_irq_cpu)
|
if (plat_smp_ops.init_per_cpu)
|
||||||
plat_smp_ops.init_irq_cpu(cpu);
|
plat_smp_ops.init_per_cpu(cpu);
|
||||||
|
|
||||||
if (machine_desc->init_cpu_smp)
|
if (machine_desc->init_per_cpu)
|
||||||
machine_desc->init_cpu_smp(cpu);
|
machine_desc->init_per_cpu(cpu);
|
||||||
|
|
||||||
arc_local_timer_setup();
|
arc_local_timer_setup();
|
||||||
|
|
||||||
|
|||||||
+34
-23
@@ -170,6 +170,23 @@ static struct unwind_table *find_table(unsigned long pc)
|
|||||||
|
|
||||||
static unsigned long read_pointer(const u8 **pLoc,
|
static unsigned long read_pointer(const u8 **pLoc,
|
||||||
const void *end, signed ptrType);
|
const void *end, signed ptrType);
|
||||||
|
static void init_unwind_hdr(struct unwind_table *table,
|
||||||
|
void *(*alloc) (unsigned long));
|
||||||
|
|
||||||
|
/*
|
||||||
|
* wrappers for header alloc (vs. calling one vs. other at call site)
|
||||||
|
* to elide section mismatches warnings
|
||||||
|
*/
|
||||||
|
static void *__init unw_hdr_alloc_early(unsigned long sz)
|
||||||
|
{
|
||||||
|
return __alloc_bootmem_nopanic(sz, sizeof(unsigned int),
|
||||||
|
MAX_DMA_ADDRESS);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void *unw_hdr_alloc(unsigned long sz)
|
||||||
|
{
|
||||||
|
return kmalloc(sz, GFP_KERNEL);
|
||||||
|
}
|
||||||
|
|
||||||
static void init_unwind_table(struct unwind_table *table, const char *name,
|
static void init_unwind_table(struct unwind_table *table, const char *name,
|
||||||
const void *core_start, unsigned long core_size,
|
const void *core_start, unsigned long core_size,
|
||||||
@@ -209,6 +226,8 @@ void __init arc_unwind_init(void)
|
|||||||
__start_unwind, __end_unwind - __start_unwind,
|
__start_unwind, __end_unwind - __start_unwind,
|
||||||
NULL, 0);
|
NULL, 0);
|
||||||
/*__start_unwind_hdr, __end_unwind_hdr - __start_unwind_hdr);*/
|
/*__start_unwind_hdr, __end_unwind_hdr - __start_unwind_hdr);*/
|
||||||
|
|
||||||
|
init_unwind_hdr(&root_table, unw_hdr_alloc_early);
|
||||||
}
|
}
|
||||||
|
|
||||||
static const u32 bad_cie, not_fde;
|
static const u32 bad_cie, not_fde;
|
||||||
@@ -241,8 +260,8 @@ static void swap_eh_frame_hdr_table_entries(void *p1, void *p2, int size)
|
|||||||
e2->fde = v;
|
e2->fde = v;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void __init setup_unwind_table(struct unwind_table *table,
|
static void init_unwind_hdr(struct unwind_table *table,
|
||||||
void *(*alloc) (unsigned long))
|
void *(*alloc) (unsigned long))
|
||||||
{
|
{
|
||||||
const u8 *ptr;
|
const u8 *ptr;
|
||||||
unsigned long tableSize = table->size, hdrSize;
|
unsigned long tableSize = table->size, hdrSize;
|
||||||
@@ -277,10 +296,10 @@ static void __init setup_unwind_table(struct unwind_table *table,
|
|||||||
if (cie == ¬_fde)
|
if (cie == ¬_fde)
|
||||||
continue;
|
continue;
|
||||||
if (cie == NULL || cie == &bad_cie)
|
if (cie == NULL || cie == &bad_cie)
|
||||||
return;
|
goto ret_err;
|
||||||
ptrType = fde_pointer_type(cie);
|
ptrType = fde_pointer_type(cie);
|
||||||
if (ptrType < 0)
|
if (ptrType < 0)
|
||||||
return;
|
goto ret_err;
|
||||||
|
|
||||||
ptr = (const u8 *)(fde + 2);
|
ptr = (const u8 *)(fde + 2);
|
||||||
if (!read_pointer(&ptr, (const u8 *)(fde + 1) + *fde,
|
if (!read_pointer(&ptr, (const u8 *)(fde + 1) + *fde,
|
||||||
@@ -296,13 +315,15 @@ static void __init setup_unwind_table(struct unwind_table *table,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (tableSize || !n)
|
if (tableSize || !n)
|
||||||
return;
|
goto ret_err;
|
||||||
|
|
||||||
hdrSize = 4 + sizeof(unsigned long) + sizeof(unsigned int)
|
hdrSize = 4 + sizeof(unsigned long) + sizeof(unsigned int)
|
||||||
+ 2 * n * sizeof(unsigned long);
|
+ 2 * n * sizeof(unsigned long);
|
||||||
|
|
||||||
header = alloc(hdrSize);
|
header = alloc(hdrSize);
|
||||||
if (!header)
|
if (!header)
|
||||||
return;
|
goto ret_err;
|
||||||
|
|
||||||
header->version = 1;
|
header->version = 1;
|
||||||
header->eh_frame_ptr_enc = DW_EH_PE_abs | DW_EH_PE_native;
|
header->eh_frame_ptr_enc = DW_EH_PE_abs | DW_EH_PE_native;
|
||||||
header->fde_count_enc = DW_EH_PE_abs | DW_EH_PE_data4;
|
header->fde_count_enc = DW_EH_PE_abs | DW_EH_PE_data4;
|
||||||
@@ -340,18 +361,10 @@ static void __init setup_unwind_table(struct unwind_table *table,
|
|||||||
table->hdrsz = hdrSize;
|
table->hdrsz = hdrSize;
|
||||||
smp_wmb();
|
smp_wmb();
|
||||||
table->header = (const void *)header;
|
table->header = (const void *)header;
|
||||||
}
|
return;
|
||||||
|
|
||||||
static void *__init balloc(unsigned long sz)
|
ret_err:
|
||||||
{
|
panic("Attention !!! Dwarf FDE parsing errors\n");;
|
||||||
return __alloc_bootmem_nopanic(sz,
|
|
||||||
sizeof(unsigned int),
|
|
||||||
__pa(MAX_DMA_ADDRESS));
|
|
||||||
}
|
|
||||||
|
|
||||||
void __init arc_unwind_setup(void)
|
|
||||||
{
|
|
||||||
setup_unwind_table(&root_table, balloc);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_MODULES
|
#ifdef CONFIG_MODULES
|
||||||
@@ -377,6 +390,8 @@ void *unwind_add_table(struct module *module, const void *table_start,
|
|||||||
table_start, table_size,
|
table_start, table_size,
|
||||||
NULL, 0);
|
NULL, 0);
|
||||||
|
|
||||||
|
init_unwind_hdr(table, unw_hdr_alloc);
|
||||||
|
|
||||||
#ifdef UNWIND_DEBUG
|
#ifdef UNWIND_DEBUG
|
||||||
unw_debug("Table added for [%s] %lx %lx\n",
|
unw_debug("Table added for [%s] %lx %lx\n",
|
||||||
module->name, table->core.pc, table->core.range);
|
module->name, table->core.pc, table->core.range);
|
||||||
@@ -439,6 +454,7 @@ void unwind_remove_table(void *handle, int init_only)
|
|||||||
info.init_only = init_only;
|
info.init_only = init_only;
|
||||||
|
|
||||||
unlink_table(&info); /* XXX: SMP */
|
unlink_table(&info); /* XXX: SMP */
|
||||||
|
kfree(table->header);
|
||||||
kfree(table);
|
kfree(table);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -588,9 +604,6 @@ static signed fde_pointer_type(const u32 *cie)
|
|||||||
const u8 *ptr = (const u8 *)(cie + 2);
|
const u8 *ptr = (const u8 *)(cie + 2);
|
||||||
unsigned version = *ptr;
|
unsigned version = *ptr;
|
||||||
|
|
||||||
if (version != 1)
|
|
||||||
return -1; /* unsupported */
|
|
||||||
|
|
||||||
if (*++ptr) {
|
if (*++ptr) {
|
||||||
const char *aug;
|
const char *aug;
|
||||||
const u8 *end = (const u8 *)(cie + 1) + *cie;
|
const u8 *end = (const u8 *)(cie + 1) + *cie;
|
||||||
@@ -1002,9 +1015,7 @@ int arc_unwind(struct unwind_frame_info *frame)
|
|||||||
ptr = (const u8 *)(cie + 2);
|
ptr = (const u8 *)(cie + 2);
|
||||||
end = (const u8 *)(cie + 1) + *cie;
|
end = (const u8 *)(cie + 1) + *cie;
|
||||||
frame->call_frame = 1;
|
frame->call_frame = 1;
|
||||||
if ((state.version = *ptr) != 1)
|
if (*++ptr) {
|
||||||
cie = NULL; /* unsupported version */
|
|
||||||
else if (*++ptr) {
|
|
||||||
/* check if augmentation size is first (thus present) */
|
/* check if augmentation size is first (thus present) */
|
||||||
if (*ptr == 'z') {
|
if (*ptr == 'z') {
|
||||||
while (++ptr < end && *ptr) {
|
while (++ptr < end && *ptr) {
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user