projects/linux·commit 8bc2bee2

Merge HEAD from master.kernel.org:/pub/scm/linux/kernel/git/paulus/ppc64-2.6

8bc2bee2 · Linus Torvalds <[email protected]> · 2005-08-29 21:44:33 -07:00

Commit
8bc2bee26bc7ba77eb1ffc3e3282002d9893cf09
Parents
826509f8 · 8913ca1c

Merge commit. Changes below are compared with the first parent: 826509f8.

Changes

75 files changed · +204 −573

FileStatusAddDelContent
arch/ppc/Makefilemodified+10−1View file
arch/ppc64/Makefilemodified+9−0View file
arch/ppc64/configs/g5_defconfigmodified+3−3View file
arch/ppc64/configs/iSeries_defconfigmodified+3−3View file
arch/ppc64/configs/maple_defconfigmodified+3−3View file
arch/ppc64/configs/pSeries_defconfigmodified+3−3View file
arch/ppc64/defconfigmodified+3−3View file
arch/ppc64/kernel/head.Smodified+15−1View file
arch/ppc64/kernel/iSeries_vio.cmodified+16−5View file
arch/ppc64/kernel/lparcfg.cmodified+1−0View file
arch/ppc64/kernel/of_device.cmodified+0−2View file
arch/ppc64/kernel/pSeries_vio.cmodified+13−6View file
arch/ppc64/kernel/prom_init.cmodified+4−1View file
arch/ppc64/kernel/vio.cmodified+27−46View file
arch/ppc64/mm/hash_low.Smodified+1−3View file
arch/ppc64/oprofile/common.cmodified+1−0View file
drivers/block/viodasd.cmodified+1−1View file
drivers/cdrom/viocd.cmodified+1−1View file
drivers/char/hvc_vio.cmodified+1−1View file
drivers/char/hvcs.cmodified+1−1View file
drivers/char/viotape.cmodified+1−1View file
drivers/net/ibmveth.cmodified+1−1View file
drivers/net/iseries_veth.cmodified+1−1View file
drivers/scsi/ibmvscsi/ibmvscsi.cmodified+1−1View file
drivers/scsi/ibmvscsi/rpa_vscsi.cmodified+1−0View file
include/asm-ppc/8253pit.h → include/asm-powerpc/8253pit.hrenamed+1−1View file
include/asm-ppc/agp.h → include/asm-powerpc/agp.hrenamed+0−0View file
include/asm-powerpc/cputime.hadded+1−0View file
include/asm-ppc/div64.h → include/asm-powerpc/div64.hrenamed+0−0View file
include/asm-powerpc/emergency-restart.hadded+1−0View file
include/asm-ppc/errno.h → include/asm-powerpc/errno.hrenamed+0−0View file
include/asm-ppc/ioctl.h → include/asm-powerpc/ioctl.hrenamed+0−0View file
include/asm-ppc/ioctls.h → include/asm-powerpc/ioctls.hrenamed+0−0View file
include/asm-ppc/ipc.h → include/asm-powerpc/ipc.hrenamed+0−0View file
include/asm-ppc/linkage.h → include/asm-powerpc/linkage.hrenamed+0−0View file
include/asm-ppc64/local.h → include/asm-powerpc/local.hrenamed+0−0View file
include/asm-ppc/namei.h → include/asm-powerpc/namei.hrenamed+0−0View file
include/asm-powerpc/percpu.hadded+1−0View file
include/asm-ppc/poll.h → include/asm-powerpc/poll.hrenamed+0−0View file
include/asm-powerpc/resource.hadded+1−0View file
include/asm-ppc/shmparam.h → include/asm-powerpc/shmparam.hrenamed+0−0View file
include/asm-ppc/string.h → include/asm-powerpc/string.hrenamed+0−0View file
include/asm-ppc/unaligned.h → include/asm-powerpc/unaligned.hrenamed+0−0View file
include/asm-ppc/xor.h → include/asm-powerpc/xor.hrenamed+0−0View file
include/asm-ppc/cputime.hdeleted+0−6View before deletion
include/asm-ppc/emergency-restart.hdeleted+0−6View before deletion
include/asm-ppc/hdreg.hdeleted+0−1View before deletion
include/asm-ppc/local.hdeleted+0−6View before deletion
include/asm-ppc/percpu.hdeleted+0−6View before deletion
include/asm-ppc/resource.hdeleted+0−6View before deletion
include/asm-ppc64/8253pit.hdeleted+0−10View before deletion
include/asm-ppc64/agp.hdeleted+0−23View before deletion
include/asm-ppc64/cputime.hdeleted+0−6View before deletion
include/asm-ppc64/div64.hdeleted+0−1View before deletion
include/asm-ppc64/emergency-restart.hdeleted+0−6View before deletion
include/asm-ppc64/errno.hdeleted+0−18View before deletion
include/asm-ppc64/hdreg.hdeleted+0−1View before deletion
include/asm-ppc64/ioctl.hdeleted+0−74View before deletion
include/asm-ppc64/ioctls.hdeleted+0−114View before deletion
include/asm-ppc64/ipc.hdeleted+0−1View before deletion
include/asm-ppc64/linkage.hdeleted+0−6View before deletion
include/asm-ppc64/namei.hdeleted+0−23View before deletion
include/asm-ppc64/param.hmodified+3−1View file
include/asm-ppc64/percpu.hdeleted+0−6View before deletion
include/asm-ppc64/pgtable.hmodified+2−0View file
include/asm-ppc64/poll.hdeleted+0−32View before deletion
include/asm-ppc64/processor.hmodified+1−0View file
include/asm-ppc64/resource.hdeleted+0−6View before deletion
include/asm-ppc64/shmparam.hdeleted+0−13View before deletion
include/asm-ppc64/string.hdeleted+0−35View before deletion
include/asm-ppc64/unaligned.hdeleted+0−21View before deletion
include/asm-ppc64/vio.hmodified+47−54View file
include/asm-ppc64/xor.hdeleted+0−1View before deletion
include/linux/mod_devicetable.hmodified+6−1View file
scripts/mod/file2alias.cmodified+19−0View file

Only the first 600 diff lines are shown. Download the complete patch.

arch/ppc/Makefile

View file
diff --git a/arch/ppc/Makefile b/arch/ppc/Makefile
index f9b0d77..d1b6e6d 100644
--- a/arch/ppc/Makefile
+++ b/arch/ppc/Makefile
@@ -21,11 +21,13 @@ CC := $(CC) -m32
endif
LDFLAGS_vmlinux := -Ttext $(KERNELLOAD) -Bstatic
-CPPFLAGS += -Iarch/$(ARCH)
+CPPFLAGS += -Iarch/$(ARCH) -Iinclude3
AFLAGS += -Iarch/$(ARCH)
CFLAGS += -Iarch/$(ARCH) -msoft-float -pipe \
-ffixed-r2 -mmultiple
CPP = $(CC) -E $(CFLAGS)
+# Temporary hack until we have migrated to asm-powerpc
+LINUXINCLUDE += -Iinclude3
CHECKFLAGS += -D__powerpc__
@@ -101,6 +103,7 @@ endef
archclean:
$(Q)$(MAKE) $(clean)=arch/ppc/boot
+ $(Q)rm -rf include3
prepare: include/asm-$(ARCH)/offsets.h checkbin
@@ -110,6 +113,12 @@ arch/$(ARCH)/kernel/asm-offsets.s: include/asm include/linux/version.h \
include/asm-$(ARCH)/offsets.h: arch/$(ARCH)/kernel/asm-offsets.s
$(call filechk,gen-asm-offsets)
+# Temporary hack until we have migrated to asm-powerpc
+include/asm: include3/asm
+include3/asm:
+ $(Q)if [ ! -d include3 ]; then mkdir -p include3; fi
+ $(Q)ln -fsn $(srctree)/include/asm-powerpc include3/asm
+
# Use the file '.tmp_gas_check' for binutils tests, as gas won't output
# to stdout and these checks are run even on install targets.
TOUT := .tmp_gas_check

arch/ppc64/Makefile

