parisc architecture fixes for kernel v7.1-rc3:
- Revert "parisc: led: fix reference leak on failed device registration" - Fix build failures introduced when allowing to build 32-/64-bit only VDSO - Switch to dynamic parisc root device to avoid upcoming warnings - Fix IRQ leak in LASI driver -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQS86RI+GtKfB8BJu973ErUQojoPXwUCafuSEAAKCRD3ErUQojoP X8T2AQCJq3aNsTJPG2pLeHFrzDwl0Xfik1W5SHqn9acHPay7mwD9H/uMCDtukZ2D WQsbyqxWEvuNGyWq3ww8WTlFMUhrXA8= =t5SV -----END PGP SIGNATURE----- Merge tag 'parisc-for-7.1-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux Pull parisc fixes from Helge Deller: - Revert "parisc: led: fix reference leak on failed device registration" - Fix build failures introduced when allowing to build 32-/64-bit only VDSO - Switch to dynamic parisc root device to avoid upcoming warnings - Fix IRQ leak in LASI driver * tag 'parisc-for-7.1-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux: parisc: Fix IRQ leak in LASI driver parisc: Fix 64-bit kernel build when CONFIG_COMPAT=n parisc: Fix build failure for 32-bit kernel with PA2.0 instruction set parisc: drivers: switch to dynamic root device Revert "parisc: led: fix reference leak on failed device registration"master
commit
5862221fdd
|
|
@ -174,15 +174,21 @@ ifeq ($(KBUILD_EXTMOD),)
|
|||
# this hack.
|
||||
prepare: vdso_prepare
|
||||
vdso_prepare: prepare0
|
||||
$(if $(CONFIG_64BIT),$(Q)$(MAKE) \
|
||||
$(build)=arch/parisc/kernel/vdso64 include/generated/vdso64-offsets.h)
|
||||
$(if $(CONFIG_PA11)$(CONFIG_COMPAT),$(Q)$(MAKE) \
|
||||
ifdef CONFIG_64BIT
|
||||
$(Q)$(MAKE) $(build)=arch/parisc/kernel/vdso64 include/generated/vdso64-offsets.h
|
||||
$(if $(CONFIG_COMPAT),$(Q)$(MAKE) \
|
||||
$(build)=arch/parisc/kernel/vdso32 include/generated/vdso32-offsets.h)
|
||||
else
|
||||
$(Q)$(MAKE) $(build)=arch/parisc/kernel/vdso32 include/generated/vdso32-offsets.h
|
||||
endif
|
||||
endif
|
||||
|
||||
vdso-install-$(CONFIG_PA11) += arch/parisc/kernel/vdso32/vdso32.so
|
||||
ifdef CONFIG_64BIT
|
||||
vdso-install-y += arch/parisc/kernel/vdso64/vdso64.so
|
||||
vdso-install-$(CONFIG_COMPAT) += arch/parisc/kernel/vdso32/vdso32.so
|
||||
vdso-install-$(CONFIG_64BIT) += arch/parisc/kernel/vdso64/vdso64.so
|
||||
else
|
||||
vdso-install-y += arch/parisc/kernel/vdso32/vdso32.so
|
||||
endif
|
||||
|
||||
install: KBUILD_IMAGE := vmlinux
|
||||
zinstall: KBUILD_IMAGE := vmlinuz
|
||||
|
|
|
|||
|
|
@ -6,13 +6,14 @@
|
|||
|
||||
#ifdef CONFIG_64BIT
|
||||
#include <generated/vdso64-offsets.h>
|
||||
#define VDSO64_SYMBOL(tsk, name) ((tsk)->mm->context.vdso_base + (vdso64_offset_##name))
|
||||
#endif
|
||||
#if !defined(CONFIG_64BIT) || defined(CONFIG_COMPAT)
|
||||
#include <generated/vdso32-offsets.h>
|
||||
#endif
|
||||
|
||||
#define VDSO64_SYMBOL(tsk, name) ((tsk)->mm->context.vdso_base + (vdso64_offset_##name))
|
||||
#define VDSO32_SYMBOL(tsk, name) ((tsk)->mm->context.vdso_base + (vdso32_offset_##name))
|
||||
#else
|
||||
#define VDSO32_SYMBOL(tsk, name) 0UL
|
||||
#endif
|
||||
|
||||
#endif /* __ASSEMBLER__ */
|
||||
|
||||
|
|
|
|||
|
|
@ -46,6 +46,9 @@ obj-$(CONFIG_KEXEC_FILE) += kexec_file.o
|
|||
|
||||
# vdso
|
||||
obj-y += vdso.o
|
||||
obj-$(CONFIG_64BIT) += vdso64/
|
||||
obj-$(CONFIG_PA11) += vdso32/
|
||||
ifdef CONFIG_64BIT
|
||||
obj-y += vdso64/
|
||||
obj-$(CONFIG_COMPAT) += vdso32/
|
||||
else
|
||||
obj-y += vdso32/
|
||||
endif
|
||||
|
|
|
|||
|
|
@ -41,9 +41,7 @@
|
|||
const struct dma_map_ops *hppa_dma_ops __ro_after_init;
|
||||
EXPORT_SYMBOL(hppa_dma_ops);
|
||||
|
||||
static struct device root = {
|
||||
.init_name = "parisc",
|
||||
};
|
||||
static struct device *root;
|
||||
|
||||
static inline int check_dev(struct device *dev)
|
||||
{
|
||||
|
|
@ -89,7 +87,7 @@ static int for_each_padev(int (*fn)(struct device *, void *), void * data)
|
|||
.obj = data,
|
||||
.fn = fn,
|
||||
};
|
||||
return device_for_each_child(&root, &recurse_data, descend_children);
|
||||
return device_for_each_child(root, &recurse_data, descend_children);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -290,7 +288,7 @@ const struct parisc_device *
|
|||
find_pa_parent_type(const struct parisc_device *padev, int type)
|
||||
{
|
||||
const struct device *dev = &padev->dev;
|
||||
while (dev != &root) {
|
||||
while (dev != root) {
|
||||
struct parisc_device *candidate = to_parisc_device(dev);
|
||||
if (candidate->id.hw_type == type)
|
||||
return candidate;
|
||||
|
|
@ -319,7 +317,7 @@ static void get_node_path(struct device *dev, struct hardware_path *path)
|
|||
dev = dev->parent;
|
||||
}
|
||||
|
||||
while (dev != &root) {
|
||||
while (dev != root) {
|
||||
if (dev_is_pci(dev)) {
|
||||
unsigned int devfn = to_pci_dev(dev)->devfn;
|
||||
path->bc[i--] = PCI_SLOT(devfn) | (PCI_FUNC(devfn)<< 5);
|
||||
|
|
@ -482,7 +480,7 @@ static struct parisc_device * __init alloc_tree_node(
|
|||
static struct parisc_device *create_parisc_device(struct hardware_path *modpath)
|
||||
{
|
||||
int i;
|
||||
struct device *parent = &root;
|
||||
struct device *parent = root;
|
||||
for (i = 0; i < 6; i++) {
|
||||
if (modpath->bc[i] == -1)
|
||||
continue;
|
||||
|
|
@ -755,7 +753,7 @@ parse_tree_node(struct device *parent, int index, struct hardware_path *modpath)
|
|||
struct device *hwpath_to_device(struct hardware_path *modpath)
|
||||
{
|
||||
int i;
|
||||
struct device *parent = &root;
|
||||
struct device *parent = root;
|
||||
for (i = 0; i < 6; i++) {
|
||||
if (modpath->bc[i] == -1)
|
||||
continue;
|
||||
|
|
@ -880,7 +878,7 @@ void __init walk_central_bus(void)
|
|||
{
|
||||
walk_native_bus(CENTRAL_BUS_ADDR,
|
||||
CENTRAL_BUS_ADDR + (MAX_NATIVE_DEVICES * NATIVE_DEVICE_OFFSET),
|
||||
&root);
|
||||
root);
|
||||
}
|
||||
|
||||
static __init void print_parisc_device(struct parisc_device *dev)
|
||||
|
|
@ -907,9 +905,10 @@ void __init init_parisc_bus(void)
|
|||
{
|
||||
if (bus_register(&parisc_bus_type))
|
||||
panic("Could not register PA-RISC bus type\n");
|
||||
if (device_register(&root))
|
||||
|
||||
root = root_device_register("parisc");
|
||||
if (IS_ERR(root))
|
||||
panic("Could not register PA-RISC root device\n");
|
||||
get_device(&root);
|
||||
}
|
||||
|
||||
static __init void qemu_header(void)
|
||||
|
|
|
|||
|
|
@ -193,8 +193,7 @@ static int __init lasi_init_chip(struct parisc_device *dev)
|
|||
|
||||
ret = request_irq(lasi->gsc_irq.irq, gsc_asic_intr, 0, "lasi", lasi);
|
||||
if (ret < 0) {
|
||||
kfree(lasi);
|
||||
return ret;
|
||||
goto err_free;
|
||||
}
|
||||
|
||||
/* enable IRQ's for devices below LASI */
|
||||
|
|
@ -203,8 +202,7 @@ static int __init lasi_init_chip(struct parisc_device *dev)
|
|||
/* Done init'ing, register this driver */
|
||||
ret = gsc_common_setup(dev, lasi);
|
||||
if (ret) {
|
||||
kfree(lasi);
|
||||
return ret;
|
||||
goto err_irq;
|
||||
}
|
||||
|
||||
gsc_fixup_irqs(dev, lasi, lasi_choose_irq);
|
||||
|
|
@ -214,6 +212,12 @@ static int __init lasi_init_chip(struct parisc_device *dev)
|
|||
SYS_OFF_PRIO_DEFAULT, lasi_power_off, lasi);
|
||||
|
||||
return ret;
|
||||
|
||||
err_irq:
|
||||
free_irq(lasi->gsc_irq.irq, lasi);
|
||||
err_free:
|
||||
kfree(lasi);
|
||||
return ret;
|
||||
}
|
||||
|
||||
static struct parisc_device_id lasi_tbl[] __initdata = {
|
||||
|
|
|
|||
|
|
@ -543,10 +543,8 @@ static void __init register_led_regions(void)
|
|||
|
||||
static int __init startup_leds(void)
|
||||
{
|
||||
if (platform_device_register(&platform_leds)) {
|
||||
pr_info("LED: failed to register LEDs\n");
|
||||
platform_device_put(&platform_leds);
|
||||
}
|
||||
if (platform_device_register(&platform_leds))
|
||||
printk(KERN_INFO "LED: failed to register LEDs\n");
|
||||
register_led_regions();
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue