aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc')
-rw-r--r--arch/powerpc/Kconfig11
-rw-r--r--arch/powerpc/Makefile4
-rw-r--r--arch/powerpc/configs/g5_defconfig58
-rw-r--r--arch/powerpc/configs/iseries_defconfig43
-rw-r--r--arch/powerpc/configs/pseries_defconfig54
-rw-r--r--arch/powerpc/kernel/Makefile2
-rw-r--r--arch/powerpc/kernel/asm-offsets.c1
-rw-r--r--arch/powerpc/kernel/entry_32.S35
-rw-r--r--arch/powerpc/kernel/head_64.S49
-rw-r--r--arch/powerpc/kernel/idle.c4
-rw-r--r--arch/powerpc/kernel/idle_6xx.S63
-rw-r--r--arch/powerpc/kernel/idle_power4.S10
-rw-r--r--arch/powerpc/kernel/iommu.c36
-rw-r--r--arch/powerpc/kernel/irq.c36
-rw-r--r--arch/powerpc/kernel/kprobes.c14
-rw-r--r--arch/powerpc/kernel/pci_iommu.c40
-rw-r--r--arch/powerpc/kernel/prom.c2
-rw-r--r--arch/powerpc/kernel/prom_init.c5
-rw-r--r--arch/powerpc/kernel/rtas-proc.c4
-rw-r--r--arch/powerpc/kernel/systbl.S6
-rw-r--r--arch/powerpc/kernel/vio.c6
-rw-r--r--arch/powerpc/platforms/cell/spu_callbacks.c5
-rw-r--r--arch/powerpc/platforms/cell/spufs/switch.c2
-rw-r--r--arch/powerpc/platforms/chrp/chrp.h1
-rw-r--r--arch/powerpc/platforms/chrp/pci.c6
-rw-r--r--arch/powerpc/platforms/chrp/setup.c44
-rw-r--r--arch/powerpc/platforms/iseries/setup.c7
-rw-r--r--arch/powerpc/platforms/powermac/low_i2c.c78
-rw-r--r--arch/powerpc/platforms/pseries/eeh.c6
-rw-r--r--arch/powerpc/platforms/pseries/rtasd.c2
-rw-r--r--arch/powerpc/sysdev/dart_iommu.c12
31 files changed, 381 insertions, 265 deletions
diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
index 2cdc35ce8045..6729c98b66f9 100644
--- a/arch/powerpc/Kconfig
+++ b/arch/powerpc/Kconfig
@@ -366,6 +366,7 @@ config PPC_PMAC64
366 select U3_DART 366 select U3_DART
367 select MPIC_BROKEN_U3 367 select MPIC_BROKEN_U3
368 select GENERIC_TBSYNC 368 select GENERIC_TBSYNC
369 select PPC_970_NAP
369 default y 370 default y
370 371
371config PPC_PREP 372config PPC_PREP
@@ -383,6 +384,7 @@ config PPC_MAPLE
383 select MPIC_BROKEN_U3 384 select MPIC_BROKEN_U3
384 select GENERIC_TBSYNC 385 select GENERIC_TBSYNC
385 select PPC_UDBG_16550 386 select PPC_UDBG_16550
387 select PPC_970_NAP
386 default n 388 default n
387 help 389 help
388 This option enables support for the Maple 970FX Evaluation Board. 390 This option enables support for the Maple 970FX Evaluation Board.
@@ -457,6 +459,10 @@ config PPC_MPC106
457 bool 459 bool
458 default n 460 default n
459 461
462config PPC_970_NAP
463 bool
464 default n
465
460source "drivers/cpufreq/Kconfig" 466source "drivers/cpufreq/Kconfig"
461 467
462config CPU_FREQ_PMAC 468config CPU_FREQ_PMAC
@@ -649,6 +655,11 @@ config NUMA
649 depends on PPC64 655 depends on PPC64
650 default y if SMP && PPC_PSERIES 656 default y if SMP && PPC_PSERIES
651 657
658config NODES_SHIFT
659 int
660 default "4"
661 depends on NEED_MULTIPLE_NODES
662
652config ARCH_SELECT_MEMORY_MODEL 663config ARCH_SELECT_MEMORY_MODEL
653 def_bool y 664 def_bool y
654 depends on PPC64 665 depends on PPC64
diff --git a/arch/powerpc/Makefile b/arch/powerpc/Makefile
index 6ec84d37a337..ed5b26aa8be3 100644
--- a/arch/powerpc/Makefile
+++ b/arch/powerpc/Makefile
@@ -104,6 +104,10 @@ ifndef CONFIG_FSL_BOOKE
104CFLAGS += -mstring 104CFLAGS += -mstring
105endif 105endif
106 106
107ifeq ($(CONFIG_6xx),y)
108CFLAGS += -mcpu=powerpc
109endif
110
107cpu-as-$(CONFIG_PPC64BRIDGE) += -Wa,-mppc64bridge 111cpu-as-$(CONFIG_PPC64BRIDGE) += -Wa,-mppc64bridge
108cpu-as-$(CONFIG_4xx) += -Wa,-m405 112cpu-as-$(CONFIG_4xx) += -Wa,-m405
109cpu-as-$(CONFIG_6xx) += -Wa,-maltivec 113cpu-as-$(CONFIG_6xx) += -Wa,-maltivec
diff --git a/arch/powerpc/configs/g5_defconfig b/arch/powerpc/configs/g5_defconfig
index 2c3fd2007676..a45627547d03 100644
--- a/arch/powerpc/configs/g5_defconfig
+++ b/arch/powerpc/configs/g5_defconfig
@@ -1,7 +1,7 @@
1# 1#
2# Automatically generated make config: don't edit 2# Automatically generated make config: don't edit
3# Linux kernel version: 2.6.16-rc2 3# Linux kernel version: 2.6.17-rc1
4# Fri Feb 10 17:33:08 2006 4# Wed Apr 19 13:24:37 2006
5# 5#
6CONFIG_PPC64=y 6CONFIG_PPC64=y
7CONFIG_64BIT=y 7CONFIG_64BIT=y
@@ -9,6 +9,7 @@ CONFIG_PPC_MERGE=y
9CONFIG_MMU=y 9CONFIG_MMU=y
10CONFIG_GENERIC_HARDIRQS=y 10CONFIG_GENERIC_HARDIRQS=y
11CONFIG_RWSEM_XCHGADD_ALGORITHM=y 11CONFIG_RWSEM_XCHGADD_ALGORITHM=y
12CONFIG_GENERIC_HWEIGHT=y
12CONFIG_GENERIC_CALIBRATE_DELAY=y 13CONFIG_GENERIC_CALIBRATE_DELAY=y
13CONFIG_PPC=y 14CONFIG_PPC=y
14CONFIG_EARLY_PRINTK=y 15CONFIG_EARLY_PRINTK=y
@@ -29,6 +30,7 @@ CONFIG_POWER4=y
29CONFIG_PPC_FPU=y 30CONFIG_PPC_FPU=y
30CONFIG_ALTIVEC=y 31CONFIG_ALTIVEC=y
31CONFIG_PPC_STD_MMU=y 32CONFIG_PPC_STD_MMU=y
33CONFIG_VIRT_CPU_ACCOUNTING=y
32CONFIG_SMP=y 34CONFIG_SMP=y
33CONFIG_NR_CPUS=4 35CONFIG_NR_CPUS=4
34 36
@@ -53,6 +55,7 @@ CONFIG_SYSCTL=y
53CONFIG_IKCONFIG=y 55CONFIG_IKCONFIG=y
54CONFIG_IKCONFIG_PROC=y 56CONFIG_IKCONFIG_PROC=y
55# CONFIG_CPUSETS is not set 57# CONFIG_CPUSETS is not set
58# CONFIG_RELAY is not set
56CONFIG_INITRAMFS_SOURCE="" 59CONFIG_INITRAMFS_SOURCE=""
57CONFIG_CC_OPTIMIZE_FOR_SIZE=y 60CONFIG_CC_OPTIMIZE_FOR_SIZE=y
58# CONFIG_EMBEDDED is not set 61# CONFIG_EMBEDDED is not set
@@ -67,10 +70,6 @@ CONFIG_BASE_FULL=y
67CONFIG_FUTEX=y 70CONFIG_FUTEX=y
68CONFIG_EPOLL=y 71CONFIG_EPOLL=y
69CONFIG_SHMEM=y 72CONFIG_SHMEM=y
70CONFIG_CC_ALIGN_FUNCTIONS=0
71CONFIG_CC_ALIGN_LABELS=0
72CONFIG_CC_ALIGN_LOOPS=0
73CONFIG_CC_ALIGN_JUMPS=0
74CONFIG_SLAB=y 73CONFIG_SLAB=y
75# CONFIG_TINY_SHMEM is not set 74# CONFIG_TINY_SHMEM is not set
76CONFIG_BASE_SMALL=0 75CONFIG_BASE_SMALL=0
@@ -82,7 +81,6 @@ CONFIG_BASE_SMALL=0
82CONFIG_MODULES=y 81CONFIG_MODULES=y
83CONFIG_MODULE_UNLOAD=y 82CONFIG_MODULE_UNLOAD=y
84# CONFIG_MODULE_FORCE_UNLOAD is not set 83# CONFIG_MODULE_FORCE_UNLOAD is not set
85CONFIG_OBSOLETE_MODPARM=y
86CONFIG_MODVERSIONS=y 84CONFIG_MODVERSIONS=y
87CONFIG_MODULE_SRCVERSION_ALL=y 85CONFIG_MODULE_SRCVERSION_ALL=y
88CONFIG_KMOD=y 86CONFIG_KMOD=y
@@ -91,6 +89,7 @@ CONFIG_STOP_MACHINE=y
91# 89#
92# Block layer 90# Block layer
93# 91#
92# CONFIG_BLK_DEV_IO_TRACE is not set
94 93
95# 94#
96# IO Schedulers 95# IO Schedulers
@@ -185,7 +184,6 @@ CONFIG_GENERIC_ISA_DMA=y
185# CONFIG_PPC_INDIRECT_PCI is not set 184# CONFIG_PPC_INDIRECT_PCI is not set
186CONFIG_PCI=y 185CONFIG_PCI=y
187CONFIG_PCI_DOMAINS=y 186CONFIG_PCI_DOMAINS=y
188CONFIG_PCI_LEGACY_PROC=y
189# CONFIG_PCI_DEBUG is not set 187# CONFIG_PCI_DEBUG is not set
190 188
191# 189#
@@ -227,6 +225,7 @@ CONFIG_SYN_COOKIES=y
227CONFIG_INET_AH=m 225CONFIG_INET_AH=m
228CONFIG_INET_ESP=m 226CONFIG_INET_ESP=m
229CONFIG_INET_IPCOMP=m 227CONFIG_INET_IPCOMP=m
228CONFIG_INET_XFRM_TUNNEL=m
230CONFIG_INET_TUNNEL=y 229CONFIG_INET_TUNNEL=y
231CONFIG_INET_DIAG=y 230CONFIG_INET_DIAG=y
232CONFIG_INET_TCP_DIAG=y 231CONFIG_INET_TCP_DIAG=y
@@ -238,6 +237,8 @@ CONFIG_TCP_CONG_BIC=y
238# 237#
239# CONFIG_IP_VS is not set 238# CONFIG_IP_VS is not set
240# CONFIG_IPV6 is not set 239# CONFIG_IPV6 is not set
240# CONFIG_INET6_XFRM_TUNNEL is not set
241# CONFIG_INET6_TUNNEL is not set
241CONFIG_NETFILTER=y 242CONFIG_NETFILTER=y
242# CONFIG_NETFILTER_DEBUG is not set 243# CONFIG_NETFILTER_DEBUG is not set
243 244
@@ -261,6 +262,7 @@ CONFIG_IP_NF_IRC=m
261CONFIG_IP_NF_TFTP=m 262CONFIG_IP_NF_TFTP=m
262CONFIG_IP_NF_AMANDA=m 263CONFIG_IP_NF_AMANDA=m
263# CONFIG_IP_NF_PPTP is not set 264# CONFIG_IP_NF_PPTP is not set
265# CONFIG_IP_NF_H323 is not set
264CONFIG_IP_NF_QUEUE=m 266CONFIG_IP_NF_QUEUE=m
265 267
266# 268#
@@ -513,6 +515,7 @@ CONFIG_MD_RAID0=y
513CONFIG_MD_RAID1=y 515CONFIG_MD_RAID1=y
514CONFIG_MD_RAID10=m 516CONFIG_MD_RAID10=m
515CONFIG_MD_RAID5=y 517CONFIG_MD_RAID5=y
518# CONFIG_MD_RAID5_RESHAPE is not set
516CONFIG_MD_RAID6=m 519CONFIG_MD_RAID6=m
517CONFIG_MD_MULTIPATH=m 520CONFIG_MD_MULTIPATH=m
518CONFIG_MD_FAULTY=m 521CONFIG_MD_FAULTY=m
@@ -761,7 +764,6 @@ CONFIG_LEGACY_PTY_COUNT=256
761# Watchdog Cards 764# Watchdog Cards
762# 765#
763# CONFIG_WATCHDOG is not set 766# CONFIG_WATCHDOG is not set
764# CONFIG_RTC is not set
765CONFIG_GEN_RTC=y 767CONFIG_GEN_RTC=y
766# CONFIG_GEN_RTC_X is not set 768# CONFIG_GEN_RTC_X is not set
767# CONFIG_DTLK is not set 769# CONFIG_DTLK is not set
@@ -772,6 +774,7 @@ CONFIG_GEN_RTC=y
772# Ftape, the floppy tape device driver 774# Ftape, the floppy tape device driver
773# 775#
774CONFIG_AGP=m 776CONFIG_AGP=m
777# CONFIG_AGP_VIA is not set
775CONFIG_AGP_UNINORTH=m 778CONFIG_AGP_UNINORTH=m
776# CONFIG_DRM is not set 779# CONFIG_DRM is not set
777CONFIG_RAW_DRIVER=y 780CONFIG_RAW_DRIVER=y
@@ -813,7 +816,6 @@ CONFIG_I2C_POWERMAC=y
813# CONFIG_I2C_PARPORT_LIGHT is not set 816# CONFIG_I2C_PARPORT_LIGHT is not set
814# CONFIG_I2C_PROSAVAGE is not set 817# CONFIG_I2C_PROSAVAGE is not set
815# CONFIG_I2C_SAVAGE4 is not set 818# CONFIG_I2C_SAVAGE4 is not set
816# CONFIG_SCx200_ACB is not set
817# CONFIG_I2C_SIS5595 is not set 819# CONFIG_I2C_SIS5595 is not set
818# CONFIG_I2C_SIS630 is not set 820# CONFIG_I2C_SIS630 is not set
819# CONFIG_I2C_SIS96X is not set 821# CONFIG_I2C_SIS96X is not set
@@ -832,9 +834,7 @@ CONFIG_I2C_POWERMAC=y
832# CONFIG_SENSORS_PCF8574 is not set 834# CONFIG_SENSORS_PCF8574 is not set
833# CONFIG_SENSORS_PCA9539 is not set 835# CONFIG_SENSORS_PCA9539 is not set
834# CONFIG_SENSORS_PCF8591 is not set 836# CONFIG_SENSORS_PCF8591 is not set
835# CONFIG_SENSORS_RTC8564 is not set
836# CONFIG_SENSORS_MAX6875 is not set 837# CONFIG_SENSORS_MAX6875 is not set
837# CONFIG_RTC_X1205_I2C is not set
838# CONFIG_I2C_DEBUG_CORE is not set 838# CONFIG_I2C_DEBUG_CORE is not set
839# CONFIG_I2C_DEBUG_ALGO is not set 839# CONFIG_I2C_DEBUG_ALGO is not set
840# CONFIG_I2C_DEBUG_BUS is not set 840# CONFIG_I2C_DEBUG_BUS is not set
@@ -862,10 +862,6 @@ CONFIG_I2C_POWERMAC=y
862# 862#
863 863
864# 864#
865# Multimedia Capabilities Port drivers
866#
867
868#
869# Multimedia devices 865# Multimedia devices
870# 866#
871# CONFIG_VIDEO_DEV is not set 867# CONFIG_VIDEO_DEV is not set
@@ -874,6 +870,7 @@ CONFIG_I2C_POWERMAC=y
874# Digital Video Broadcasting Devices 870# Digital Video Broadcasting Devices
875# 871#
876# CONFIG_DVB is not set 872# CONFIG_DVB is not set
873# CONFIG_USB_DABUSB is not set
877 874
878# 875#
879# Graphics support 876# Graphics support
@@ -883,6 +880,7 @@ CONFIG_FB_CFB_FILLRECT=y
883CONFIG_FB_CFB_COPYAREA=y 880CONFIG_FB_CFB_COPYAREA=y
884CONFIG_FB_CFB_IMAGEBLIT=y 881CONFIG_FB_CFB_IMAGEBLIT=y
885CONFIG_FB_MACMODES=y 882CONFIG_FB_MACMODES=y
883CONFIG_FB_FIRMWARE_EDID=y
886CONFIG_FB_MODE_HELPERS=y 884CONFIG_FB_MODE_HELPERS=y
887CONFIG_FB_TILEBLITTING=y 885CONFIG_FB_TILEBLITTING=y
888# CONFIG_FB_CIRRUS is not set 886# CONFIG_FB_CIRRUS is not set
@@ -901,7 +899,6 @@ CONFIG_FB_NVIDIA=y
901CONFIG_FB_NVIDIA_I2C=y 899CONFIG_FB_NVIDIA_I2C=y
902# CONFIG_FB_RIVA is not set 900# CONFIG_FB_RIVA is not set
903# CONFIG_FB_MATROX is not set 901# CONFIG_FB_MATROX is not set
904# CONFIG_FB_RADEON_OLD is not set
905CONFIG_FB_RADEON=y 902CONFIG_FB_RADEON=y
906CONFIG_FB_RADEON_I2C=y 903CONFIG_FB_RADEON_I2C=y
907# CONFIG_FB_RADEON_DEBUG is not set 904# CONFIG_FB_RADEON_DEBUG is not set
@@ -958,9 +955,11 @@ CONFIG_SND_SEQUENCER=m
958CONFIG_SND_OSSEMUL=y 955CONFIG_SND_OSSEMUL=y
959CONFIG_SND_MIXER_OSS=m 956CONFIG_SND_MIXER_OSS=m
960CONFIG_SND_PCM_OSS=m 957CONFIG_SND_PCM_OSS=m
958CONFIG_SND_PCM_OSS_PLUGINS=y
961CONFIG_SND_SEQUENCER_OSS=y 959CONFIG_SND_SEQUENCER_OSS=y
962# CONFIG_SND_DYNAMIC_MINORS is not set 960# CONFIG_SND_DYNAMIC_MINORS is not set
963CONFIG_SND_SUPPORT_OLD_API=y 961CONFIG_SND_SUPPORT_OLD_API=y
962CONFIG_SND_VERBOSE_PROCFS=y
964# CONFIG_SND_VERBOSE_PRINTK is not set 963# CONFIG_SND_VERBOSE_PRINTK is not set
965# CONFIG_SND_DEBUG is not set 964# CONFIG_SND_DEBUG is not set
966 965
@@ -977,6 +976,7 @@ CONFIG_SND_SUPPORT_OLD_API=y
977# PCI devices 976# PCI devices
978# 977#
979# CONFIG_SND_AD1889 is not set 978# CONFIG_SND_AD1889 is not set
979# CONFIG_SND_ALS300 is not set
980# CONFIG_SND_ALS4000 is not set 980# CONFIG_SND_ALS4000 is not set
981# CONFIG_SND_ALI5451 is not set 981# CONFIG_SND_ALI5451 is not set
982# CONFIG_SND_ATIIXP is not set 982# CONFIG_SND_ATIIXP is not set
@@ -1009,6 +1009,7 @@ CONFIG_SND_SUPPORT_OLD_API=y
1009# CONFIG_SND_MIXART is not set 1009# CONFIG_SND_MIXART is not set
1010# CONFIG_SND_NM256 is not set 1010# CONFIG_SND_NM256 is not set
1011# CONFIG_SND_PCXHR is not set 1011# CONFIG_SND_PCXHR is not set
1012# CONFIG_SND_RIPTIDE is not set
1012# CONFIG_SND_RME32 is not set 1013# CONFIG_SND_RME32 is not set
1013# CONFIG_SND_RME96 is not set 1014# CONFIG_SND_RME96 is not set
1014# CONFIG_SND_RME9652 is not set 1015# CONFIG_SND_RME9652 is not set
@@ -1041,6 +1042,7 @@ CONFIG_SND_USB_AUDIO=m
1041# 1042#
1042CONFIG_USB_ARCH_HAS_HCD=y 1043CONFIG_USB_ARCH_HAS_HCD=y
1043CONFIG_USB_ARCH_HAS_OHCI=y 1044CONFIG_USB_ARCH_HAS_OHCI=y
1045CONFIG_USB_ARCH_HAS_EHCI=y
1044CONFIG_USB=y 1046CONFIG_USB=y
1045# CONFIG_USB_DEBUG is not set 1047# CONFIG_USB_DEBUG is not set
1046 1048
@@ -1068,7 +1070,6 @@ CONFIG_USB_OHCI_LITTLE_ENDIAN=y
1068# 1070#
1069# USB Device Class drivers 1071# USB Device Class drivers
1070# 1072#
1071# CONFIG_OBSOLETE_OSS_USB_DRIVER is not set
1072CONFIG_USB_ACM=m 1073CONFIG_USB_ACM=m
1073CONFIG_USB_PRINTER=y 1074CONFIG_USB_PRINTER=y
1074 1075
@@ -1126,15 +1127,6 @@ CONFIG_USB_HIDDEV=y
1126# CONFIG_USB_MICROTEK is not set 1127# CONFIG_USB_MICROTEK is not set
1127 1128
1128# 1129#
1129# USB Multimedia devices
1130#
1131# CONFIG_USB_DABUSB is not set
1132
1133#
1134# Video4Linux support is needed for USB Multimedia device support
1135#
1136
1137#
1138# USB Network Adapters 1130# USB Network Adapters
1139# 1131#
1140CONFIG_USB_CATC=m 1132CONFIG_USB_CATC=m
@@ -1194,6 +1186,7 @@ CONFIG_USB_SERIAL_KEYSPAN_USA49WLC=y
1194CONFIG_USB_SERIAL_KLSI=m 1186CONFIG_USB_SERIAL_KLSI=m
1195CONFIG_USB_SERIAL_KOBIL_SCT=m 1187CONFIG_USB_SERIAL_KOBIL_SCT=m
1196CONFIG_USB_SERIAL_MCT_U232=m 1188CONFIG_USB_SERIAL_MCT_U232=m
1189# CONFIG_USB_SERIAL_NAVMAN is not set
1197CONFIG_USB_SERIAL_PL2303=m 1190CONFIG_USB_SERIAL_PL2303=m
1198# CONFIG_USB_SERIAL_HP4X is not set 1191# CONFIG_USB_SERIAL_HP4X is not set
1199CONFIG_USB_SERIAL_SAFE=m 1192CONFIG_USB_SERIAL_SAFE=m
@@ -1237,17 +1230,23 @@ CONFIG_USB_EZUSB=y
1237# CONFIG_MMC is not set 1230# CONFIG_MMC is not set
1238 1231
1239# 1232#
1233# LED devices
1234#
1235# CONFIG_NEW_LEDS is not set
1236
1237#
1240# InfiniBand support 1238# InfiniBand support
1241# 1239#
1242# CONFIG_INFINIBAND is not set 1240# CONFIG_INFINIBAND is not set
1243 1241
1244# 1242#
1245# SN Devices 1243# EDAC - error detection and reporting (RAS) (EXPERIMENTAL)
1246# 1244#
1247 1245
1248# 1246#
1249# EDAC - error detection and reporting (RAS) 1247# Real Time Clock
1250# 1248#
1249# CONFIG_RTC_CLASS is not set
1251 1250
1252# 1251#
1253# File systems 1252# File systems
@@ -1319,7 +1318,6 @@ CONFIG_TMPFS=y
1319CONFIG_HUGETLBFS=y 1318CONFIG_HUGETLBFS=y
1320CONFIG_HUGETLB_PAGE=y 1319CONFIG_HUGETLB_PAGE=y
1321CONFIG_RAMFS=y 1320CONFIG_RAMFS=y
1322# CONFIG_RELAYFS_FS is not set
1323# CONFIG_CONFIGFS_FS is not set 1321# CONFIG_CONFIGFS_FS is not set
1324 1322
1325# 1323#
diff --git a/arch/powerpc/configs/iseries_defconfig b/arch/powerpc/configs/iseries_defconfig
index 1816a46742f6..a95e455a1944 100644
--- a/arch/powerpc/configs/iseries_defconfig
+++ b/arch/powerpc/configs/iseries_defconfig
@@ -1,7 +1,7 @@
1# 1#
2# Automatically generated make config: don't edit 2# Automatically generated make config: don't edit
3# Linux kernel version: 2.6.16-rc6 3# Linux kernel version: 2.6.17-rc1
4# Wed Mar 15 16:19:52 2006 4# Wed Apr 19 11:46:44 2006
5# 5#
6CONFIG_PPC64=y 6CONFIG_PPC64=y
7CONFIG_64BIT=y 7CONFIG_64BIT=y
@@ -9,6 +9,7 @@ CONFIG_PPC_MERGE=y
9CONFIG_MMU=y 9CONFIG_MMU=y
10CONFIG_GENERIC_HARDIRQS=y 10CONFIG_GENERIC_HARDIRQS=y
11CONFIG_RWSEM_XCHGADD_ALGORITHM=y 11CONFIG_RWSEM_XCHGADD_ALGORITHM=y
12CONFIG_GENERIC_HWEIGHT=y
12CONFIG_GENERIC_CALIBRATE_DELAY=y 13CONFIG_GENERIC_CALIBRATE_DELAY=y
13CONFIG_PPC=y 14CONFIG_PPC=y
14CONFIG_EARLY_PRINTK=y 15CONFIG_EARLY_PRINTK=y
@@ -30,6 +31,7 @@ CONFIG_POWER4=y
30CONFIG_PPC_FPU=y 31CONFIG_PPC_FPU=y
31# CONFIG_ALTIVEC is not set 32# CONFIG_ALTIVEC is not set
32CONFIG_PPC_STD_MMU=y 33CONFIG_PPC_STD_MMU=y
34CONFIG_VIRT_CPU_ACCOUNTING=y
33CONFIG_SMP=y 35CONFIG_SMP=y
34CONFIG_NR_CPUS=32 36CONFIG_NR_CPUS=32
35 37
@@ -55,6 +57,7 @@ CONFIG_AUDITSYSCALL=y
55CONFIG_IKCONFIG=y 57CONFIG_IKCONFIG=y
56CONFIG_IKCONFIG_PROC=y 58CONFIG_IKCONFIG_PROC=y
57# CONFIG_CPUSETS is not set 59# CONFIG_CPUSETS is not set
60# CONFIG_RELAY is not set
58CONFIG_INITRAMFS_SOURCE="" 61CONFIG_INITRAMFS_SOURCE=""
59CONFIG_CC_OPTIMIZE_FOR_SIZE=y 62CONFIG_CC_OPTIMIZE_FOR_SIZE=y
60# CONFIG_EMBEDDED is not set 63# CONFIG_EMBEDDED is not set
@@ -69,10 +72,6 @@ CONFIG_BASE_FULL=y
69CONFIG_FUTEX=y 72CONFIG_FUTEX=y
70CONFIG_EPOLL=y 73CONFIG_EPOLL=y
71CONFIG_SHMEM=y 74CONFIG_SHMEM=y
72CONFIG_CC_ALIGN_FUNCTIONS=0
73CONFIG_CC_ALIGN_LABELS=0
74CONFIG_CC_ALIGN_LOOPS=0
75CONFIG_CC_ALIGN_JUMPS=0
76CONFIG_SLAB=y 75CONFIG_SLAB=y
77# CONFIG_TINY_SHMEM is not set 76# CONFIG_TINY_SHMEM is not set
78CONFIG_BASE_SMALL=0 77CONFIG_BASE_SMALL=0
@@ -84,7 +83,6 @@ CONFIG_BASE_SMALL=0
84CONFIG_MODULES=y 83CONFIG_MODULES=y
85CONFIG_MODULE_UNLOAD=y 84CONFIG_MODULE_UNLOAD=y
86# CONFIG_MODULE_FORCE_UNLOAD is not set 85# CONFIG_MODULE_FORCE_UNLOAD is not set
87CONFIG_OBSOLETE_MODPARM=y
88CONFIG_MODVERSIONS=y 86CONFIG_MODVERSIONS=y
89CONFIG_MODULE_SRCVERSION_ALL=y 87CONFIG_MODULE_SRCVERSION_ALL=y
90CONFIG_KMOD=y 88CONFIG_KMOD=y
@@ -93,6 +91,7 @@ CONFIG_STOP_MACHINE=y
93# 91#
94# Block layer 92# Block layer
95# 93#
94# CONFIG_BLK_DEV_IO_TRACE is not set
96 95
97# 96#
98# IO Schedulers 97# IO Schedulers
@@ -165,7 +164,6 @@ CONFIG_GENERIC_ISA_DMA=y
165# CONFIG_PPC_INDIRECT_PCI is not set 164# CONFIG_PPC_INDIRECT_PCI is not set
166CONFIG_PCI=y 165CONFIG_PCI=y
167CONFIG_PCI_DOMAINS=y 166CONFIG_PCI_DOMAINS=y
168CONFIG_PCI_LEGACY_PROC=y
169# CONFIG_PCI_DEBUG is not set 167# CONFIG_PCI_DEBUG is not set
170 168
171# 169#
@@ -207,6 +205,7 @@ CONFIG_SYN_COOKIES=y
207CONFIG_INET_AH=m 205CONFIG_INET_AH=m
208CONFIG_INET_ESP=m 206CONFIG_INET_ESP=m
209CONFIG_INET_IPCOMP=m 207CONFIG_INET_IPCOMP=m
208CONFIG_INET_XFRM_TUNNEL=m
210CONFIG_INET_TUNNEL=y 209CONFIG_INET_TUNNEL=y
211CONFIG_INET_DIAG=y 210CONFIG_INET_DIAG=y
212CONFIG_INET_TCP_DIAG=y 211CONFIG_INET_TCP_DIAG=y
@@ -218,6 +217,8 @@ CONFIG_TCP_CONG_BIC=y
218# 217#
219# CONFIG_IP_VS is not set 218# CONFIG_IP_VS is not set
220# CONFIG_IPV6 is not set 219# CONFIG_IPV6 is not set
220# CONFIG_INET6_XFRM_TUNNEL is not set
221# CONFIG_INET6_TUNNEL is not set
221CONFIG_NETFILTER=y 222CONFIG_NETFILTER=y
222# CONFIG_NETFILTER_DEBUG is not set 223# CONFIG_NETFILTER_DEBUG is not set
223 224
@@ -236,11 +237,14 @@ CONFIG_NETFILTER_XT_MATCH_CONNBYTES=m
236CONFIG_NETFILTER_XT_MATCH_CONNMARK=m 237CONFIG_NETFILTER_XT_MATCH_CONNMARK=m
237CONFIG_NETFILTER_XT_MATCH_CONNTRACK=m 238CONFIG_NETFILTER_XT_MATCH_CONNTRACK=m
238# CONFIG_NETFILTER_XT_MATCH_DCCP is not set 239# CONFIG_NETFILTER_XT_MATCH_DCCP is not set
240# CONFIG_NETFILTER_XT_MATCH_ESP is not set
239CONFIG_NETFILTER_XT_MATCH_HELPER=m 241CONFIG_NETFILTER_XT_MATCH_HELPER=m
240CONFIG_NETFILTER_XT_MATCH_LENGTH=m 242CONFIG_NETFILTER_XT_MATCH_LENGTH=m
241CONFIG_NETFILTER_XT_MATCH_LIMIT=m 243CONFIG_NETFILTER_XT_MATCH_LIMIT=m
242CONFIG_NETFILTER_XT_MATCH_MAC=m 244CONFIG_NETFILTER_XT_MATCH_MAC=m
243CONFIG_NETFILTER_XT_MATCH_MARK=m 245CONFIG_NETFILTER_XT_MATCH_MARK=m
246# CONFIG_NETFILTER_XT_MATCH_POLICY is not set
247# CONFIG_NETFILTER_XT_MATCH_MULTIPORT is not set
244CONFIG_NETFILTER_XT_MATCH_PKTTYPE=m 248CONFIG_NETFILTER_XT_MATCH_PKTTYPE=m
245CONFIG_NETFILTER_XT_MATCH_REALM=m 249CONFIG_NETFILTER_XT_MATCH_REALM=m
246CONFIG_NETFILTER_XT_MATCH_SCTP=m 250CONFIG_NETFILTER_XT_MATCH_SCTP=m
@@ -262,20 +266,19 @@ CONFIG_IP_NF_IRC=m
262CONFIG_IP_NF_TFTP=m 266CONFIG_IP_NF_TFTP=m
263CONFIG_IP_NF_AMANDA=m 267CONFIG_IP_NF_AMANDA=m
264# CONFIG_IP_NF_PPTP is not set 268# CONFIG_IP_NF_PPTP is not set
269# CONFIG_IP_NF_H323 is not set
265CONFIG_IP_NF_QUEUE=m 270CONFIG_IP_NF_QUEUE=m
266CONFIG_IP_NF_IPTABLES=m 271CONFIG_IP_NF_IPTABLES=m
267CONFIG_IP_NF_MATCH_IPRANGE=m 272CONFIG_IP_NF_MATCH_IPRANGE=m
268CONFIG_IP_NF_MATCH_MULTIPORT=m
269CONFIG_IP_NF_MATCH_TOS=m 273CONFIG_IP_NF_MATCH_TOS=m
270CONFIG_IP_NF_MATCH_RECENT=m 274CONFIG_IP_NF_MATCH_RECENT=m
271CONFIG_IP_NF_MATCH_ECN=m 275CONFIG_IP_NF_MATCH_ECN=m
272CONFIG_IP_NF_MATCH_DSCP=m 276CONFIG_IP_NF_MATCH_DSCP=m
273CONFIG_IP_NF_MATCH_AH_ESP=m 277# CONFIG_IP_NF_MATCH_AH is not set
274CONFIG_IP_NF_MATCH_TTL=m 278CONFIG_IP_NF_MATCH_TTL=m
275CONFIG_IP_NF_MATCH_OWNER=m 279CONFIG_IP_NF_MATCH_OWNER=m
276CONFIG_IP_NF_MATCH_ADDRTYPE=m 280CONFIG_IP_NF_MATCH_ADDRTYPE=m
277CONFIG_IP_NF_MATCH_HASHLIMIT=m 281CONFIG_IP_NF_MATCH_HASHLIMIT=m
278CONFIG_IP_NF_MATCH_POLICY=m
279CONFIG_IP_NF_FILTER=m 282CONFIG_IP_NF_FILTER=m
280CONFIG_IP_NF_TARGET_REJECT=m 283CONFIG_IP_NF_TARGET_REJECT=m
281CONFIG_IP_NF_TARGET_LOG=m 284CONFIG_IP_NF_TARGET_LOG=m
@@ -479,6 +482,7 @@ CONFIG_MD_RAID0=y
479CONFIG_MD_RAID1=y 482CONFIG_MD_RAID1=y
480CONFIG_MD_RAID10=m 483CONFIG_MD_RAID10=m
481CONFIG_MD_RAID5=y 484CONFIG_MD_RAID5=y
485# CONFIG_MD_RAID5_RESHAPE is not set
482CONFIG_MD_RAID6=m 486CONFIG_MD_RAID6=m
483CONFIG_MD_MULTIPATH=m 487CONFIG_MD_MULTIPATH=m
484CONFIG_MD_FAULTY=m 488CONFIG_MD_FAULTY=m
@@ -702,7 +706,6 @@ CONFIG_LEGACY_PTY_COUNT=256
702# Watchdog Cards 706# Watchdog Cards
703# 707#
704# CONFIG_WATCHDOG is not set 708# CONFIG_WATCHDOG is not set
705# CONFIG_RTC is not set
706CONFIG_GEN_RTC=y 709CONFIG_GEN_RTC=y
707# CONFIG_GEN_RTC_X is not set 710# CONFIG_GEN_RTC_X is not set
708# CONFIG_DTLK is not set 711# CONFIG_DTLK is not set
@@ -751,10 +754,6 @@ CONFIG_MAX_RAW_DEVS=256
751# 754#
752 755
753# 756#
754# Multimedia Capabilities Port drivers
755#
756
757#
758# Multimedia devices 757# Multimedia devices
759# 758#
760# CONFIG_VIDEO_DEV is not set 759# CONFIG_VIDEO_DEV is not set
@@ -779,6 +778,7 @@ CONFIG_MAX_RAW_DEVS=256
779# 778#
780CONFIG_USB_ARCH_HAS_HCD=y 779CONFIG_USB_ARCH_HAS_HCD=y
781CONFIG_USB_ARCH_HAS_OHCI=y 780CONFIG_USB_ARCH_HAS_OHCI=y
781CONFIG_USB_ARCH_HAS_EHCI=y
782# CONFIG_USB is not set 782# CONFIG_USB is not set
783 783
784# 784#
@@ -796,6 +796,11 @@ CONFIG_USB_ARCH_HAS_OHCI=y
796# CONFIG_MMC is not set 796# CONFIG_MMC is not set
797 797
798# 798#
799# LED devices
800#
801# CONFIG_NEW_LEDS is not set
802
803#
799# InfiniBand support 804# InfiniBand support
800# 805#
801# CONFIG_INFINIBAND is not set 806# CONFIG_INFINIBAND is not set
@@ -805,6 +810,11 @@ CONFIG_USB_ARCH_HAS_OHCI=y
805# 810#
806 811
807# 812#
813# Real Time Clock
814#
815# CONFIG_RTC_CLASS is not set
816
817#
808# File systems 818# File systems
809# 819#
810CONFIG_EXT2_FS=y 820CONFIG_EXT2_FS=y
@@ -878,7 +888,6 @@ CONFIG_TMPFS=y
878# CONFIG_HUGETLBFS is not set 888# CONFIG_HUGETLBFS is not set
879# CONFIG_HUGETLB_PAGE is not set 889# CONFIG_HUGETLB_PAGE is not set
880CONFIG_RAMFS=y 890CONFIG_RAMFS=y
881# CONFIG_RELAYFS_FS is not set
882# CONFIG_CONFIGFS_FS is not set 891# CONFIG_CONFIGFS_FS is not set
883 892
884# 893#
diff --git a/arch/powerpc/configs/pseries_defconfig b/arch/powerpc/configs/pseries_defconfig
index daaf038a1faa..58e68ce09b0f 100644
--- a/arch/powerpc/configs/pseries_defconfig
+++ b/arch/powerpc/configs/pseries_defconfig
@@ -1,7 +1,7 @@
1# 1#
2# Automatically generated make config: don't edit 2# Automatically generated make config: don't edit
3# Linux kernel version: 2.6.16-rc2 3# Linux kernel version: 2.6.17-rc1
4# Fri Feb 10 17:33:32 2006 4# Wed Apr 19 11:48:00 2006
5# 5#
6CONFIG_PPC64=y 6CONFIG_PPC64=y
7CONFIG_64BIT=y 7CONFIG_64BIT=y
@@ -9,6 +9,7 @@ CONFIG_PPC_MERGE=y
9CONFIG_MMU=y 9CONFIG_MMU=y
10CONFIG_GENERIC_HARDIRQS=y 10CONFIG_GENERIC_HARDIRQS=y
11CONFIG_RWSEM_XCHGADD_ALGORITHM=y 11CONFIG_RWSEM_XCHGADD_ALGORITHM=y
12CONFIG_GENERIC_HWEIGHT=y
12CONFIG_GENERIC_CALIBRATE_DELAY=y 13CONFIG_GENERIC_CALIBRATE_DELAY=y
13CONFIG_PPC=y 14CONFIG_PPC=y
14CONFIG_EARLY_PRINTK=y 15CONFIG_EARLY_PRINTK=y
@@ -30,6 +31,7 @@ CONFIG_POWER4=y
30CONFIG_PPC_FPU=y 31CONFIG_PPC_FPU=y
31CONFIG_ALTIVEC=y 32CONFIG_ALTIVEC=y
32CONFIG_PPC_STD_MMU=y 33CONFIG_PPC_STD_MMU=y
34CONFIG_VIRT_CPU_ACCOUNTING=y
33CONFIG_SMP=y 35CONFIG_SMP=y
34CONFIG_NR_CPUS=128 36CONFIG_NR_CPUS=128
35 37
@@ -55,6 +57,7 @@ CONFIG_AUDITSYSCALL=y
55CONFIG_IKCONFIG=y 57CONFIG_IKCONFIG=y
56CONFIG_IKCONFIG_PROC=y 58CONFIG_IKCONFIG_PROC=y
57CONFIG_CPUSETS=y 59CONFIG_CPUSETS=y
60# CONFIG_RELAY is not set
58CONFIG_INITRAMFS_SOURCE="" 61CONFIG_INITRAMFS_SOURCE=""
59CONFIG_CC_OPTIMIZE_FOR_SIZE=y 62CONFIG_CC_OPTIMIZE_FOR_SIZE=y
60# CONFIG_EMBEDDED is not set 63# CONFIG_EMBEDDED is not set
@@ -69,10 +72,6 @@ CONFIG_BASE_FULL=y
69CONFIG_FUTEX=y 72CONFIG_FUTEX=y
70CONFIG_EPOLL=y 73CONFIG_EPOLL=y
71CONFIG_SHMEM=y 74CONFIG_SHMEM=y
72CONFIG_CC_ALIGN_FUNCTIONS=0
73CONFIG_CC_ALIGN_LABELS=0
74CONFIG_CC_ALIGN_LOOPS=0
75CONFIG_CC_ALIGN_JUMPS=0
76CONFIG_SLAB=y 75CONFIG_SLAB=y
77# CONFIG_TINY_SHMEM is not set 76# CONFIG_TINY_SHMEM is not set
78CONFIG_BASE_SMALL=0 77CONFIG_BASE_SMALL=0
@@ -84,7 +83,6 @@ CONFIG_BASE_SMALL=0
84CONFIG_MODULES=y 83CONFIG_MODULES=y
85CONFIG_MODULE_UNLOAD=y 84CONFIG_MODULE_UNLOAD=y
86# CONFIG_MODULE_FORCE_UNLOAD is not set 85# CONFIG_MODULE_FORCE_UNLOAD is not set
87CONFIG_OBSOLETE_MODPARM=y
88CONFIG_MODVERSIONS=y 86CONFIG_MODVERSIONS=y
89CONFIG_MODULE_SRCVERSION_ALL=y 87CONFIG_MODULE_SRCVERSION_ALL=y
90CONFIG_KMOD=y 88CONFIG_KMOD=y
@@ -93,6 +91,7 @@ CONFIG_STOP_MACHINE=y
93# 91#
94# Block layer 92# Block layer
95# 93#
94# CONFIG_BLK_DEV_IO_TRACE is not set
96 95
97# 96#
98# IO Schedulers 97# IO Schedulers
@@ -188,7 +187,6 @@ CONFIG_PPC_I8259=y
188# CONFIG_PPC_INDIRECT_PCI is not set 187# CONFIG_PPC_INDIRECT_PCI is not set
189CONFIG_PCI=y 188CONFIG_PCI=y
190CONFIG_PCI_DOMAINS=y 189CONFIG_PCI_DOMAINS=y
191CONFIG_PCI_LEGACY_PROC=y
192# CONFIG_PCI_DEBUG is not set 190# CONFIG_PCI_DEBUG is not set
193 191
194# 192#
@@ -235,6 +233,7 @@ CONFIG_SYN_COOKIES=y
235CONFIG_INET_AH=m 233CONFIG_INET_AH=m
236CONFIG_INET_ESP=m 234CONFIG_INET_ESP=m
237CONFIG_INET_IPCOMP=m 235CONFIG_INET_IPCOMP=m
236CONFIG_INET_XFRM_TUNNEL=m
238CONFIG_INET_TUNNEL=y 237CONFIG_INET_TUNNEL=y
239CONFIG_INET_DIAG=y 238CONFIG_INET_DIAG=y
240CONFIG_INET_TCP_DIAG=y 239CONFIG_INET_TCP_DIAG=y
@@ -246,6 +245,8 @@ CONFIG_TCP_CONG_BIC=y
246# 245#
247# CONFIG_IP_VS is not set 246# CONFIG_IP_VS is not set
248# CONFIG_IPV6 is not set 247# CONFIG_IPV6 is not set
248# CONFIG_INET6_XFRM_TUNNEL is not set
249# CONFIG_INET6_TUNNEL is not set
249CONFIG_NETFILTER=y 250CONFIG_NETFILTER=y
250# CONFIG_NETFILTER_DEBUG is not set 251# CONFIG_NETFILTER_DEBUG is not set
251 252
@@ -272,6 +273,7 @@ CONFIG_IP_NF_IRC=m
272CONFIG_IP_NF_TFTP=m 273CONFIG_IP_NF_TFTP=m
273CONFIG_IP_NF_AMANDA=m 274CONFIG_IP_NF_AMANDA=m
274# CONFIG_IP_NF_PPTP is not set 275# CONFIG_IP_NF_PPTP is not set
276# CONFIG_IP_NF_H323 is not set
275CONFIG_IP_NF_QUEUE=m 277CONFIG_IP_NF_QUEUE=m
276 278
277# 279#
@@ -519,6 +521,7 @@ CONFIG_MD_RAID0=y
519CONFIG_MD_RAID1=y 521CONFIG_MD_RAID1=y
520CONFIG_MD_RAID10=m 522CONFIG_MD_RAID10=m
521CONFIG_MD_RAID5=y 523CONFIG_MD_RAID5=y
524# CONFIG_MD_RAID5_RESHAPE is not set
522CONFIG_MD_RAID6=m 525CONFIG_MD_RAID6=m
523CONFIG_MD_MULTIPATH=m 526CONFIG_MD_MULTIPATH=m
524CONFIG_MD_FAULTY=m 527CONFIG_MD_FAULTY=m
@@ -750,6 +753,7 @@ CONFIG_HW_CONSOLE=y
750# 753#
751CONFIG_SERIAL_8250=y 754CONFIG_SERIAL_8250=y
752CONFIG_SERIAL_8250_CONSOLE=y 755CONFIG_SERIAL_8250_CONSOLE=y
756CONFIG_SERIAL_8250_PCI=y
753CONFIG_SERIAL_8250_NR_UARTS=4 757CONFIG_SERIAL_8250_NR_UARTS=4
754CONFIG_SERIAL_8250_RUNTIME_UARTS=4 758CONFIG_SERIAL_8250_RUNTIME_UARTS=4
755# CONFIG_SERIAL_8250_EXTENDED is not set 759# CONFIG_SERIAL_8250_EXTENDED is not set
@@ -767,7 +771,9 @@ CONFIG_LEGACY_PTY_COUNT=256
767# CONFIG_PRINTER is not set 771# CONFIG_PRINTER is not set
768# CONFIG_PPDEV is not set 772# CONFIG_PPDEV is not set
769# CONFIG_TIPAR is not set 773# CONFIG_TIPAR is not set
774CONFIG_HVC_DRIVER=y
770CONFIG_HVC_CONSOLE=y 775CONFIG_HVC_CONSOLE=y
776# CONFIG_HVC_RTAS is not set
771CONFIG_HVCS=m 777CONFIG_HVCS=m
772 778
773# 779#
@@ -779,7 +785,6 @@ CONFIG_HVCS=m
779# Watchdog Cards 785# Watchdog Cards
780# 786#
781# CONFIG_WATCHDOG is not set 787# CONFIG_WATCHDOG is not set
782# CONFIG_RTC is not set
783CONFIG_GEN_RTC=y 788CONFIG_GEN_RTC=y
784# CONFIG_GEN_RTC_X is not set 789# CONFIG_GEN_RTC_X is not set
785# CONFIG_DTLK is not set 790# CONFIG_DTLK is not set
@@ -830,7 +835,6 @@ CONFIG_I2C_ALGOBIT=y
830# CONFIG_I2C_PARPORT_LIGHT is not set 835# CONFIG_I2C_PARPORT_LIGHT is not set
831# CONFIG_I2C_PROSAVAGE is not set 836# CONFIG_I2C_PROSAVAGE is not set
832# CONFIG_I2C_SAVAGE4 is not set 837# CONFIG_I2C_SAVAGE4 is not set
833# CONFIG_SCx200_ACB is not set
834# CONFIG_I2C_SIS5595 is not set 838# CONFIG_I2C_SIS5595 is not set
835# CONFIG_I2C_SIS630 is not set 839# CONFIG_I2C_SIS630 is not set
836# CONFIG_I2C_SIS96X is not set 840# CONFIG_I2C_SIS96X is not set
@@ -849,9 +853,7 @@ CONFIG_I2C_ALGOBIT=y
849# CONFIG_SENSORS_PCF8574 is not set 853# CONFIG_SENSORS_PCF8574 is not set
850# CONFIG_SENSORS_PCA9539 is not set 854# CONFIG_SENSORS_PCA9539 is not set
851# CONFIG_SENSORS_PCF8591 is not set 855# CONFIG_SENSORS_PCF8591 is not set
852# CONFIG_SENSORS_RTC8564 is not set
853# CONFIG_SENSORS_MAX6875 is not set 856# CONFIG_SENSORS_MAX6875 is not set
854# CONFIG_RTC_X1205_I2C is not set
855# CONFIG_I2C_DEBUG_CORE is not set 857# CONFIG_I2C_DEBUG_CORE is not set
856# CONFIG_I2C_DEBUG_ALGO is not set 858# CONFIG_I2C_DEBUG_ALGO is not set
857# CONFIG_I2C_DEBUG_BUS is not set 859# CONFIG_I2C_DEBUG_BUS is not set
@@ -879,10 +881,6 @@ CONFIG_I2C_ALGOBIT=y
879# 881#
880 882
881# 883#
882# Multimedia Capabilities Port drivers
883#
884
885#
886# Multimedia devices 884# Multimedia devices
887# 885#
888# CONFIG_VIDEO_DEV is not set 886# CONFIG_VIDEO_DEV is not set
@@ -891,6 +889,7 @@ CONFIG_I2C_ALGOBIT=y
891# Digital Video Broadcasting Devices 889# Digital Video Broadcasting Devices
892# 890#
893# CONFIG_DVB is not set 891# CONFIG_DVB is not set
892# CONFIG_USB_DABUSB is not set
894 893
895# 894#
896# Graphics support 895# Graphics support
@@ -900,6 +899,7 @@ CONFIG_FB_CFB_FILLRECT=y
900CONFIG_FB_CFB_COPYAREA=y 899CONFIG_FB_CFB_COPYAREA=y
901CONFIG_FB_CFB_IMAGEBLIT=y 900CONFIG_FB_CFB_IMAGEBLIT=y
902CONFIG_FB_MACMODES=y 901CONFIG_FB_MACMODES=y
902CONFIG_FB_FIRMWARE_EDID=y
903CONFIG_FB_MODE_HELPERS=y 903CONFIG_FB_MODE_HELPERS=y
904CONFIG_FB_TILEBLITTING=y 904CONFIG_FB_TILEBLITTING=y
905# CONFIG_FB_CIRRUS is not set 905# CONFIG_FB_CIRRUS is not set
@@ -919,7 +919,6 @@ CONFIG_FB_MATROX_MYSTIQUE=y
919CONFIG_FB_MATROX_G=y 919CONFIG_FB_MATROX_G=y
920# CONFIG_FB_MATROX_I2C is not set 920# CONFIG_FB_MATROX_I2C is not set
921CONFIG_FB_MATROX_MULTIHEAD=y 921CONFIG_FB_MATROX_MULTIHEAD=y
922# CONFIG_FB_RADEON_OLD is not set
923CONFIG_FB_RADEON=y 922CONFIG_FB_RADEON=y
924CONFIG_FB_RADEON_I2C=y 923CONFIG_FB_RADEON_I2C=y
925# CONFIG_FB_RADEON_DEBUG is not set 924# CONFIG_FB_RADEON_DEBUG is not set
@@ -968,6 +967,7 @@ CONFIG_LCD_DEVICE=y
968# 967#
969CONFIG_USB_ARCH_HAS_HCD=y 968CONFIG_USB_ARCH_HAS_HCD=y
970CONFIG_USB_ARCH_HAS_OHCI=y 969CONFIG_USB_ARCH_HAS_OHCI=y
970CONFIG_USB_ARCH_HAS_EHCI=y
971CONFIG_USB=y 971CONFIG_USB=y
972# CONFIG_USB_DEBUG is not set 972# CONFIG_USB_DEBUG is not set
973 973
@@ -1048,15 +1048,6 @@ CONFIG_USB_HIDDEV=y
1048# CONFIG_USB_MICROTEK is not set 1048# CONFIG_USB_MICROTEK is not set
1049 1049
1050# 1050#
1051# USB Multimedia devices
1052#
1053# CONFIG_USB_DABUSB is not set
1054
1055#
1056# Video4Linux support is needed for USB Multimedia device support
1057#
1058
1059#
1060# USB Network Adapters 1051# USB Network Adapters
1061# 1052#
1062# CONFIG_USB_CATC is not set 1053# CONFIG_USB_CATC is not set
@@ -1109,6 +1100,11 @@ CONFIG_USB_MON=y
1109# CONFIG_MMC is not set 1100# CONFIG_MMC is not set
1110 1101
1111# 1102#
1103# LED devices
1104#
1105# CONFIG_NEW_LEDS is not set
1106
1107#
1112# InfiniBand support 1108# InfiniBand support
1113# 1109#
1114CONFIG_INFINIBAND=m 1110CONFIG_INFINIBAND=m
@@ -1121,12 +1117,13 @@ CONFIG_INFINIBAND_IPOIB=m
1121# CONFIG_INFINIBAND_SRP is not set 1117# CONFIG_INFINIBAND_SRP is not set
1122 1118
1123# 1119#
1124# SN Devices 1120# EDAC - error detection and reporting (RAS) (EXPERIMENTAL)
1125# 1121#
1126 1122
1127# 1123#
1128# EDAC - error detection and reporting (RAS) 1124# Real Time Clock
1129# 1125#
1126# CONFIG_RTC_CLASS is not set
1130 1127
1131# 1128#
1132# File systems 1129# File systems
@@ -1202,7 +1199,6 @@ CONFIG_TMPFS=y
1202CONFIG_HUGETLBFS=y 1199CONFIG_HUGETLBFS=y
1203CONFIG_HUGETLB_PAGE=y 1200CONFIG_HUGETLB_PAGE=y
1204CONFIG_RAMFS=y 1201CONFIG_RAMFS=y
1205# CONFIG_RELAYFS_FS is not set
1206# CONFIG_CONFIGFS_FS is not set 1202# CONFIG_CONFIGFS_FS is not set
1207 1203
1208# 1204#
diff --git a/arch/powerpc/kernel/Makefile b/arch/powerpc/kernel/Makefile
index 0cc0995b81b0..803858e86160 100644
--- a/arch/powerpc/kernel/Makefile
+++ b/arch/powerpc/kernel/Makefile
@@ -20,7 +20,7 @@ obj-$(CONFIG_PPC64) += setup_64.o binfmt_elf32.o sys_ppc32.o \
20 firmware.o sysfs.o 20 firmware.o sysfs.o
21obj-$(CONFIG_PPC64) += vdso64/ 21obj-$(CONFIG_PPC64) += vdso64/
22obj-$(CONFIG_ALTIVEC) += vecemu.o vector.o 22obj-$(CONFIG_ALTIVEC) += vecemu.o vector.o
23obj-$(CONFIG_POWER4) += idle_power4.o 23obj-$(CONFIG_PPC_970_NAP) += idle_power4.o
24obj-$(CONFIG_PPC_OF) += of_device.o prom_parse.o 24obj-$(CONFIG_PPC_OF) += of_device.o prom_parse.o
25procfs-$(CONFIG_PPC64) := proc_ppc64.o 25procfs-$(CONFIG_PPC64) := proc_ppc64.o
26obj-$(CONFIG_PROC_FS) += $(procfs-y) 26obj-$(CONFIG_PROC_FS) += $(procfs-y)
diff --git a/arch/powerpc/kernel/asm-offsets.c b/arch/powerpc/kernel/asm-offsets.c
index 54b48f330051..8f85c5e8a55a 100644
--- a/arch/powerpc/kernel/asm-offsets.c
+++ b/arch/powerpc/kernel/asm-offsets.c
@@ -91,6 +91,7 @@ int main(void)
91#endif /* CONFIG_PPC64 */ 91#endif /* CONFIG_PPC64 */
92 92
93 DEFINE(TI_FLAGS, offsetof(struct thread_info, flags)); 93 DEFINE(TI_FLAGS, offsetof(struct thread_info, flags));
94 DEFINE(TI_LOCAL_FLAGS, offsetof(struct thread_info, local_flags));
94 DEFINE(TI_PREEMPT, offsetof(struct thread_info, preempt_count)); 95 DEFINE(TI_PREEMPT, offsetof(struct thread_info, preempt_count));
95 DEFINE(TI_TASK, offsetof(struct thread_info, task)); 96 DEFINE(TI_TASK, offsetof(struct thread_info, task));
96#ifdef CONFIG_PPC32 97#ifdef CONFIG_PPC32
diff --git a/arch/powerpc/kernel/entry_32.S b/arch/powerpc/kernel/entry_32.S
index b3a979467225..8866fd26c6b9 100644
--- a/arch/powerpc/kernel/entry_32.S
+++ b/arch/powerpc/kernel/entry_32.S
@@ -128,37 +128,36 @@ transfer_to_handler:
128 stw r12,4(r11) 128 stw r12,4(r11)
129#endif 129#endif
130 b 3f 130 b 3f
131
1312: /* if from kernel, check interrupted DOZE/NAP mode and 1322: /* if from kernel, check interrupted DOZE/NAP mode and
132 * check for stack overflow 133 * check for stack overflow
133 */ 134 */
135 lwz r9,THREAD_INFO-THREAD(r12)
136 cmplw r1,r9 /* if r1 <= current->thread_info */
137 ble- stack_ovf /* then the kernel stack overflowed */
1385:
134#ifdef CONFIG_6xx 139#ifdef CONFIG_6xx
135 mfspr r11,SPRN_HID0 140 tophys(r9,r9) /* check local flags */
136 mtcr r11 141 lwz r12,TI_LOCAL_FLAGS(r9)
137BEGIN_FTR_SECTION 142 mtcrf 0x01,r12
138 bt- 8,4f /* Check DOZE */ 143 bt- 31-TLF_NAPPING,4f
139END_FTR_SECTION_IFSET(CPU_FTR_CAN_DOZE)
140BEGIN_FTR_SECTION
141 bt- 9,4f /* Check NAP */
142END_FTR_SECTION_IFSET(CPU_FTR_CAN_NAP)
143#endif /* CONFIG_6xx */ 144#endif /* CONFIG_6xx */
144 .globl transfer_to_handler_cont 145 .globl transfer_to_handler_cont
145transfer_to_handler_cont: 146transfer_to_handler_cont:
146 lwz r11,THREAD_INFO-THREAD(r12)
147 cmplw r1,r11 /* if r1 <= current->thread_info */
148 ble- stack_ovf /* then the kernel stack overflowed */
1493: 1473:
150 mflr r9 148 mflr r9
151 lwz r11,0(r9) /* virtual address of handler */ 149 lwz r11,0(r9) /* virtual address of handler */
152 lwz r9,4(r9) /* where to go when done */ 150 lwz r9,4(r9) /* where to go when done */
153 FIX_SRR1(r10,r12)
154 mtspr SPRN_SRR0,r11 151 mtspr SPRN_SRR0,r11
155 mtspr SPRN_SRR1,r10 152 mtspr SPRN_SRR1,r10
156 mtlr r9 153 mtlr r9
157 SYNC 154 SYNC
158 RFI /* jump to handler, enable MMU */ 155 RFI /* jump to handler, enable MMU */
159 156
160#ifdef CONFIG_6xx 157#ifdef CONFIG_6xx
1614: b power_save_6xx_restore 1584: rlwinm r12,r12,0,~_TLF_NAPPING
159 stw r12,TI_LOCAL_FLAGS(r9)
160 b power_save_6xx_restore
162#endif 161#endif
163 162
164/* 163/*
@@ -167,10 +166,10 @@ transfer_to_handler_cont:
167 */ 166 */
168stack_ovf: 167stack_ovf:
169 /* sometimes we use a statically-allocated stack, which is OK. */ 168 /* sometimes we use a statically-allocated stack, which is OK. */
170 lis r11,_end@h 169 lis r12,_end@h
171 ori r11,r11,_end@l 170 ori r12,r12,_end@l
172 cmplw r1,r11 171 cmplw r1,r12
173 ble 3b /* r1 <= &_end is OK */ 172 ble 5b /* r1 <= &_end is OK */
174 SAVE_NVGPRS(r11) 173 SAVE_NVGPRS(r11)
175 addi r3,r1,STACK_FRAME_OVERHEAD 174 addi r3,r1,STACK_FRAME_OVERHEAD
176 lis r1,init_thread_union@ha 175 lis r1,init_thread_union@ha
diff --git a/arch/powerpc/kernel/head_64.S b/arch/powerpc/kernel/head_64.S
index a5ae04a57c78..b7d140430a41 100644
--- a/arch/powerpc/kernel/head_64.S
+++ b/arch/powerpc/kernel/head_64.S
@@ -376,11 +376,28 @@ label##_common: \
376 bl hdlr; \ 376 bl hdlr; \
377 b .ret_from_except 377 b .ret_from_except
378 378
379/*
380 * Like STD_EXCEPTION_COMMON, but for exceptions that can occur
381 * in the idle task and therefore need the special idle handling.
382 */
383#define STD_EXCEPTION_COMMON_IDLE(trap, label, hdlr) \
384 .align 7; \
385 .globl label##_common; \
386label##_common: \
387 EXCEPTION_PROLOG_COMMON(trap, PACA_EXGEN); \
388 FINISH_NAP; \
389 DISABLE_INTS; \
390 bl .save_nvgprs; \
391 addi r3,r1,STACK_FRAME_OVERHEAD; \
392 bl hdlr; \
393 b .ret_from_except
394
379#define STD_EXCEPTION_COMMON_LITE(trap, label, hdlr) \ 395#define STD_EXCEPTION_COMMON_LITE(trap, label, hdlr) \
380 .align 7; \ 396 .align 7; \
381 .globl label##_common; \ 397 .globl label##_common; \
382label##_common: \ 398label##_common: \
383 EXCEPTION_PROLOG_COMMON(trap, PACA_EXGEN); \ 399 EXCEPTION_PROLOG_COMMON(trap, PACA_EXGEN); \
400 FINISH_NAP; \
384 DISABLE_INTS; \ 401 DISABLE_INTS; \
385 bl .ppc64_runlatch_on; \ 402 bl .ppc64_runlatch_on; \
386 addi r3,r1,STACK_FRAME_OVERHEAD; \ 403 addi r3,r1,STACK_FRAME_OVERHEAD; \
@@ -388,6 +405,25 @@ label##_common: \
388 b .ret_from_except_lite 405 b .ret_from_except_lite
389 406
390/* 407/*
408 * When the idle code in power4_idle puts the CPU into NAP mode,
409 * it has to do so in a loop, and relies on the external interrupt
410 * and decrementer interrupt entry code to get it out of the loop.
411 * It sets the _TLF_NAPPING bit in current_thread_info()->local_flags
412 * to signal that it is in the loop and needs help to get out.
413 */
414#ifdef CONFIG_PPC_970_NAP
415#define FINISH_NAP \
416BEGIN_FTR_SECTION \
417 clrrdi r11,r1,THREAD_SHIFT; \
418 ld r9,TI_LOCAL_FLAGS(r11); \
419 andi. r10,r9,_TLF_NAPPING; \
420 bnel power4_fixup_nap; \
421END_FTR_SECTION_IFSET(CPU_FTR_CAN_NAP)
422#else
423#define FINISH_NAP
424#endif
425
426/*
391 * Start of pSeries system interrupt routines 427 * Start of pSeries system interrupt routines
392 */ 428 */
393 . = 0x100 429 . = 0x100
@@ -772,6 +808,7 @@ hardware_interrupt_iSeries_masked:
772 .globl machine_check_common 808 .globl machine_check_common
773machine_check_common: 809machine_check_common:
774 EXCEPTION_PROLOG_COMMON(0x200, PACA_EXMC) 810 EXCEPTION_PROLOG_COMMON(0x200, PACA_EXMC)
811 FINISH_NAP
775 DISABLE_INTS 812 DISABLE_INTS
776 bl .save_nvgprs 813 bl .save_nvgprs
777 addi r3,r1,STACK_FRAME_OVERHEAD 814 addi r3,r1,STACK_FRAME_OVERHEAD
@@ -783,7 +820,7 @@ machine_check_common:
783 STD_EXCEPTION_COMMON(0xb00, trap_0b, .unknown_exception) 820 STD_EXCEPTION_COMMON(0xb00, trap_0b, .unknown_exception)
784 STD_EXCEPTION_COMMON(0xd00, single_step, .single_step_exception) 821 STD_EXCEPTION_COMMON(0xd00, single_step, .single_step_exception)
785 STD_EXCEPTION_COMMON(0xe00, trap_0e, .unknown_exception) 822 STD_EXCEPTION_COMMON(0xe00, trap_0e, .unknown_exception)
786 STD_EXCEPTION_COMMON(0xf00, performance_monitor, .performance_monitor_exception) 823 STD_EXCEPTION_COMMON_IDLE(0xf00, performance_monitor, .performance_monitor_exception)
787 STD_EXCEPTION_COMMON(0x1300, instruction_breakpoint, .instruction_breakpoint_exception) 824 STD_EXCEPTION_COMMON(0x1300, instruction_breakpoint, .instruction_breakpoint_exception)
788#ifdef CONFIG_ALTIVEC 825#ifdef CONFIG_ALTIVEC
789 STD_EXCEPTION_COMMON(0x1700, altivec_assist, .altivec_assist_exception) 826 STD_EXCEPTION_COMMON(0x1700, altivec_assist, .altivec_assist_exception)
@@ -1034,6 +1071,7 @@ unrecov_slb:
1034 .globl hardware_interrupt_entry 1071 .globl hardware_interrupt_entry
1035hardware_interrupt_common: 1072hardware_interrupt_common:
1036 EXCEPTION_PROLOG_COMMON(0x500, PACA_EXGEN) 1073 EXCEPTION_PROLOG_COMMON(0x500, PACA_EXGEN)
1074 FINISH_NAP
1037hardware_interrupt_entry: 1075hardware_interrupt_entry:
1038 DISABLE_INTS 1076 DISABLE_INTS
1039 bl .ppc64_runlatch_on 1077 bl .ppc64_runlatch_on
@@ -1041,6 +1079,15 @@ hardware_interrupt_entry:
1041 bl .do_IRQ 1079 bl .do_IRQ
1042 b .ret_from_except_lite 1080 b .ret_from_except_lite
1043 1081
1082#ifdef CONFIG_PPC_970_NAP
1083power4_fixup_nap:
1084 andc r9,r9,r10
1085 std r9,TI_LOCAL_FLAGS(r11)
1086 ld r10,_LINK(r1) /* make idle task do the */
1087 std r10,_NIP(r1) /* equivalent of a blr */
1088 blr
1089#endif
1090
1044 .align 7 1091 .align 7
1045 .globl alignment_common 1092 .globl alignment_common
1046alignment_common: 1093alignment_common:
diff --git a/arch/powerpc/kernel/idle.c b/arch/powerpc/kernel/idle.c
index e9f321d74d85..d491052c8e0c 100644
--- a/arch/powerpc/kernel/idle.c
+++ b/arch/powerpc/kernel/idle.c
@@ -50,9 +50,9 @@ void cpu_idle(void)
50 50
51 set_thread_flag(TIF_POLLING_NRFLAG); 51 set_thread_flag(TIF_POLLING_NRFLAG);
52 while (1) { 52 while (1) {
53 ppc64_runlatch_off();
54
55 while (!need_resched() && !cpu_should_die()) { 53 while (!need_resched() && !cpu_should_die()) {
54 ppc64_runlatch_off();
55
56 if (ppc_md.power_save) { 56 if (ppc_md.power_save) {
57 clear_thread_flag(TIF_POLLING_NRFLAG); 57 clear_thread_flag(TIF_POLLING_NRFLAG);
58 /* 58 /*
diff --git a/arch/powerpc/kernel/idle_6xx.S b/arch/powerpc/kernel/idle_6xx.S
index 12a4efbaa08f..b45fa0e37212 100644
--- a/arch/powerpc/kernel/idle_6xx.S
+++ b/arch/powerpc/kernel/idle_6xx.S
@@ -22,8 +22,6 @@
22#include <asm/ppc_asm.h> 22#include <asm/ppc_asm.h>
23#include <asm/asm-offsets.h> 23#include <asm/asm-offsets.h>
24 24
25#undef DEBUG
26
27 .text 25 .text
28 26
29/* 27/*
@@ -109,12 +107,6 @@ BEGIN_FTR_SECTION
109 dcbf 0,r4 107 dcbf 0,r4
110 dcbf 0,r4 108 dcbf 0,r4
111END_FTR_SECTION_IFSET(CPU_FTR_NAP_DISABLE_L2_PR) 109END_FTR_SECTION_IFSET(CPU_FTR_NAP_DISABLE_L2_PR)
112#ifdef DEBUG
113 lis r6,nap_enter_count@ha
114 lwz r4,nap_enter_count@l(r6)
115 addi r4,r4,1
116 stw r4,nap_enter_count@l(r6)
117#endif
1182: 1102:
119BEGIN_FTR_SECTION 111BEGIN_FTR_SECTION
120 /* Go to low speed mode on some 750FX */ 112 /* Go to low speed mode on some 750FX */
@@ -144,48 +136,42 @@ BEGIN_FTR_SECTION
144 DSSALL 136 DSSALL
145 sync 137 sync
146END_FTR_SECTION_IFSET(CPU_FTR_ALTIVEC) 138END_FTR_SECTION_IFSET(CPU_FTR_ALTIVEC)
139 rlwinm r9,r1,0,0,31-THREAD_SHIFT /* current thread_info */
140 lwz r8,TI_LOCAL_FLAGS(r9) /* set napping bit */
141 ori r8,r8,_TLF_NAPPING /* so when we take an exception */
142 stw r8,TI_LOCAL_FLAGS(r9) /* it will return to our caller */
147 mfmsr r7 143 mfmsr r7
148 ori r7,r7,MSR_EE 144 ori r7,r7,MSR_EE
149 oris r7,r7,MSR_POW@h 145 oris r7,r7,MSR_POW@h
150 sync 1461: sync
151 isync
152 mtmsr r7 147 mtmsr r7
153 isync 148 isync
154 sync 149 b 1b
155 blr 150
156
157/* 151/*
158 * Return from NAP/DOZE mode, restore some CPU specific registers, 152 * Return from NAP/DOZE mode, restore some CPU specific registers,
159 * we are called with DR/IR still off and r2 containing physical 153 * we are called with DR/IR still off and r2 containing physical
160 * address of current. 154 * address of current. R11 points to the exception frame (physical
155 * address). We have to preserve r10.
161 */ 156 */
162_GLOBAL(power_save_6xx_restore) 157_GLOBAL(power_save_6xx_restore)
163 mfspr r11,SPRN_HID0 158 lwz r9,_LINK(r11) /* interrupted in ppc6xx_idle: */
164 rlwinm. r11,r11,0,10,8 /* Clear NAP & copy NAP bit !state to cr1 EQ */ 159 stw r9,_NIP(r11) /* make it do a blr */
165 cror 4*cr1+eq,4*cr0+eq,4*cr0+eq
166BEGIN_FTR_SECTION
167 rlwinm r11,r11,0,9,7 /* Clear DOZE */
168END_FTR_SECTION_IFSET(CPU_FTR_CAN_DOZE)
169 mtspr SPRN_HID0, r11
170 160
171#ifdef DEBUG 161#ifdef CONFIG_SMP
172 beq cr1,1f 162 mfspr r12,SPRN_SPRG3
173 lis r11,(nap_return_count-KERNELBASE)@ha 163 lwz r11,TI_CPU(r12) /* get cpu number * 4 */
174 lwz r9,nap_return_count@l(r11)
175 addi r9,r9,1
176 stw r9,nap_return_count@l(r11)
1771:
178#endif
179
180 rlwinm r9,r1,0,0,18
181 tophys(r9,r9)
182 lwz r11,TI_CPU(r9)
183 slwi r11,r11,2 164 slwi r11,r11,2
165#else
166 li r11,0
167#endif
184 /* Todo make sure all these are in the same page 168 /* Todo make sure all these are in the same page
185 * and load r22 (@ha part + CPU offset) only once 169 * and load r11 (@ha part + CPU offset) only once
186 */ 170 */
187BEGIN_FTR_SECTION 171BEGIN_FTR_SECTION
188 beq cr1,1f 172 mfspr r9,SPRN_HID0
173 andis. r9,r9,HID0_NAP@h
174 beq 1f
189 addis r9,r11,(nap_save_msscr0-KERNELBASE)@ha 175 addis r9,r11,(nap_save_msscr0-KERNELBASE)@ha
190 lwz r9,nap_save_msscr0@l(r9) 176 lwz r9,nap_save_msscr0@l(r9)
191 mtspr SPRN_MSSCR0, r9 177 mtspr SPRN_MSSCR0, r9
@@ -210,10 +196,3 @@ _GLOBAL(nap_save_hid1)
210 196
211_GLOBAL(powersave_lowspeed) 197_GLOBAL(powersave_lowspeed)
212 .long 0 198 .long 0
213
214#ifdef DEBUG
215_GLOBAL(nap_enter_count)
216 .space 4
217_GLOBAL(nap_return_count)
218 .space 4
219#endif
diff --git a/arch/powerpc/kernel/idle_power4.S b/arch/powerpc/kernel/idle_power4.S
index 6dad1c02496e..d85c7c938eed 100644
--- a/arch/powerpc/kernel/idle_power4.S
+++ b/arch/powerpc/kernel/idle_power4.S
@@ -35,12 +35,16 @@ BEGIN_FTR_SECTION
35 DSSALL 35 DSSALL
36 sync 36 sync
37END_FTR_SECTION_IFSET(CPU_FTR_ALTIVEC) 37END_FTR_SECTION_IFSET(CPU_FTR_ALTIVEC)
38 clrrdi r9,r1,THREAD_SHIFT /* current thread_info */
39 ld r8,TI_LOCAL_FLAGS(r9) /* set napping bit */
40 ori r8,r8,_TLF_NAPPING /* so when we take an exception */
41 std r8,TI_LOCAL_FLAGS(r9) /* it will return to our caller */
38 mfmsr r7 42 mfmsr r7
39 ori r7,r7,MSR_EE 43 ori r7,r7,MSR_EE
40 oris r7,r7,MSR_POW@h 44 oris r7,r7,MSR_POW@h
41 sync 451: sync
42 isync 46 isync
43 mtmsrd r7 47 mtmsrd r7
44 isync 48 isync
45 sync 49 b 1b
46 blr 50
diff --git a/arch/powerpc/kernel/iommu.c b/arch/powerpc/kernel/iommu.c
index d9a7fdef59b9..4eba60a32890 100644
--- a/arch/powerpc/kernel/iommu.c
+++ b/arch/powerpc/kernel/iommu.c
@@ -61,6 +61,7 @@ __setup("iommu=", setup_iommu);
61static unsigned long iommu_range_alloc(struct iommu_table *tbl, 61static unsigned long iommu_range_alloc(struct iommu_table *tbl,
62 unsigned long npages, 62 unsigned long npages,
63 unsigned long *handle, 63 unsigned long *handle,
64 unsigned long mask,
64 unsigned int align_order) 65 unsigned int align_order)
65{ 66{
66 unsigned long n, end, i, start; 67 unsigned long n, end, i, start;
@@ -97,9 +98,21 @@ static unsigned long iommu_range_alloc(struct iommu_table *tbl,
97 */ 98 */
98 if (start >= limit) 99 if (start >= limit)
99 start = largealloc ? tbl->it_largehint : tbl->it_hint; 100 start = largealloc ? tbl->it_largehint : tbl->it_hint;
100 101
101 again: 102 again:
102 103
104 if (limit + tbl->it_offset > mask) {
105 limit = mask - tbl->it_offset + 1;
106 /* If we're constrained on address range, first try
107 * at the masked hint to avoid O(n) search complexity,
108 * but on second pass, start at 0.
109 */
110 if ((start & mask) >= limit || pass > 0)
111 start = 0;
112 else
113 start &= mask;
114 }
115
103 n = find_next_zero_bit(tbl->it_map, limit, start); 116 n = find_next_zero_bit(tbl->it_map, limit, start);
104 117
105 /* Align allocation */ 118 /* Align allocation */
@@ -150,14 +163,14 @@ static unsigned long iommu_range_alloc(struct iommu_table *tbl,
150 163
151static dma_addr_t iommu_alloc(struct iommu_table *tbl, void *page, 164static dma_addr_t iommu_alloc(struct iommu_table *tbl, void *page,
152 unsigned int npages, enum dma_data_direction direction, 165 unsigned int npages, enum dma_data_direction direction,
153 unsigned int align_order) 166 unsigned long mask, unsigned int align_order)
154{ 167{
155 unsigned long entry, flags; 168 unsigned long entry, flags;
156 dma_addr_t ret = DMA_ERROR_CODE; 169 dma_addr_t ret = DMA_ERROR_CODE;
157 170
158 spin_lock_irqsave(&(tbl->it_lock), flags); 171 spin_lock_irqsave(&(tbl->it_lock), flags);
159 172
160 entry = iommu_range_alloc(tbl, npages, NULL, align_order); 173 entry = iommu_range_alloc(tbl, npages, NULL, mask, align_order);
161 174
162 if (unlikely(entry == DMA_ERROR_CODE)) { 175 if (unlikely(entry == DMA_ERROR_CODE)) {
163 spin_unlock_irqrestore(&(tbl->it_lock), flags); 176 spin_unlock_irqrestore(&(tbl->it_lock), flags);
@@ -236,7 +249,7 @@ static void iommu_free(struct iommu_table *tbl, dma_addr_t dma_addr,
236 249
237int iommu_map_sg(struct device *dev, struct iommu_table *tbl, 250int iommu_map_sg(struct device *dev, struct iommu_table *tbl,
238 struct scatterlist *sglist, int nelems, 251 struct scatterlist *sglist, int nelems,
239 enum dma_data_direction direction) 252 unsigned long mask, enum dma_data_direction direction)
240{ 253{
241 dma_addr_t dma_next = 0, dma_addr; 254 dma_addr_t dma_next = 0, dma_addr;
242 unsigned long flags; 255 unsigned long flags;
@@ -274,7 +287,7 @@ int iommu_map_sg(struct device *dev, struct iommu_table *tbl,
274 vaddr = (unsigned long)page_address(s->page) + s->offset; 287 vaddr = (unsigned long)page_address(s->page) + s->offset;
275 npages = PAGE_ALIGN(vaddr + slen) - (vaddr & PAGE_MASK); 288 npages = PAGE_ALIGN(vaddr + slen) - (vaddr & PAGE_MASK);
276 npages >>= PAGE_SHIFT; 289 npages >>= PAGE_SHIFT;
277 entry = iommu_range_alloc(tbl, npages, &handle, 0); 290 entry = iommu_range_alloc(tbl, npages, &handle, mask >> PAGE_SHIFT, 0);
278 291
279 DBG(" - vaddr: %lx, size: %lx\n", vaddr, slen); 292 DBG(" - vaddr: %lx, size: %lx\n", vaddr, slen);
280 293
@@ -479,7 +492,8 @@ void iommu_free_table(struct device_node *dn)
479 * byte within the page as vaddr. 492 * byte within the page as vaddr.
480 */ 493 */
481dma_addr_t iommu_map_single(struct iommu_table *tbl, void *vaddr, 494dma_addr_t iommu_map_single(struct iommu_table *tbl, void *vaddr,
482 size_t size, enum dma_data_direction direction) 495 size_t size, unsigned long mask,
496 enum dma_data_direction direction)
483{ 497{
484 dma_addr_t dma_handle = DMA_ERROR_CODE; 498 dma_addr_t dma_handle = DMA_ERROR_CODE;
485 unsigned long uaddr; 499 unsigned long uaddr;
@@ -492,7 +506,8 @@ dma_addr_t iommu_map_single(struct iommu_table *tbl, void *vaddr,
492 npages >>= PAGE_SHIFT; 506 npages >>= PAGE_SHIFT;
493 507
494 if (tbl) { 508 if (tbl) {
495 dma_handle = iommu_alloc(tbl, vaddr, npages, direction, 0); 509 dma_handle = iommu_alloc(tbl, vaddr, npages, direction,
510 mask >> PAGE_SHIFT, 0);
496 if (dma_handle == DMA_ERROR_CODE) { 511 if (dma_handle == DMA_ERROR_CODE) {
497 if (printk_ratelimit()) { 512 if (printk_ratelimit()) {
498 printk(KERN_INFO "iommu_alloc failed, " 513 printk(KERN_INFO "iommu_alloc failed, "
@@ -521,7 +536,7 @@ void iommu_unmap_single(struct iommu_table *tbl, dma_addr_t dma_handle,
521 * to the dma address (mapping) of the first page. 536 * to the dma address (mapping) of the first page.
522 */ 537 */
523void *iommu_alloc_coherent(struct iommu_table *tbl, size_t size, 538void *iommu_alloc_coherent(struct iommu_table *tbl, size_t size,
524 dma_addr_t *dma_handle, gfp_t flag) 539 dma_addr_t *dma_handle, unsigned long mask, gfp_t flag)
525{ 540{
526 void *ret = NULL; 541 void *ret = NULL;
527 dma_addr_t mapping; 542 dma_addr_t mapping;
@@ -551,7 +566,8 @@ void *iommu_alloc_coherent(struct iommu_table *tbl, size_t size,
551 memset(ret, 0, size); 566 memset(ret, 0, size);
552 567
553 /* Set up tces to cover the allocated range */ 568 /* Set up tces to cover the allocated range */
554 mapping = iommu_alloc(tbl, ret, npages, DMA_BIDIRECTIONAL, order); 569 mapping = iommu_alloc(tbl, ret, npages, DMA_BIDIRECTIONAL,
570 mask >> PAGE_SHIFT, order);
555 if (mapping == DMA_ERROR_CODE) { 571 if (mapping == DMA_ERROR_CODE) {
556 free_pages((unsigned long)ret, order); 572 free_pages((unsigned long)ret, order);
557 ret = NULL; 573 ret = NULL;
diff --git a/arch/powerpc/kernel/irq.c b/arch/powerpc/kernel/irq.c
index bb5c9501234c..57d560c68897 100644
--- a/arch/powerpc/kernel/irq.c
+++ b/arch/powerpc/kernel/irq.c
@@ -272,18 +272,26 @@ unsigned int virt_irq_to_real_map[NR_IRQS];
272 * Don't use virtual irqs 0, 1, 2 for devices. 272 * Don't use virtual irqs 0, 1, 2 for devices.
273 * The pcnet32 driver considers interrupt numbers < 2 to be invalid, 273 * The pcnet32 driver considers interrupt numbers < 2 to be invalid,
274 * and 2 is the XICS IPI interrupt. 274 * and 2 is the XICS IPI interrupt.
275 * We limit virtual irqs to 17 less than NR_IRQS so that when we 275 * We limit virtual irqs to __irq_offet_value less than virt_irq_max so
276 * offset them by 16 (to reserve the first 16 for ISA interrupts) 276 * that when we offset them we don't end up with an interrupt
277 * we don't end up with an interrupt number >= NR_IRQS. 277 * number >= virt_irq_max.
278 */ 278 */
279#define MIN_VIRT_IRQ 3 279#define MIN_VIRT_IRQ 3
280#define MAX_VIRT_IRQ (NR_IRQS - NUM_ISA_INTERRUPTS - 1) 280
281#define NR_VIRT_IRQS (MAX_VIRT_IRQ - MIN_VIRT_IRQ + 1) 281unsigned int virt_irq_max;
282static unsigned int max_virt_irq;
283static unsigned int nr_virt_irqs;
282 284
283void 285void
284virt_irq_init(void) 286virt_irq_init(void)
285{ 287{
286 int i; 288 int i;
289
290 if ((virt_irq_max == 0) || (virt_irq_max > (NR_IRQS - 1)))
291 virt_irq_max = NR_IRQS - 1;
292 max_virt_irq = virt_irq_max - __irq_offset_value;
293 nr_virt_irqs = max_virt_irq - MIN_VIRT_IRQ + 1;
294
287 for (i = 0; i < NR_IRQS; i++) 295 for (i = 0; i < NR_IRQS; i++)
288 virt_irq_to_real_map[i] = UNDEFINED_IRQ; 296 virt_irq_to_real_map[i] = UNDEFINED_IRQ;
289} 297}
@@ -308,17 +316,17 @@ int virt_irq_create_mapping(unsigned int real_irq)
308 return real_irq; 316 return real_irq;
309 } 317 }
310 318
311 /* map to a number between MIN_VIRT_IRQ and MAX_VIRT_IRQ */ 319 /* map to a number between MIN_VIRT_IRQ and max_virt_irq */
312 virq = real_irq; 320 virq = real_irq;
313 if (virq > MAX_VIRT_IRQ) 321 if (virq > max_virt_irq)
314 virq = (virq % NR_VIRT_IRQS) + MIN_VIRT_IRQ; 322 virq = (virq % nr_virt_irqs) + MIN_VIRT_IRQ;
315 323
316 /* search for this number or a free slot */ 324 /* search for this number or a free slot */
317 first_virq = virq; 325 first_virq = virq;
318 while (virt_irq_to_real_map[virq] != UNDEFINED_IRQ) { 326 while (virt_irq_to_real_map[virq] != UNDEFINED_IRQ) {
319 if (virt_irq_to_real_map[virq] == real_irq) 327 if (virt_irq_to_real_map[virq] == real_irq)
320 return virq; 328 return virq;
321 if (++virq > MAX_VIRT_IRQ) 329 if (++virq > max_virt_irq)
322 virq = MIN_VIRT_IRQ; 330 virq = MIN_VIRT_IRQ;
323 if (virq == first_virq) 331 if (virq == first_virq)
324 goto nospace; /* oops, no free slots */ 332 goto nospace; /* oops, no free slots */
@@ -330,8 +338,8 @@ int virt_irq_create_mapping(unsigned int real_irq)
330 nospace: 338 nospace:
331 if (!warned) { 339 if (!warned) {
332 printk(KERN_CRIT "Interrupt table is full\n"); 340 printk(KERN_CRIT "Interrupt table is full\n");
333 printk(KERN_CRIT "Increase NR_IRQS (currently %d) " 341 printk(KERN_CRIT "Increase virt_irq_max (currently %d) "
334 "in your kernel sources and rebuild.\n", NR_IRQS); 342 "in your kernel sources and rebuild.\n", virt_irq_max);
335 warned = 1; 343 warned = 1;
336 } 344 }
337 return NO_IRQ; 345 return NO_IRQ;
@@ -349,8 +357,8 @@ unsigned int real_irq_to_virt_slowpath(unsigned int real_irq)
349 357
350 virq = real_irq; 358 virq = real_irq;
351 359
352 if (virq > MAX_VIRT_IRQ) 360 if (virq > max_virt_irq)
353 virq = (virq % NR_VIRT_IRQS) + MIN_VIRT_IRQ; 361 virq = (virq % nr_virt_irqs) + MIN_VIRT_IRQ;
354 362
355 first_virq = virq; 363 first_virq = virq;
356 364
@@ -360,7 +368,7 @@ unsigned int real_irq_to_virt_slowpath(unsigned int real_irq)
360 368
361 virq++; 369 virq++;
362 370
363 if (virq >= MAX_VIRT_IRQ) 371 if (virq >= max_virt_irq)
364 virq = 0; 372 virq = 0;
365 373
366 } while (first_virq != virq); 374 } while (first_virq != virq);
diff --git a/arch/powerpc/kernel/kprobes.c b/arch/powerpc/kernel/kprobes.c
index ad7a90212204..856ef1a832b9 100644
--- a/arch/powerpc/kernel/kprobes.c
+++ b/arch/powerpc/kernel/kprobes.c
@@ -88,7 +88,7 @@ void __kprobes arch_remove_kprobe(struct kprobe *p)
88 mutex_unlock(&kprobe_mutex); 88 mutex_unlock(&kprobe_mutex);
89} 89}
90 90
91static inline void prepare_singlestep(struct kprobe *p, struct pt_regs *regs) 91static void __kprobes prepare_singlestep(struct kprobe *p, struct pt_regs *regs)
92{ 92{
93 kprobe_opcode_t insn = *p->ainsn.insn; 93 kprobe_opcode_t insn = *p->ainsn.insn;
94 94
@@ -101,21 +101,21 @@ static inline void prepare_singlestep(struct kprobe *p, struct pt_regs *regs)
101 regs->nip = (unsigned long)p->ainsn.insn; 101 regs->nip = (unsigned long)p->ainsn.insn;
102} 102}
103 103
104static inline void save_previous_kprobe(struct kprobe_ctlblk *kcb) 104static void __kprobes save_previous_kprobe(struct kprobe_ctlblk *kcb)
105{ 105{
106 kcb->prev_kprobe.kp = kprobe_running(); 106 kcb->prev_kprobe.kp = kprobe_running();
107 kcb->prev_kprobe.status = kcb->kprobe_status; 107 kcb->prev_kprobe.status = kcb->kprobe_status;
108 kcb->prev_kprobe.saved_msr = kcb->kprobe_saved_msr; 108 kcb->prev_kprobe.saved_msr = kcb->kprobe_saved_msr;
109} 109}
110 110
111static inline void restore_previous_kprobe(struct kprobe_ctlblk *kcb) 111static void __kprobes restore_previous_kprobe(struct kprobe_ctlblk *kcb)
112{ 112{
113 __get_cpu_var(current_kprobe) = kcb->prev_kprobe.kp; 113 __get_cpu_var(current_kprobe) = kcb->prev_kprobe.kp;
114 kcb->kprobe_status = kcb->prev_kprobe.status; 114 kcb->kprobe_status = kcb->prev_kprobe.status;
115 kcb->kprobe_saved_msr = kcb->prev_kprobe.saved_msr; 115 kcb->kprobe_saved_msr = kcb->prev_kprobe.saved_msr;
116} 116}
117 117
118static inline void set_current_kprobe(struct kprobe *p, struct pt_regs *regs, 118static void __kprobes set_current_kprobe(struct kprobe *p, struct pt_regs *regs,
119 struct kprobe_ctlblk *kcb) 119 struct kprobe_ctlblk *kcb)
120{ 120{
121 __get_cpu_var(current_kprobe) = p; 121 __get_cpu_var(current_kprobe) = p;
@@ -141,7 +141,7 @@ void __kprobes arch_prepare_kretprobe(struct kretprobe *rp,
141 } 141 }
142} 142}
143 143
144static inline int kprobe_handler(struct pt_regs *regs) 144static int __kprobes kprobe_handler(struct pt_regs *regs)
145{ 145{
146 struct kprobe *p; 146 struct kprobe *p;
147 int ret = 0; 147 int ret = 0;
@@ -334,7 +334,7 @@ static void __kprobes resume_execution(struct kprobe *p, struct pt_regs *regs)
334 regs->nip = (unsigned long)p->addr + 4; 334 regs->nip = (unsigned long)p->addr + 4;
335} 335}
336 336
337static inline int post_kprobe_handler(struct pt_regs *regs) 337static int __kprobes post_kprobe_handler(struct pt_regs *regs)
338{ 338{
339 struct kprobe *cur = kprobe_running(); 339 struct kprobe *cur = kprobe_running();
340 struct kprobe_ctlblk *kcb = get_kprobe_ctlblk(); 340 struct kprobe_ctlblk *kcb = get_kprobe_ctlblk();
@@ -370,7 +370,7 @@ out:
370 return 1; 370 return 1;
371} 371}
372 372
373static inline int kprobe_fault_handler(struct pt_regs *regs, int trapnr) 373static int __kprobes kprobe_fault_handler(struct pt_regs *regs, int trapnr)
374{ 374{
375 struct kprobe *cur = kprobe_running(); 375 struct kprobe *cur = kprobe_running();
376 struct kprobe_ctlblk *kcb = get_kprobe_ctlblk(); 376 struct kprobe_ctlblk *kcb = get_kprobe_ctlblk();
diff --git a/arch/powerpc/kernel/pci_iommu.c b/arch/powerpc/kernel/pci_iommu.c
index c336f3e31cff..c1d95e14bbed 100644
--- a/arch/powerpc/kernel/pci_iommu.c
+++ b/arch/powerpc/kernel/pci_iommu.c
@@ -59,6 +59,25 @@ static inline struct iommu_table *devnode_table(struct device *dev)
59} 59}
60 60
61 61
62static inline unsigned long device_to_mask(struct device *hwdev)
63{
64 struct pci_dev *pdev;
65
66 if (!hwdev) {
67 pdev = ppc64_isabridge_dev;
68 if (!pdev) /* This is the best guess we can do */
69 return 0xfffffffful;
70 } else
71 pdev = to_pci_dev(hwdev);
72
73 if (pdev->dma_mask)
74 return pdev->dma_mask;
75
76 /* Assume devices without mask can take 32 bit addresses */
77 return 0xfffffffful;
78}
79
80
62/* Allocates a contiguous real buffer and creates mappings over it. 81/* Allocates a contiguous real buffer and creates mappings over it.
63 * Returns the virtual address of the buffer and sets dma_handle 82 * Returns the virtual address of the buffer and sets dma_handle
64 * to the dma address (mapping) of the first page. 83 * to the dma address (mapping) of the first page.
@@ -67,7 +86,7 @@ static void *pci_iommu_alloc_coherent(struct device *hwdev, size_t size,
67 dma_addr_t *dma_handle, gfp_t flag) 86 dma_addr_t *dma_handle, gfp_t flag)
68{ 87{
69 return iommu_alloc_coherent(devnode_table(hwdev), size, dma_handle, 88 return iommu_alloc_coherent(devnode_table(hwdev), size, dma_handle,
70 flag); 89 device_to_mask(hwdev), flag);
71} 90}
72 91
73static void pci_iommu_free_coherent(struct device *hwdev, size_t size, 92static void pci_iommu_free_coherent(struct device *hwdev, size_t size,
@@ -85,7 +104,8 @@ static void pci_iommu_free_coherent(struct device *hwdev, size_t size,
85static dma_addr_t pci_iommu_map_single(struct device *hwdev, void *vaddr, 104static dma_addr_t pci_iommu_map_single(struct device *hwdev, void *vaddr,
86 size_t size, enum dma_data_direction direction) 105 size_t size, enum dma_data_direction direction)
87{ 106{
88 return iommu_map_single(devnode_table(hwdev), vaddr, size, direction); 107 return iommu_map_single(devnode_table(hwdev), vaddr, size,
108 device_to_mask(hwdev), direction);
89} 109}
90 110
91 111
@@ -100,7 +120,7 @@ static int pci_iommu_map_sg(struct device *pdev, struct scatterlist *sglist,
100 int nelems, enum dma_data_direction direction) 120 int nelems, enum dma_data_direction direction)
101{ 121{
102 return iommu_map_sg(pdev, devnode_table(pdev), sglist, 122 return iommu_map_sg(pdev, devnode_table(pdev), sglist,
103 nelems, direction); 123 nelems, device_to_mask(pdev), direction);
104} 124}
105 125
106static void pci_iommu_unmap_sg(struct device *pdev, struct scatterlist *sglist, 126static void pci_iommu_unmap_sg(struct device *pdev, struct scatterlist *sglist,
@@ -112,7 +132,19 @@ static void pci_iommu_unmap_sg(struct device *pdev, struct scatterlist *sglist,
112/* We support DMA to/from any memory page via the iommu */ 132/* We support DMA to/from any memory page via the iommu */
113static int pci_iommu_dma_supported(struct device *dev, u64 mask) 133static int pci_iommu_dma_supported(struct device *dev, u64 mask)
114{ 134{
115 return 1; 135 struct iommu_table *tbl = devnode_table(dev);
136
137 if (!tbl || tbl->it_offset > mask) {
138 printk(KERN_INFO "Warning: IOMMU table offset too big for device mask\n");
139 if (tbl)
140 printk(KERN_INFO "mask: 0x%08lx, table offset: 0x%08lx\n",
141 mask, tbl->it_offset);
142 else
143 printk(KERN_INFO "mask: 0x%08lx, table unavailable\n",
144 mask);
145 return 0;
146 } else
147 return 1;
116} 148}
117 149
118void pci_iommu_init(void) 150void pci_iommu_init(void)
diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c
index 4336390bcf34..1cb69e8fb0b1 100644
--- a/arch/powerpc/kernel/prom.c
+++ b/arch/powerpc/kernel/prom.c
@@ -62,7 +62,7 @@ static int __initdata dt_root_addr_cells;
62static int __initdata dt_root_size_cells; 62static int __initdata dt_root_size_cells;
63 63
64#ifdef CONFIG_PPC64 64#ifdef CONFIG_PPC64
65static int __initdata iommu_is_off; 65int __initdata iommu_is_off;
66int __initdata iommu_force_on; 66int __initdata iommu_force_on;
67unsigned long tce_alloc_start, tce_alloc_end; 67unsigned long tce_alloc_start, tce_alloc_end;
68#endif 68#endif
diff --git a/arch/powerpc/kernel/prom_init.c b/arch/powerpc/kernel/prom_init.c
index d66c5e77fcff..7e4d54821a07 100644
--- a/arch/powerpc/kernel/prom_init.c
+++ b/arch/powerpc/kernel/prom_init.c
@@ -1528,12 +1528,11 @@ static int __init prom_find_machine_type(void)
1528 * non-IBM designs ! 1528 * non-IBM designs !
1529 * - it has /rtas 1529 * - it has /rtas
1530 */ 1530 */
1531 len = prom_getprop(_prom->root, "model", 1531 len = prom_getprop(_prom->root, "device_type",
1532 compat, sizeof(compat)-1); 1532 compat, sizeof(compat)-1);
1533 if (len <= 0) 1533 if (len <= 0)
1534 return PLATFORM_GENERIC; 1534 return PLATFORM_GENERIC;
1535 compat[len] = 0; 1535 if (strncmp(compat, RELOC("chrp"), 4))
1536 if (strcmp(compat, "chrp"))
1537 return PLATFORM_GENERIC; 1536 return PLATFORM_GENERIC;
1538 1537
1539 /* Default to pSeries. We need to know if we are running LPAR */ 1538 /* Default to pSeries. We need to know if we are running LPAR */
diff --git a/arch/powerpc/kernel/rtas-proc.c b/arch/powerpc/kernel/rtas-proc.c
index 456286cf1d14..9c9ad1fa9cce 100644
--- a/arch/powerpc/kernel/rtas-proc.c
+++ b/arch/powerpc/kernel/rtas-proc.c
@@ -258,11 +258,11 @@ static int __init proc_rtas_init(void)
258 struct proc_dir_entry *entry; 258 struct proc_dir_entry *entry;
259 259
260 if (!machine_is(pseries)) 260 if (!machine_is(pseries))
261 return 1; 261 return -ENODEV;
262 262
263 rtas_node = of_find_node_by_name(NULL, "rtas"); 263 rtas_node = of_find_node_by_name(NULL, "rtas");
264 if (rtas_node == NULL) 264 if (rtas_node == NULL)
265 return 1; 265 return -ENODEV;
266 266
267 entry = create_proc_entry("ppc64/rtas/progress", S_IRUGO|S_IWUSR, NULL); 267 entry = create_proc_entry("ppc64/rtas/progress", S_IRUGO|S_IWUSR, NULL);
268 if (entry) 268 if (entry)
diff --git a/arch/powerpc/kernel/systbl.S b/arch/powerpc/kernel/systbl.S
index 1424eab450ee..8d1522690501 100644
--- a/arch/powerpc/kernel/systbl.S
+++ b/arch/powerpc/kernel/systbl.S
@@ -323,3 +323,9 @@ COMPAT_SYS(pselect6)
323COMPAT_SYS(ppoll) 323COMPAT_SYS(ppoll)
324SYSCALL(unshare) 324SYSCALL(unshare)
325SYSCALL(splice) 325SYSCALL(splice)
326SYSCALL(tee)
327
328/*
329 * please add new calls to arch/powerpc/platforms/cell/spu_callbacks.c
330 * as well when appropriate.
331 */
diff --git a/arch/powerpc/kernel/vio.c b/arch/powerpc/kernel/vio.c
index 13c655ba2841..971020cf3f7d 100644
--- a/arch/powerpc/kernel/vio.c
+++ b/arch/powerpc/kernel/vio.c
@@ -202,7 +202,7 @@ static dma_addr_t vio_map_single(struct device *dev, void *vaddr,
202 size_t size, enum dma_data_direction direction) 202 size_t size, enum dma_data_direction direction)
203{ 203{
204 return iommu_map_single(to_vio_dev(dev)->iommu_table, vaddr, size, 204 return iommu_map_single(to_vio_dev(dev)->iommu_table, vaddr, size,
205 direction); 205 ~0ul, direction);
206} 206}
207 207
208static void vio_unmap_single(struct device *dev, dma_addr_t dma_handle, 208static void vio_unmap_single(struct device *dev, dma_addr_t dma_handle,
@@ -216,7 +216,7 @@ static int vio_map_sg(struct device *dev, struct scatterlist *sglist,
216 int nelems, enum dma_data_direction direction) 216 int nelems, enum dma_data_direction direction)
217{ 217{
218 return iommu_map_sg(dev, to_vio_dev(dev)->iommu_table, sglist, 218 return iommu_map_sg(dev, to_vio_dev(dev)->iommu_table, sglist,
219 nelems, direction); 219 nelems, ~0ul, direction);
220} 220}
221 221
222static void vio_unmap_sg(struct device *dev, struct scatterlist *sglist, 222static void vio_unmap_sg(struct device *dev, struct scatterlist *sglist,
@@ -229,7 +229,7 @@ static void *vio_alloc_coherent(struct device *dev, size_t size,
229 dma_addr_t *dma_handle, gfp_t flag) 229 dma_addr_t *dma_handle, gfp_t flag)
230{ 230{
231 return iommu_alloc_coherent(to_vio_dev(dev)->iommu_table, size, 231 return iommu_alloc_coherent(to_vio_dev(dev)->iommu_table, size,
232 dma_handle, flag); 232 dma_handle, ~0ul, flag);
233} 233}
234 234
235static void vio_free_coherent(struct device *dev, size_t size, 235static void vio_free_coherent(struct device *dev, size_t size,
diff --git a/arch/powerpc/platforms/cell/spu_callbacks.c b/arch/powerpc/platforms/cell/spu_callbacks.c
index 6594bec73882..deb3afb94484 100644
--- a/arch/powerpc/platforms/cell/spu_callbacks.c
+++ b/arch/powerpc/platforms/cell/spu_callbacks.c
@@ -317,17 +317,16 @@ void *spu_syscall_table[] = {
317 [__NR_ppoll] sys_ni_syscall, /* sys_ppoll */ 317 [__NR_ppoll] sys_ni_syscall, /* sys_ppoll */
318 [__NR_unshare] sys_unshare, 318 [__NR_unshare] sys_unshare,
319 [__NR_splice] sys_splice, 319 [__NR_splice] sys_splice,
320 [__NR_tee] sys_tee,
320}; 321};
321 322
322long spu_sys_callback(struct spu_syscall_block *s) 323long spu_sys_callback(struct spu_syscall_block *s)
323{ 324{
324 long (*syscall)(u64 a1, u64 a2, u64 a3, u64 a4, u64 a5, u64 a6); 325 long (*syscall)(u64 a1, u64 a2, u64 a3, u64 a4, u64 a5, u64 a6);
325 326
326 BUILD_BUG_ON(ARRAY_SIZE(spu_syscall_table) != __NR_syscalls);
327
328 syscall = spu_syscall_table[s->nr_ret]; 327 syscall = spu_syscall_table[s->nr_ret];
329 328
330 if (s->nr_ret >= __NR_syscalls) { 329 if (s->nr_ret >= ARRAY_SIZE(spu_syscall_table)) {
331 pr_debug("%s: invalid syscall #%ld", __FUNCTION__, s->nr_ret); 330 pr_debug("%s: invalid syscall #%ld", __FUNCTION__, s->nr_ret);
332 return -ENOSYS; 331 return -ENOSYS;
333 } 332 }
diff --git a/arch/powerpc/platforms/cell/spufs/switch.c b/arch/powerpc/platforms/cell/spufs/switch.c
index 97898d5d34e5..1726bfe38ee0 100644
--- a/arch/powerpc/platforms/cell/spufs/switch.c
+++ b/arch/powerpc/platforms/cell/spufs/switch.c
@@ -1297,7 +1297,7 @@ static inline void setup_decr(struct spu_state *csa, struct spu *spu)
1297 cycles_t resume_time = get_cycles(); 1297 cycles_t resume_time = get_cycles();
1298 cycles_t delta_time = resume_time - csa->suspend_time; 1298 cycles_t delta_time = resume_time - csa->suspend_time;
1299 1299
1300 csa->lscsa->decr.slot[0] = delta_time; 1300 csa->lscsa->decr.slot[0] -= delta_time;
1301 } 1301 }
1302} 1302}
1303 1303
diff --git a/arch/powerpc/platforms/chrp/chrp.h b/arch/powerpc/platforms/chrp/chrp.h
index 63f0aee4c158..996c28744e96 100644
--- a/arch/powerpc/platforms/chrp/chrp.h
+++ b/arch/powerpc/platforms/chrp/chrp.h
@@ -9,3 +9,4 @@ extern long chrp_time_init(void);
9 9
10extern void chrp_find_bridges(void); 10extern void chrp_find_bridges(void);
11extern void chrp_event_scan(unsigned long); 11extern void chrp_event_scan(unsigned long);
12extern void chrp_pcibios_fixup(void);
diff --git a/arch/powerpc/platforms/chrp/pci.c b/arch/powerpc/platforms/chrp/pci.c
index 8ef279ad36ad..ac224876ce59 100644
--- a/arch/powerpc/platforms/chrp/pci.c
+++ b/arch/powerpc/platforms/chrp/pci.c
@@ -23,6 +23,8 @@
23#include <asm/grackle.h> 23#include <asm/grackle.h>
24#include <asm/rtas.h> 24#include <asm/rtas.h>
25 25
26#include "chrp.h"
27
26/* LongTrail */ 28/* LongTrail */
27void __iomem *gg2_pci_config_base; 29void __iomem *gg2_pci_config_base;
28 30
@@ -314,6 +316,6 @@ chrp_find_bridges(void)
314 } 316 }
315 317
316 /* Do not fixup interrupts from OF tree on pegasos */ 318 /* Do not fixup interrupts from OF tree on pegasos */
317 if (is_pegasos == 0) 319 if (is_pegasos)
318 ppc_md.pcibios_fixup = chrp_pcibios_fixup; 320 ppc_md.pcibios_fixup = NULL;
319} 321}
diff --git a/arch/powerpc/platforms/chrp/setup.c b/arch/powerpc/platforms/chrp/setup.c
index 23a201718704..18d89f38796b 100644
--- a/arch/powerpc/platforms/chrp/setup.c
+++ b/arch/powerpc/platforms/chrp/setup.c
@@ -440,8 +440,6 @@ void __init chrp_init_IRQ(void)
440 440
441 if (_chrp_type == _CHRP_Pegasos) 441 if (_chrp_type == _CHRP_Pegasos)
442 ppc_md.get_irq = i8259_irq; 442 ppc_md.get_irq = i8259_irq;
443 else
444 ppc_md.get_irq = mpic_get_irq;
445 443
446#if defined(CONFIG_VT) && defined(CONFIG_INPUT_ADBHID) && defined(XMON) 444#if defined(CONFIG_VT) && defined(CONFIG_INPUT_ADBHID) && defined(XMON)
447 /* see if there is a keyboard in the device tree 445 /* see if there is a keyboard in the device tree
@@ -528,26 +526,24 @@ static int __init chrp_probe(void)
528 /* Assume we have an 8259... */ 526 /* Assume we have an 8259... */
529 __irq_offset_value = NUM_ISA_INTERRUPTS; 527 __irq_offset_value = NUM_ISA_INTERRUPTS;
530 528
531 ppc_md.setup_arch = chrp_setup_arch; 529 return 1;
532 ppc_md.show_cpuinfo = chrp_show_cpuinfo;
533
534 ppc_md.init_IRQ = chrp_init_IRQ;
535 ppc_md.init = chrp_init2;
536
537 ppc_md.phys_mem_access_prot = pci_phys_mem_access_prot;
538
539 ppc_md.restart = rtas_restart;
540 ppc_md.power_off = rtas_power_off;
541 ppc_md.halt = rtas_halt;
542
543 ppc_md.time_init = chrp_time_init;
544 ppc_md.calibrate_decr = generic_calibrate_decr;
545
546 /* this may get overridden with rtas routines later... */
547 ppc_md.set_rtc_time = chrp_set_rtc_time;
548 ppc_md.get_rtc_time = chrp_get_rtc_time;
549
550#ifdef CONFIG_SMP
551 smp_ops = &chrp_smp_ops;
552#endif /* CONFIG_SMP */
553} 530}
531
532define_machine(chrp) {
533 .name = "CHRP",
534 .probe = chrp_probe,
535 .setup_arch = chrp_setup_arch,
536 .init = chrp_init2,
537 .show_cpuinfo = chrp_show_cpuinfo,
538 .init_IRQ = chrp_init_IRQ,
539 .get_irq = mpic_get_irq,
540 .pcibios_fixup = chrp_pcibios_fixup,
541 .restart = rtas_restart,
542 .power_off = rtas_power_off,
543 .halt = rtas_halt,
544 .time_init = chrp_time_init,
545 .set_rtc_time = chrp_set_rtc_time,
546 .get_rtc_time = chrp_get_rtc_time,
547 .calibrate_decr = generic_calibrate_decr,
548 .phys_mem_access_prot = pci_phys_mem_access_prot,
549};
diff --git a/arch/powerpc/platforms/iseries/setup.c b/arch/powerpc/platforms/iseries/setup.c
index 6ce8a404ba6b..a6fd9bedb074 100644
--- a/arch/powerpc/platforms/iseries/setup.c
+++ b/arch/powerpc/platforms/iseries/setup.c
@@ -54,6 +54,7 @@
54#include <asm/iseries/hv_lp_event.h> 54#include <asm/iseries/hv_lp_event.h>
55#include <asm/iseries/lpar_map.h> 55#include <asm/iseries/lpar_map.h>
56#include <asm/udbg.h> 56#include <asm/udbg.h>
57#include <asm/irq.h>
57 58
58#include "naca.h" 59#include "naca.h"
59#include "setup.h" 60#include "setup.h"
@@ -684,6 +685,12 @@ static int __init iseries_probe(void)
684 powerpc_firmware_features |= FW_FEATURE_ISERIES; 685 powerpc_firmware_features |= FW_FEATURE_ISERIES;
685 powerpc_firmware_features |= FW_FEATURE_LPAR; 686 powerpc_firmware_features |= FW_FEATURE_LPAR;
686 687
688 /*
689 * The Hypervisor only allows us up to 256 interrupt
690 * sources (the irq number is passed in a u8).
691 */
692 virt_irq_max = 255;
693
687 return 1; 694 return 1;
688} 695}
689 696
diff --git a/arch/powerpc/platforms/powermac/low_i2c.c b/arch/powerpc/platforms/powermac/low_i2c.c
index e14f9ac55cf4..df2343e1956b 100644
--- a/arch/powerpc/platforms/powermac/low_i2c.c
+++ b/arch/powerpc/platforms/powermac/low_i2c.c
@@ -231,6 +231,14 @@ static u8 kw_i2c_wait_interrupt(struct pmac_i2c_host_kw *host)
231 return isr; 231 return isr;
232} 232}
233 233
234static void kw_i2c_do_stop(struct pmac_i2c_host_kw *host, int result)
235{
236 kw_write_reg(reg_control, KW_I2C_CTL_STOP);
237 host->state = state_stop;
238 host->result = result;
239}
240
241
234static void kw_i2c_handle_interrupt(struct pmac_i2c_host_kw *host, u8 isr) 242static void kw_i2c_handle_interrupt(struct pmac_i2c_host_kw *host, u8 isr)
235{ 243{
236 u8 ack; 244 u8 ack;
@@ -246,42 +254,36 @@ static void kw_i2c_handle_interrupt(struct pmac_i2c_host_kw *host, u8 isr)
246 } 254 }
247 255
248 if (isr == 0) { 256 if (isr == 0) {
257 printk(KERN_WARNING "low_i2c: Timeout in i2c transfer"
258 " on keywest !\n");
249 if (host->state != state_stop) { 259 if (host->state != state_stop) {
250 DBG_LOW("KW: Timeout !\n"); 260 kw_i2c_do_stop(host, -EIO);
251 host->result = -EIO; 261 return;
252 goto stop;
253 }
254 if (host->state == state_stop) {
255 ack = kw_read_reg(reg_status);
256 if (ack & KW_I2C_STAT_BUSY)
257 kw_write_reg(reg_status, 0);
258 host->state = state_idle;
259 kw_write_reg(reg_ier, 0x00);
260 if (!host->polled)
261 complete(&host->complete);
262 } 262 }
263 ack = kw_read_reg(reg_status);
264 if (ack & KW_I2C_STAT_BUSY)
265 kw_write_reg(reg_status, 0);
266 host->state = state_idle;
267 kw_write_reg(reg_ier, 0x00);
268 if (!host->polled)
269 complete(&host->complete);
263 return; 270 return;
264 } 271 }
265 272
266 if (isr & KW_I2C_IRQ_ADDR) { 273 if (isr & KW_I2C_IRQ_ADDR) {
267 ack = kw_read_reg(reg_status); 274 ack = kw_read_reg(reg_status);
268 if (host->state != state_addr) { 275 if (host->state != state_addr) {
269 kw_write_reg(reg_isr, KW_I2C_IRQ_ADDR);
270 WRONG_STATE("KW_I2C_IRQ_ADDR"); 276 WRONG_STATE("KW_I2C_IRQ_ADDR");
271 host->result = -EIO; 277 kw_i2c_do_stop(host, -EIO);
272 goto stop;
273 } 278 }
274 if ((ack & KW_I2C_STAT_LAST_AAK) == 0) { 279 if ((ack & KW_I2C_STAT_LAST_AAK) == 0) {
275 host->result = -ENODEV; 280 host->result = -ENXIO;
276 DBG_LOW("KW: NAK on address\n");
277 host->state = state_stop; 281 host->state = state_stop;
278 return; 282 DBG_LOW("KW: NAK on address\n");
279 } else { 283 } else {
280 if (host->len == 0) { 284 if (host->len == 0)
281 kw_write_reg(reg_isr, KW_I2C_IRQ_ADDR); 285 kw_i2c_do_stop(host, 0);
282 goto stop; 286 else if (host->rw) {
283 }
284 if (host->rw) {
285 host->state = state_read; 287 host->state = state_read;
286 if (host->len > 1) 288 if (host->len > 1)
287 kw_write_reg(reg_control, 289 kw_write_reg(reg_control,
@@ -308,25 +310,19 @@ static void kw_i2c_handle_interrupt(struct pmac_i2c_host_kw *host, u8 isr)
308 ack = kw_read_reg(reg_status); 310 ack = kw_read_reg(reg_status);
309 if ((ack & KW_I2C_STAT_LAST_AAK) == 0) { 311 if ((ack & KW_I2C_STAT_LAST_AAK) == 0) {
310 DBG_LOW("KW: nack on data write\n"); 312 DBG_LOW("KW: nack on data write\n");
311 host->result = -EIO; 313 host->result = -EFBIG;
312 goto stop; 314 host->state = state_stop;
313 } else if (host->len) { 315 } else if (host->len) {
314 kw_write_reg(reg_data, *(host->data++)); 316 kw_write_reg(reg_data, *(host->data++));
315 host->len--; 317 host->len--;
316 } else { 318 } else
317 kw_write_reg(reg_control, KW_I2C_CTL_STOP); 319 kw_i2c_do_stop(host, 0);
318 host->state = state_stop;
319 host->result = 0;
320 }
321 kw_write_reg(reg_isr, KW_I2C_IRQ_DATA);
322 } else { 320 } else {
323 kw_write_reg(reg_isr, KW_I2C_IRQ_DATA);
324 WRONG_STATE("KW_I2C_IRQ_DATA"); 321 WRONG_STATE("KW_I2C_IRQ_DATA");
325 if (host->state != state_stop) { 322 if (host->state != state_stop)
326 host->result = -EIO; 323 kw_i2c_do_stop(host, -EIO);
327 goto stop;
328 }
329 } 324 }
325 kw_write_reg(reg_isr, KW_I2C_IRQ_DATA);
330 } 326 }
331 327
332 if (isr & KW_I2C_IRQ_STOP) { 328 if (isr & KW_I2C_IRQ_STOP) {
@@ -340,14 +336,10 @@ static void kw_i2c_handle_interrupt(struct pmac_i2c_host_kw *host, u8 isr)
340 complete(&host->complete); 336 complete(&host->complete);
341 } 337 }
342 338
339 /* Below should only happen in manual mode which we don't use ... */
343 if (isr & KW_I2C_IRQ_START) 340 if (isr & KW_I2C_IRQ_START)
344 kw_write_reg(reg_isr, KW_I2C_IRQ_START); 341 kw_write_reg(reg_isr, KW_I2C_IRQ_START);
345 342
346 return;
347 stop:
348 kw_write_reg(reg_control, KW_I2C_CTL_STOP);
349 host->state = state_stop;
350 return;
351} 343}
352 344
353/* Interrupt handler */ 345/* Interrupt handler */
@@ -544,11 +536,11 @@ static struct pmac_i2c_host_kw *__init kw_i2c_host_init(struct device_node *np)
544 return NULL; 536 return NULL;
545 } 537 }
546 538
547 /* Make sure IRA is disabled */ 539 /* Make sure IRQ is disabled */
548 kw_write_reg(reg_ier, 0); 540 kw_write_reg(reg_ier, 0);
549 541
550 /* Request chip interrupt */ 542 /* Request chip interrupt */
551 if (request_irq(host->irq, kw_i2c_irq, SA_SHIRQ, "keywest i2c", host)) 543 if (request_irq(host->irq, kw_i2c_irq, 0, "keywest i2c", host))
552 host->irq = NO_IRQ; 544 host->irq = NO_IRQ;
553 545
554 printk(KERN_INFO "KeyWest i2c @0x%08x irq %d %s\n", 546 printk(KERN_INFO "KeyWest i2c @0x%08x irq %d %s\n",
diff --git a/arch/powerpc/platforms/pseries/eeh.c b/arch/powerpc/platforms/pseries/eeh.c
index 780fb27a0099..32eaddfa5470 100644
--- a/arch/powerpc/platforms/pseries/eeh.c
+++ b/arch/powerpc/platforms/pseries/eeh.c
@@ -957,8 +957,10 @@ static void eeh_remove_device(struct pci_dev *dev)
957 pci_addr_cache_remove_device(dev); 957 pci_addr_cache_remove_device(dev);
958 958
959 dn = pci_device_to_OF_node(dev); 959 dn = pci_device_to_OF_node(dev);
960 PCI_DN(dn)->pcidev = NULL; 960 if (PCI_DN(dn)->pcidev) {
961 pci_dev_put (dev); 961 PCI_DN(dn)->pcidev = NULL;
962 pci_dev_put (dev);
963 }
962} 964}
963 965
964void eeh_remove_bus_device(struct pci_dev *dev) 966void eeh_remove_bus_device(struct pci_dev *dev)
diff --git a/arch/powerpc/platforms/pseries/rtasd.c b/arch/powerpc/platforms/pseries/rtasd.c
index fcc4d561a236..e0000ce769e5 100644
--- a/arch/powerpc/platforms/pseries/rtasd.c
+++ b/arch/powerpc/platforms/pseries/rtasd.c
@@ -488,7 +488,7 @@ static int __init rtas_init(void)
488 /* No RTAS */ 488 /* No RTAS */
489 if (rtas_token("event-scan") == RTAS_UNKNOWN_SERVICE) { 489 if (rtas_token("event-scan") == RTAS_UNKNOWN_SERVICE) {
490 printk(KERN_INFO "rtasd: no event-scan on system\n"); 490 printk(KERN_INFO "rtasd: no event-scan on system\n");
491 return 1; 491 return -ENODEV;
492 } 492 }
493 493
494 entry = create_proc_entry("ppc64/rtas/error_log", S_IRUSR, NULL); 494 entry = create_proc_entry("ppc64/rtas/error_log", S_IRUSR, NULL);
diff --git a/arch/powerpc/sysdev/dart_iommu.c b/arch/powerpc/sysdev/dart_iommu.c
index 61d317428610..38087bd6e3cf 100644
--- a/arch/powerpc/sysdev/dart_iommu.c
+++ b/arch/powerpc/sysdev/dart_iommu.c
@@ -49,6 +49,7 @@
49 49
50#include "dart.h" 50#include "dart.h"
51 51
52extern int iommu_is_off;
52extern int iommu_force_on; 53extern int iommu_force_on;
53 54
54/* Physical base address and size of the DART table */ 55/* Physical base address and size of the DART table */
@@ -329,10 +330,17 @@ void iommu_init_early_dart(void)
329 330
330void __init alloc_dart_table(void) 331void __init alloc_dart_table(void)
331{ 332{
332 /* Only reserve DART space if machine has more than 2GB of RAM 333 /* Only reserve DART space if machine has more than 1GB of RAM
333 * or if requested with iommu=on on cmdline. 334 * or if requested with iommu=on on cmdline.
335 *
336 * 1GB of RAM is picked as limit because some default devices
337 * (i.e. Airport Extreme) have 30 bit address range limits.
334 */ 338 */
335 if (lmb_end_of_DRAM() <= 0x80000000ull && !iommu_force_on) 339
340 if (iommu_is_off)
341 return;
342
343 if (!iommu_force_on && lmb_end_of_DRAM() <= 0x40000000ull)
336 return; 344 return;
337 345
338 /* 512 pages (2MB) is max DART tablesize. */ 346 /* 512 pages (2MB) is max DART tablesize. */