View file
diff --git a/arch/ppc64/Makefile b/arch/ppc64/Makefile
index 731b847..6350cce 100644
--- a/arch/ppc64/Makefile
+++ b/arch/ppc64/Makefile
@@ -55,6 +55,8 @@ LDFLAGS := -m elf64ppc
LDFLAGS_vmlinux := -Bstatic -e $(KERNELLOAD) -Ttext $(KERNELLOAD)
CFLAGS += -msoft-float -pipe -mminimal-toc -mtraceback=none \
-mcall-aixdesc
+# Temporary hack until we have migrated to asm-powerpc
+CPPFLAGS += -Iinclude3
GCC_VERSION := $(call cc-version)
GCC_BROKEN_VEC := $(shell if [ $(GCC_VERSION) -lt 0400 ] ; then echo "y"; fi ;)
@@ -112,6 +114,7 @@ all: $(KBUILD_IMAGE)
archclean:
$(Q)$(MAKE) $(clean)=$(boot)
+ $(Q)rm -rf include3
prepare: include/asm-ppc64/offsets.h
@@ -121,6 +124,12 @@ arch/ppc64/kernel/asm-offsets.s: include/asm include/linux/version.h \
include/asm-ppc64/offsets.h: arch/ppc64/kernel/asm-offsets.s
$(call filechk,gen-asm-offsets)
+# Temporary hack until we have migrated to asm-powerpc
+include/asm: include3/asm
+include3/asm:
+ $(Q)if [ ! -d include3 ]; then mkdir -p include3; fi;
+ $(Q)ln -fsn $(srctree)/include/asm-powerpc include3/asm
+
define archhelp
echo '* zImage - Compressed kernel image (arch/$(ARCH)/boot/zImage)'
echo ' zImage.initrd- Compressed kernel image with initrd attached,'

arch/ppc64/configs/g5_defconfig

View file
diff --git a/arch/ppc64/configs/g5_defconfig b/arch/ppc64/configs/g5_defconfig
index ab56774..fc83d93 100644
--- a/arch/ppc64/configs/g5_defconfig
+++ b/arch/ppc64/configs/g5_defconfig
@@ -103,10 +103,10 @@ CONFIG_PREEMPT_NONE=y
# CONFIG_PREEMPT_VOLUNTARY is not set
# CONFIG_PREEMPT is not set
# CONFIG_PREEMPT_BKL is not set
-CONFIG_HZ_100=y
-# CONFIG_HZ_250 is not set
+# CONFIG_HZ_100 is not set
+CONFIG_HZ_250=y
# CONFIG_HZ_1000 is not set
-CONFIG_HZ=100
+CONFIG_HZ=250
CONFIG_GENERIC_HARDIRQS=y
CONFIG_SECCOMP=y
CONFIG_ISA_DMA_API=y

arch/ppc64/configs/iSeries_defconfig

View file
diff --git a/arch/ppc64/configs/iSeries_defconfig b/arch/ppc64/configs/iSeries_defconfig
index 219c667..013d4e0 100644
--- a/arch/ppc64/configs/iSeries_defconfig
+++ b/arch/ppc64/configs/iSeries_defconfig
@@ -94,10 +94,10 @@ CONFIG_PREEMPT_NONE=y
# CONFIG_PREEMPT_VOLUNTARY is not set
# CONFIG_PREEMPT is not set
# CONFIG_PREEMPT_BKL is not set
-CONFIG_HZ_100=y
-# CONFIG_HZ_250 is not set
+# CONFIG_HZ_100 is not set
+CONFIG_HZ_250=y
# CONFIG_HZ_1000 is not set
-CONFIG_HZ=100
+CONFIG_HZ=250
CONFIG_GENERIC_HARDIRQS=y
CONFIG_LPARCFG=y
CONFIG_SECCOMP=y

arch/ppc64/configs/maple_defconfig

View file
diff --git a/arch/ppc64/configs/maple_defconfig b/arch/ppc64/configs/maple_defconfig
index 2033fe6..dd42892 100644
--- a/arch/ppc64/configs/maple_defconfig
+++ b/arch/ppc64/configs/maple_defconfig
@@ -103,10 +103,10 @@ CONFIG_PREEMPT_NONE=y
# CONFIG_PREEMPT_VOLUNTARY is not set
# CONFIG_PREEMPT is not set
# CONFIG_PREEMPT_BKL is not set
-CONFIG_HZ_100=y
-# CONFIG_HZ_250 is not set
+# CONFIG_HZ_100 is not set
+CONFIG_HZ_250=y
# CONFIG_HZ_1000 is not set
-CONFIG_HZ=100
+CONFIG_HZ=250
CONFIG_GENERIC_HARDIRQS=y
CONFIG_SECCOMP=y
CONFIG_ISA_DMA_API=y

arch/ppc64/configs/pSeries_defconfig

View file
diff --git a/arch/ppc64/configs/pSeries_defconfig b/arch/ppc64/configs/pSeries_defconfig
index 297fd52..29f7b80 100644
--- a/arch/ppc64/configs/pSeries_defconfig
+++ b/arch/ppc64/configs/pSeries_defconfig
@@ -112,10 +112,10 @@ CONFIG_PREEMPT_NONE=y
# CONFIG_PREEMPT_VOLUNTARY is not set
# CONFIG_PREEMPT is not set
# CONFIG_PREEMPT_BKL is not set
-CONFIG_HZ_100=y
-# CONFIG_HZ_250 is not set
+# CONFIG_HZ_100 is not set
+CONFIG_HZ_250=y
# CONFIG_HZ_1000 is not set
-CONFIG_HZ=100
+CONFIG_HZ=250
CONFIG_EEH=y
CONFIG_GENERIC_HARDIRQS=y
CONFIG_PPC_RTAS=y

arch/ppc64/defconfig

View file
diff --git a/arch/ppc64/defconfig b/arch/ppc64/defconfig
index c361e77..7cb4750 100644
--- a/arch/ppc64/defconfig
+++ b/arch/ppc64/defconfig
@@ -114,10 +114,10 @@ CONFIG_PREEMPT_NONE=y
# CONFIG_PREEMPT_VOLUNTARY is not set
# CONFIG_PREEMPT is not set
# CONFIG_PREEMPT_BKL is not set
-CONFIG_HZ_100=y
-# CONFIG_HZ_250 is not set
+# CONFIG_HZ_100 is not set
+CONFIG_HZ_250=y
# CONFIG_HZ_1000 is not set
-CONFIG_HZ=100
+CONFIG_HZ=250
CONFIG_EEH=y
CONFIG_GENERIC_HARDIRQS=y
CONFIG_PPC_RTAS=y

arch/ppc64/kernel/head.S

View file
diff --git a/arch/ppc64/kernel/head.S b/arch/ppc64/kernel/head.S
index cccec49..0369597 100644
--- a/arch/ppc64/kernel/head.S
+++ b/arch/ppc64/kernel/head.S
@@ -1269,7 +1269,21 @@ initial_stab:
.= 0x7000
.globl fwnmi_data_area
fwnmi_data_area:
- .space PAGE_SIZE
+
+ /* iSeries does not use the FWNMI stuff, so it is safe to put
+ * this here, even if we later allow kernels that will boot on
+ * both pSeries and iSeries */
+#ifdef CONFIG_PPC_ISERIES
+ . = LPARMAP_PHYS
+#include "lparmap.s"
+/*
+ * This ".text" is here for old compilers that generate a trailing
+ * .note section when compiling .c files to .s
+ */
+ .text
+#endif /* CONFIG_PPC_ISERIES */
+
+ . = 0x8000
/*
* On pSeries, secondary processors spin in the following code.

arch/ppc64/kernel/iSeries_vio.c

View file
diff --git a/arch/ppc64/kernel/iSeries_vio.c b/arch/ppc64/kernel/iSeries_vio.c
index b4268cc..6b754b0 100644
--- a/arch/ppc64/kernel/iSeries_vio.c
+++ b/arch/ppc64/kernel/iSeries_vio.c
@@ -68,7 +68,7 @@ static void __init iommu_vio_init(void)
}
/**
- * vio_register_device: - Register a new vio device.
+ * vio_register_device_iseries: - Register a new iSeries vio device.
* @voidev: The device to register.
*/
static struct vio_dev *__init vio_register_device_iseries(char *type,
@@ -76,7 +76,7 @@ static struct vio_dev *__init vio_register_device_iseries(char *type,
{
struct vio_dev *viodev;
- /* allocate a vio_dev for this node */
+ /* allocate a vio_dev for this device */
viodev = kmalloc(sizeof(struct vio_dev), GFP_KERNEL);
if (!viodev)
return NULL;
@@ -84,8 +84,15 @@ static struct vio_dev *__init vio_register_device_iseries(char *type,
snprintf(viodev->dev.bus_id, BUS_ID_SIZE, "%s%d", type, unit_num);
- return vio_register_device_common(viodev, viodev->dev.bus_id, type,
- unit_num, &vio_iommu_table);
+ viodev->name = viodev->dev.bus_id;
+ viodev->type = type;
+ viodev->unit_address = unit_num;
+ viodev->iommu_table = &vio_iommu_table;
+ if (vio_register_device(viodev) == NULL) {
+ kfree(viodev);
+ return NULL;
+ }
+ return viodev;
}
void __init probe_bus_iseries(void)
@@ -124,6 +131,10 @@ static int vio_match_device_iseries(const struct vio_device_id *id,
return strncmp(dev->type, id->type, strlen(id->type)) == 0;
}
+static struct vio_bus_ops vio_bus_ops_iseries = {
+ .match = vio_match_device_iseries,
+};
+
/**
* vio_bus_init_iseries: - Initialize the iSeries virtual IO bus
*/
@@ -131,7 +142,7 @@ static int __init vio_bus_init_iseries(void)
{
int err;
- err = vio_bus_init(vio_match_device_iseries, NULL, NULL);
+ err = vio_bus_init(&vio_bus_ops_iseries);
if (err == 0) {
iommu_vio_init();
vio_bus_device.iommu_table = &vio_iommu_table;

arch/ppc64/kernel/lparcfg.c

View file
diff --git a/arch/ppc64/kernel/lparcfg.c b/arch/ppc64/kernel/lparcfg.c
index 9d034ff..edad361 100644
--- a/arch/ppc64/kernel/lparcfg.c
+++ b/arch/ppc64/kernel/lparcfg.c
@@ -273,6 +273,7 @@ static void parse_system_parameter_string(struct seq_file *m)
if (!workbuffer) {
printk(KERN_ERR "%s %s kmalloc failure at line %d \n",
__FILE__, __FUNCTION__, __LINE__);
+ kfree(local_buffer);
return;
}
#ifdef LPARCFG_DEBUG

arch/ppc64/kernel/of_device.c

View file
diff --git a/arch/ppc64/kernel/of_device.c b/arch/ppc64/kernel/of_device.c
index b80e819..da58081 100644
--- a/arch/ppc64/kernel/of_device.c
+++ b/arch/ppc64/kernel/of_device.c
@@ -236,7 +236,6 @@ void of_device_unregister(struct of_device *ofdev)
struct of_device* of_platform_device_create(struct device_node *np, const char *bus_id)
{
struct of_device *dev;
- u32 *reg;
dev = kmalloc(sizeof(*dev), GFP_KERNEL);
if (!dev)
@@ -250,7 +249,6 @@ struct of_device* of_platform_device_create(struct device_node *np, const char *
dev->dev.bus = &of_platform_bus_type;
dev->dev.release = of_release_dev;
- reg = (u32 *)get_property(np, "reg", NULL);
strlcpy(dev->dev.bus_id, bus_id, BUS_ID_SIZE);
if (of_device_register(dev) != 0) {

arch/ppc64/kernel/pSeries_vio.c

View file
diff --git a/arch/ppc64/kernel/pSeries_vio.c b/arch/ppc64/kernel/pSeries_vio.c
index 338f9e1..e0ae06f 100644
--- a/arch/ppc64/kernel/pSeries_vio.c
+++ b/arch/ppc64/kernel/pSeries_vio.c
@@ -19,6 +19,7 @@
#include <linux/kobject.h>
#include <asm/iommu.h>
#include <asm/dma.h>
+#include <asm/prom.h>
#include <asm/vio.h>
#include <asm/hvcall.h>
@@ -75,6 +76,12 @@ static void vio_unregister_device_pseries(struct vio_dev *viodev)
device_remove_file(&viodev->dev, &dev_attr_devspec);
}
+static struct vio_bus_ops vio_bus_ops_pseries = {
+ .match = vio_match_device_pseries,
+ .unregister_device = vio_unregister_device_pseries,
+ .release_device = vio_release_device_pseries,
+};
+
/**
* vio_bus_init_pseries: - Initialize the pSeries virtual IO bus
*/
@@ -82,9 +89,7 @@ static int __init vio_bus_init_pseries(void)
{
int err;
- err = vio_bus_init(vio_match_device_pseries,
- vio_unregister_device_pseries,
- vio_release_device_pseries);
+ err = vio_bus_init(&vio_bus_ops_pseries);
if (err == 0)
probe_bus_pseries();
return err;
@@ -181,11 +186,13 @@ struct vio_dev * __devinit vio_register_device_node(struct device_node *of_node)
}
snprintf(viodev->dev.bus_id, BUS_ID_SIZE, "%x", *unit_address);
+ viodev->name = of_node->name;
+ viodev->type = of_node->type;
+ viodev->unit_address = *unit_address;
+ viodev->iommu_table = vio_build_iommu_table(viodev);
/* register with generic device framework */
- if (vio_register_device_common(viodev, of_node->name, of_node->type,
- *unit_address, vio_build_iommu_table(viodev))
- == NULL) {
+ if (vio_register_device(viodev) == NULL) {
/* XXX free TCE table */
kfree(viodev);
return NULL;

arch/ppc64/kernel/prom_init.c

View file
diff --git a/arch/ppc64/kernel/prom_init.c b/arch/ppc64/kernel/prom_init.c
index adcf972..122283a 100644
--- a/arch/ppc64/kernel/prom_init.c
+++ b/arch/ppc64/kernel/prom_init.c
@@ -892,7 +892,10 @@ static void __init prom_init_mem(void)
if ( RELOC(of_platform) == PLATFORM_PSERIES_LPAR )
RELOC(alloc_top) = RELOC(rmo_top);
else
- RELOC(alloc_top) = RELOC(rmo_top) = min(0x40000000ul, RELOC(ram_top));
+ /* Some RS64 machines have buggy firmware where claims up at 1GB
+ * fails. Cap at 768MB as a workaround. Still plenty of room.
+ */
+ RELOC(alloc_top) = RELOC(rmo_top) = min(0x30000000ul, RELOC(ram_top));
prom_printf("memory layout at init:\n");
prom_printf(" memory_limit : %x (16 MB aligned)\n", RELOC(prom_memory_limit));

arch/ppc64/kernel/vio.c

View file
diff --git a/arch/ppc64/kernel/vio.c b/arch/ppc64/kernel/vio.c
index 3b790ba..c90e1dd 100644
--- a/arch/ppc64/kernel/vio.c
+++ b/arch/ppc64/kernel/vio.c
@@ -32,14 +32,13 @@ struct vio_dev vio_bus_device = { /* fake "parent" device */
.dev.bus = &vio_bus_type,
};
-static int (*is_match)(const struct vio_device_id *id,
- const struct vio_dev *dev);
-static void (*unregister_device_callback)(struct vio_dev *dev);
-static void (*release_device_callback)(struct device *dev);
+static struct vio_bus_ops vio_bus_ops;
-/* convert from struct device to struct vio_dev and pass to driver.
+/*
+ * Convert from struct device to struct vio_dev and pass to driver.
* dev->driver has already been set by generic code because vio_bus_match
- * succeeded. */
+ * succeeded.
+ */
static int vio_bus_probe(struct device *dev)
{
struct vio_dev *viodev = to_vio_dev(dev);
@@ -51,9 +50,8 @@ static int vio_bus_probe(struct device *dev)
return error;
id = vio_match_device(viodrv->id_table, viodev);
- if (id) {
+ if (id)
error = viodrv->probe(viodev, id);
- }
return error;
}
@@ -64,9 +62,8 @@ static int vio_bus_remove(struct device *dev)
struct vio_dev *viodev = to_vio_dev(dev);
struct vio_driver *viodrv = to_vio_driver(dev->driver);
- if (viodrv->remove) {
+ if (viodrv->remove)
return viodrv->remove(viodev);
- }
/* driver can't remove */
return 1;
@@ -102,19 +99,20 @@ void vio_unregister_driver(struct vio_driver *viodrv)
EXPORT_SYMBOL(vio_unregister_driver);
/**
- * vio_match_device: - Tell if a VIO device has a matching VIO device id structure.
- * @ids: array of VIO device id structures to search in
- * @dev: the VIO device structure to match against
+ * vio_match_device: - Tell if a VIO device has a matching
+ * VIO device id structure.
+ * @ids: array of VIO device id structures to search in
+ * @dev: the VIO device structure to match against
*
* Used by a driver to check whether a VIO device present in the
* system is in its list of supported devices. Returns the matching
* vio_device_id structure or NULL if there is no match.
*/
-static const struct vio_device_id * vio_match_device(const struct vio_device_id *ids,
- const struct vio_dev *dev)
+static const struct vio_device_id *vio_match_device(
+ const struct vio_device_id *ids, const struct vio_dev *dev)
{
- while (ids->type) {
- if (is_match(ids, dev))
+ while (ids->type[0] != '\0') {
+ if (vio_bus_ops.match(ids, dev))
return ids;
ids++;
}
@@ -124,16 +122,11 @@ static const struct vio_device_id * vio_match_device(const struct vio_device_id
/**
* vio_bus_init: - Initialize the virtual IO bus
*/
-int __init vio_bus_init(int (*match_func)(const struct vio_device_id *id,
- const struct vio_dev *dev),
- void (*unregister_dev)(struct vio_dev *),
- void (*release_dev)(struct device *))
+int __init vio_bus_init(struct vio_bus_ops *ops)
{
int err;
- is_match = match_func;
- unregister_device_callback = unregister_dev;
- release_device_callback = release_dev;
+ vio_bus_ops = *ops;
err = bus_register(&vio_bus_type);
if (err) {
@@ -141,7 +134,8 @@ int __init vio_bus_init(int (*match_func)(const struct vio_device_id *id,
return err;
}
- /* the fake parent of all vio devices, just to give us
+ /*
+ * The fake parent of all vio devices, just to give us
* a nice directory
*/
err = device_register(&vio_bus_device.dev);
@@ -157,25 +151,20 @@ int __init vio_bus_init(int (*match_func)(const struct vio_device_id *id,
/* vio_dev refcount hit 0 */
static void __devinit vio_dev_release(struct device *dev)
{
- if (release_device_callback)
- release_device_callback(dev);
+ if (vio_bus_ops.release_device)
+ vio_bus_ops.release_device(dev);
kfree(to_vio_dev(dev));
}
-static ssize_t viodev_show_name(struct device *dev, struct device_attribute *attr, char *buf)
+static ssize_t viodev_show_name(struct device *dev,
+ struct device_attribute *attr, char *buf)
{
return sprintf(buf, "%s\n", to_vio_dev(dev)->name);
}
DEVICE_ATTR(name, S_IRUSR | S_IRGRP | S_IROTH, viodev_show_name, NULL);
-struct vio_dev * __devinit vio_register_device_common(
- struct vio_dev *viodev, char *name, char *type,
- uint32_t unit_address, struct iommu_table *iommu_table)
+struct vio_dev * __devinit vio_register_device(struct vio_dev *viodev)
{
- viodev->name = name;
- viodev->type = type;
- viodev->unit_address = unit_address;
- viodev->iommu_table = iommu_table;
/* init generic 'struct device' fields: */
viodev->dev.parent = &vio_bus_device.dev;
viodev->dev.bus = &vio_bus_type;
@@ -194,8 +183,8 @@ struct vio_dev * __devinit vio_register_device_common(
void __devinit vio_unregister_device(struct vio_dev *viodev)
{
- if (unregister_device_callback)
- unregister_device_callback(viodev);
+ if (vio_bus_ops.unregister_device)
+ vio_bus_ops.unregister_device(viodev);
device_remove_file(&viodev->dev, &dev_attr_name);
device_unregister(&viodev->dev);
}
@@ -262,16 +251,8 @@ static int vio_bus_match(struct device *dev, struct device_driver *drv)
const struct vio_dev *vio_dev = to_vio_dev(dev);
struct vio_driver *vio_drv = to_vio_driver(drv);
const struct vio_device_id *ids = vio_drv->id_table;
- const struct vio_device_id *found_id;
-
- if (!ids)
- return 0;
- found_id = vio_match_device(ids, vio_dev);
- if (found_id)
- return 1;
-
- return 0;
+ return (ids != NULL) && (vio_match_device(ids, vio_dev) != NULL);
}
struct bus_type vio_bus_type = {

arch/ppc64/mm/hash_low.S

View file
diff --git a/arch/ppc64/mm/hash_low.S b/arch/ppc64/mm/hash_low.S
index fbff248..35eb49e 100644
--- a/arch/ppc64/mm/hash_low.S
+++ b/arch/ppc64/mm/hash_low.S
@@ -129,12 +129,10 @@ _GLOBAL(__hash_page)
* code rather than call a C function...)
*/
BEGIN_FTR_SECTION
-BEGIN_FTR_SECTION
mr r4,r30
mr r5,r7
bl .hash_page_do_lazy_icache
-END_FTR_SECTION_IFSET(CPU_FTR_NOEXECUTE)
-END_FTR_SECTION_IFCLR(CPU_FTR_COHERENT_ICACHE)
+END_FTR_SECTION(CPU_FTR_NOEXECUTE|CPU_FTR_COHERENT_ICACHE, CPU_FTR_NOEXECUTE)
/* At this point, r3 contains new PP bits, save them in
* place of "access" in the param area (sic)

arch/ppc64/oprofile/common.c

View file
diff --git a/arch/ppc64/oprofile/common.c b/arch/ppc64/oprofile/common.c
index b28bfda..4acd1a4 100644
--- a/arch/ppc64/oprofile/common.c
+++ b/arch/ppc64/oprofile/common.c
@@ -153,6 +153,7 @@ int __init oprofile_arch_init(struct oprofile_operations *ops)
case PV_970:
case PV_970FX:
+ case PV_970MP:
model = &op_model_power4;
model->num_counters = 8;
ops->cpu_type = "ppc64/970";

drivers/block/viodasd.c

View file
diff --git a/drivers/block/viodasd.c b/drivers/block/viodasd.c
index 46e56a2..e46ecd2 100644
--- a/drivers/block/viodasd.c
+++ b/drivers/block/viodasd.c
@@ -776,7 +776,7 @@ static int viodasd_remove(struct vio_dev *vdev)
*/
static struct vio_device_id viodasd_device_table[] __devinitdata = {
{ "viodasd", "" },
- { 0, }
+ { "", "" }
};
MODULE_DEVICE_TABLE(vio, viodasd_device_table);

drivers/cdrom/viocd.c

View file
diff --git a/drivers/cdrom/viocd.c b/drivers/cdrom/viocd.c
index 38dd9ff..0829db5 100644
--- a/drivers/cdrom/viocd.c
+++ b/drivers/cdrom/viocd.c
@@ -734,7 +734,7 @@ static int viocd_remove(struct vio_dev *vdev)
*/
static struct vio_device_id viocd_device_table[] __devinitdata = {
{ "viocd", "" },
- { 0, }
+ { "", "" }
};
MODULE_DEVICE_TABLE(vio, viocd_device_table);

drivers/char/hvc_vio.c

View file
diff --git a/drivers/char/hvc_vio.c b/drivers/char/hvc_vio.c
index 60bb915..78d681d 100644
--- a/drivers/char/hvc_vio.c
+++ b/drivers/char/hvc_vio.c
@@ -39,7 +39,7 @@ char hvc_driver_name[] = "hvc_console";
static struct vio_device_id hvc_driver_table[] __devinitdata = {
{"serial", "hvterm1"},
- { NULL, }
+ { "", "" }
};
MODULE_DEVICE_TABLE(vio, hvc_driver_table);

drivers/char/hvcs.c

View file
diff --git a/drivers/char/hvcs.c b/drivers/char/hvcs.c
index 3236d24..f47f009 100644
--- a/drivers/char/hvcs.c
+++ b/drivers/char/hvcs.c
@@ -527,7 +527,7 @@ static int khvcsd(void *unused)
static struct vio_device_id hvcs_driver_table[] __devinitdata= {
{"serial-server", "hvterm2"},
- { NULL, }
+ { "", "" }
};
MODULE_DEVICE_TABLE(vio, hvcs_driver_table);

drivers/char/viotape.c

View file
diff --git a/drivers/char/viotape.c b/drivers/char/viotape.c
index 4764b4f..0aff45f 100644
--- a/drivers/char/viotape.c

This diff is incomplete. Download the complete patch.

drivers/net/ibmveth.c

View file

This diff is incomplete. Download the complete patch.

drivers/net/iseries_veth.c

View file

This diff is incomplete. Download the complete patch.

drivers/scsi/ibmvscsi/ibmvscsi.c

View file

This diff is incomplete. Download the complete patch.

drivers/scsi/ibmvscsi/rpa_vscsi.c

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/8253pit.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/agp.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/cputime.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/div64.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/emergency-restart.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/errno.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/ioctl.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/ioctls.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/ipc.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/linkage.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/local.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/namei.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/percpu.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/poll.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/resource.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/shmparam.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/string.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/unaligned.h

View file

This diff is incomplete. Download the complete patch.

include/asm-powerpc/xor.h

View file

This diff is incomplete. Download the complete patch.

include/asm-ppc/cputime.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc/emergency-restart.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc/hdreg.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc/local.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc/percpu.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc/resource.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/8253pit.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/agp.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/cputime.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/div64.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/emergency-restart.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/errno.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/hdreg.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/ioctl.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/ioctls.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/ipc.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/linkage.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/namei.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/param.h

View file

This diff is incomplete. Download the complete patch.

include/asm-ppc64/percpu.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/pgtable.h

View file

This diff is incomplete. Download the complete patch.

include/asm-ppc64/poll.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/processor.h

View file

This diff is incomplete. Download the complete patch.

include/asm-ppc64/resource.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/shmparam.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/string.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/unaligned.h

View before deletion

This diff is incomplete. Download the complete patch.

include/asm-ppc64/vio.h

View file

This diff is incomplete. Download the complete patch.

include/asm-ppc64/xor.h

View before deletion

This diff is incomplete. Download the complete patch.

include/linux/mod_devicetable.h

View file

This diff is incomplete. Download the complete patch.

scripts/mod/file2alias.c

View file

This diff is incomplete. Download the complete patch.