aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-05-15 21:50:19 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-05-15 21:50:19 -0400
commit835a906c74ecf20cdb817d6d02975cc0ba421e35 (patch)
tree86db6424947e8f5b4ddb1f7f6bfdaf9353f194d7
parente089d43fb1ab8e39168c9f61d30aef5b8724d085 (diff)
parent51a41e7d39ce0da1198837aaa495fe6dbcc4f802 (diff)
Merge master.kernel.org:/pub/scm/linux/kernel/git/lethal/sh64-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/lethal/sh64-2.6: sh64: Add .gitignore entry for syscalltab. sh64: generic quicklist support. sh64: Update cayman defconfig. sh64: Fixup sh-sci build. sh64: ppoll/pselect6() and restartable syscalls. sh64: dma-mapping updates. sh64: Fixups for the irq_regs changes. sh64: Wire up many new syscalls. spelling fixes: arch/sh64/ sh64: ROUND_UP macro cleanup in arch/sh64/kernel/pci_sh5.c
-rw-r--r--arch/sh64/Kconfig3
-rw-r--r--arch/sh64/configs/cayman_defconfig199
-rw-r--r--arch/sh64/kernel/entry.S4
-rw-r--r--arch/sh64/kernel/irq.c4
-rw-r--r--arch/sh64/kernel/pci_sh5.c17
-rw-r--r--arch/sh64/kernel/pci_sh5.h2
-rw-r--r--arch/sh64/kernel/process.c2
-rw-r--r--arch/sh64/kernel/signal.c33
-rw-r--r--arch/sh64/kernel/syscalls.S36
-rw-r--r--arch/sh64/kernel/time.c18
-rw-r--r--arch/sh64/lib/.gitignore1
-rw-r--r--arch/sh64/mach-cayman/irq.c4
-rw-r--r--arch/sh64/mach-cayman/setup.c2
-rw-r--r--arch/sh64/mm/fault.c2
-rw-r--r--arch/sh64/mm/init.c2
-rw-r--r--arch/sh64/mm/tlbmiss.c4
-rw-r--r--include/asm-sh64/dma-mapping.h14
-rw-r--r--include/asm-sh64/irq_regs.h1
-rw-r--r--include/asm-sh64/pgalloc.h100
-rw-r--r--include/asm-sh64/sci.h1
-rw-r--r--include/asm-sh64/thread_info.h6
-rw-r--r--include/asm-sh64/unistd.h43
-rw-r--r--mm/Kconfig2
23 files changed, 296 insertions, 204 deletions
diff --git a/arch/sh64/Kconfig b/arch/sh64/Kconfig
index e14b533558c8..ff654204b7d4 100644
--- a/arch/sh64/Kconfig
+++ b/arch/sh64/Kconfig
@@ -17,6 +17,9 @@ config MMU
17 bool 17 bool
18 default y 18 default y
19 19
20config QUICKLIST
21 def_bool y
22
20config RWSEM_GENERIC_SPINLOCK 23config RWSEM_GENERIC_SPINLOCK
21 bool 24 bool
22 default y 25 default y
diff --git a/arch/sh64/configs/cayman_defconfig b/arch/sh64/configs/cayman_defconfig
index d81df574a7f7..ed035084b053 100644
--- a/arch/sh64/configs/cayman_defconfig
+++ b/arch/sh64/configs/cayman_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.18 3# Linux kernel version: 2.6.22-rc1
4# Tue Oct 3 13:30:51 2006 4# Mon May 14 08:43:31 2007
5# 5#
6CONFIG_SUPERH=y 6CONFIG_SUPERH=y
7CONFIG_SUPERH64=y 7CONFIG_SUPERH64=y
@@ -10,6 +10,8 @@ CONFIG_RWSEM_GENERIC_SPINLOCK=y
10CONFIG_GENERIC_FIND_NEXT_BIT=y 10CONFIG_GENERIC_FIND_NEXT_BIT=y
11CONFIG_GENERIC_HWEIGHT=y 11CONFIG_GENERIC_HWEIGHT=y
12CONFIG_GENERIC_CALIBRATE_DELAY=y 12CONFIG_GENERIC_CALIBRATE_DELAY=y
13# CONFIG_ARCH_HAS_ILOG2_U32 is not set
14# CONFIG_ARCH_HAS_ILOG2_U64 is not set
13CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" 15CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config"
14 16
15# 17#
@@ -33,13 +35,15 @@ CONFIG_POSIX_MQUEUE=y
33# CONFIG_UTS_NS is not set 35# CONFIG_UTS_NS is not set
34# CONFIG_AUDIT is not set 36# CONFIG_AUDIT is not set
35# CONFIG_IKCONFIG is not set 37# CONFIG_IKCONFIG is not set
38CONFIG_LOG_BUF_SHIFT=14
39CONFIG_SYSFS_DEPRECATED=y
36# CONFIG_RELAY is not set 40# CONFIG_RELAY is not set
37CONFIG_INITRAMFS_SOURCE="" 41# CONFIG_BLK_DEV_INITRD is not set
38# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set 42# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set
39CONFIG_SYSCTL=y 43CONFIG_SYSCTL=y
40# CONFIG_EMBEDDED is not set 44# CONFIG_EMBEDDED is not set
41CONFIG_UID16=y 45CONFIG_UID16=y
42# CONFIG_SYSCTL_SYSCALL is not set 46CONFIG_SYSCTL_SYSCALL=y
43CONFIG_KALLSYMS=y 47CONFIG_KALLSYMS=y
44# CONFIG_KALLSYMS_ALL is not set 48# CONFIG_KALLSYMS_ALL is not set
45# CONFIG_KALLSYMS_EXTRA_PASS is not set 49# CONFIG_KALLSYMS_EXTRA_PASS is not set
@@ -49,14 +53,19 @@ CONFIG_BUG=y
49CONFIG_ELF_CORE=y 53CONFIG_ELF_CORE=y
50CONFIG_BASE_FULL=y 54CONFIG_BASE_FULL=y
51CONFIG_FUTEX=y 55CONFIG_FUTEX=y
56CONFIG_ANON_INODES=y
52CONFIG_EPOLL=y 57CONFIG_EPOLL=y
58CONFIG_SIGNALFD=y
59CONFIG_TIMERFD=y
60CONFIG_EVENTFD=y
53CONFIG_SHMEM=y 61CONFIG_SHMEM=y
54CONFIG_SLAB=y
55CONFIG_VM_EVENT_COUNTERS=y 62CONFIG_VM_EVENT_COUNTERS=y
63CONFIG_SLAB=y
64# CONFIG_SLUB is not set
65# CONFIG_SLOB is not set
56CONFIG_RT_MUTEXES=y 66CONFIG_RT_MUTEXES=y
57# CONFIG_TINY_SHMEM is not set 67# CONFIG_TINY_SHMEM is not set
58CONFIG_BASE_SMALL=0 68CONFIG_BASE_SMALL=0
59# CONFIG_SLOB is not set
60 69
61# 70#
62# Loadable module support 71# Loadable module support
@@ -135,7 +144,7 @@ CONFIG_SH64_ID2815_WORKAROUND=y
135# 144#
136CONFIG_HEARTBEAT=y 145CONFIG_HEARTBEAT=y
137CONFIG_HDSP253_LED=y 146CONFIG_HDSP253_LED=y
138CONFIG_SH_DMA=y 147# CONFIG_SH_DMA is not set
139CONFIG_PREEMPT=y 148CONFIG_PREEMPT=y
140CONFIG_SELECT_MEMORY_MODEL=y 149CONFIG_SELECT_MEMORY_MODEL=y
141CONFIG_FLATMEM_MANUAL=y 150CONFIG_FLATMEM_MANUAL=y
@@ -146,23 +155,20 @@ CONFIG_FLAT_NODE_MEM_MAP=y
146# CONFIG_SPARSEMEM_STATIC is not set 155# CONFIG_SPARSEMEM_STATIC is not set
147CONFIG_SPLIT_PTLOCK_CPUS=4 156CONFIG_SPLIT_PTLOCK_CPUS=4
148# CONFIG_RESOURCES_64BIT is not set 157# CONFIG_RESOURCES_64BIT is not set
158CONFIG_ZONE_DMA_FLAG=0
149 159
150# 160#
151# Bus options (PCI, PCMCIA, EISA, MCA, ISA) 161# Bus options (PCI, PCMCIA, EISA, MCA, ISA)
152# 162#
153CONFIG_PCI=y 163CONFIG_PCI=y
154CONFIG_SH_PCIDMA_NONCOHERENT=y 164CONFIG_SH_PCIDMA_NONCOHERENT=y
155# CONFIG_PCI_MULTITHREAD_PROBE is not set 165# CONFIG_ARCH_SUPPORTS_MSI is not set
156# CONFIG_PCI_DEBUG is not set 166# CONFIG_PCI_DEBUG is not set
157 167
158# 168#
159# PCCARD (PCMCIA/CardBus) support 169# PCCARD (PCMCIA/CardBus) support
160# 170#
161# CONFIG_PCCARD is not set 171# CONFIG_PCCARD is not set
162
163#
164# PCI Hotplug Support
165#
166# CONFIG_HOTPLUG_PCI is not set 172# CONFIG_HOTPLUG_PCI is not set
167 173
168# 174#
@@ -180,13 +186,13 @@ CONFIG_NET=y
180# 186#
181# Networking options 187# Networking options
182# 188#
183# CONFIG_NETDEBUG is not set
184CONFIG_PACKET=y 189CONFIG_PACKET=y
185# CONFIG_PACKET_MMAP is not set 190# CONFIG_PACKET_MMAP is not set
186CONFIG_UNIX=y 191CONFIG_UNIX=y
187CONFIG_XFRM=y 192CONFIG_XFRM=y
188# CONFIG_XFRM_USER is not set 193# CONFIG_XFRM_USER is not set
189# CONFIG_XFRM_SUB_POLICY is not set 194# CONFIG_XFRM_SUB_POLICY is not set
195# CONFIG_XFRM_MIGRATE is not set
190# CONFIG_NET_KEY is not set 196# CONFIG_NET_KEY is not set
191CONFIG_INET=y 197CONFIG_INET=y
192# CONFIG_IP_MULTICAST is not set 198# CONFIG_IP_MULTICAST is not set
@@ -207,11 +213,13 @@ CONFIG_IP_PNP=y
207# CONFIG_INET_TUNNEL is not set 213# CONFIG_INET_TUNNEL is not set
208CONFIG_INET_XFRM_MODE_TRANSPORT=y 214CONFIG_INET_XFRM_MODE_TRANSPORT=y
209CONFIG_INET_XFRM_MODE_TUNNEL=y 215CONFIG_INET_XFRM_MODE_TUNNEL=y
216CONFIG_INET_XFRM_MODE_BEET=y
210CONFIG_INET_DIAG=y 217CONFIG_INET_DIAG=y
211CONFIG_INET_TCP_DIAG=y 218CONFIG_INET_TCP_DIAG=y
212# CONFIG_TCP_CONG_ADVANCED is not set 219# CONFIG_TCP_CONG_ADVANCED is not set
213CONFIG_TCP_CONG_CUBIC=y 220CONFIG_TCP_CONG_CUBIC=y
214CONFIG_DEFAULT_TCP_CONG="cubic" 221CONFIG_DEFAULT_TCP_CONG="cubic"
222# CONFIG_TCP_MD5SIG is not set
215# CONFIG_IPV6 is not set 223# CONFIG_IPV6 is not set
216# CONFIG_INET6_XFRM_TUNNEL is not set 224# CONFIG_INET6_XFRM_TUNNEL is not set
217# CONFIG_INET6_TUNNEL is not set 225# CONFIG_INET6_TUNNEL is not set
@@ -256,7 +264,16 @@ CONFIG_DEFAULT_TCP_CONG="cubic"
256# CONFIG_HAMRADIO is not set 264# CONFIG_HAMRADIO is not set
257# CONFIG_IRDA is not set 265# CONFIG_IRDA is not set
258# CONFIG_BT is not set 266# CONFIG_BT is not set
267# CONFIG_AF_RXRPC is not set
268
269#
270# Wireless
271#
272# CONFIG_CFG80211 is not set
273# CONFIG_WIRELESS_EXT is not set
274# CONFIG_MAC80211 is not set
259# CONFIG_IEEE80211 is not set 275# CONFIG_IEEE80211 is not set
276# CONFIG_RFKILL is not set
260 277
261# 278#
262# Device Drivers 279# Device Drivers
@@ -269,16 +286,13 @@ CONFIG_STANDALONE=y
269CONFIG_PREVENT_FIRMWARE_BUILD=y 286CONFIG_PREVENT_FIRMWARE_BUILD=y
270# CONFIG_FW_LOADER is not set 287# CONFIG_FW_LOADER is not set
271# CONFIG_DEBUG_DRIVER is not set 288# CONFIG_DEBUG_DRIVER is not set
289# CONFIG_DEBUG_DEVRES is not set
272# CONFIG_SYS_HYPERVISOR is not set 290# CONFIG_SYS_HYPERVISOR is not set
273 291
274# 292#
275# Connector - unified userspace <-> kernelspace linker 293# Connector - unified userspace <-> kernelspace linker
276# 294#
277# CONFIG_CONNECTOR is not set 295# CONFIG_CONNECTOR is not set
278
279#
280# Memory Technology Devices (MTD)
281#
282# CONFIG_MTD is not set 296# CONFIG_MTD is not set
283 297
284# 298#
@@ -289,6 +303,7 @@ CONFIG_PREVENT_FIRMWARE_BUILD=y
289# 303#
290# Plug and Play support 304# Plug and Play support
291# 305#
306# CONFIG_PNPACPI is not set
292 307
293# 308#
294# Block devices 309# Block devices
@@ -306,11 +321,18 @@ CONFIG_BLK_DEV_RAM=y
306CONFIG_BLK_DEV_RAM_COUNT=16 321CONFIG_BLK_DEV_RAM_COUNT=16
307CONFIG_BLK_DEV_RAM_SIZE=4096 322CONFIG_BLK_DEV_RAM_SIZE=4096
308CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024 323CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024
309# CONFIG_BLK_DEV_INITRD is not set
310# CONFIG_CDROM_PKTCDVD is not set 324# CONFIG_CDROM_PKTCDVD is not set
311# CONFIG_ATA_OVER_ETH is not set 325# CONFIG_ATA_OVER_ETH is not set
312 326
313# 327#
328# Misc devices
329#
330# CONFIG_PHANTOM is not set
331# CONFIG_SGI_IOC4 is not set
332# CONFIG_TIFM_CORE is not set
333# CONFIG_BLINK is not set
334
335#
314# ATA/ATAPI/MFM/RLL support 336# ATA/ATAPI/MFM/RLL support
315# 337#
316# CONFIG_IDE is not set 338# CONFIG_IDE is not set
@@ -320,6 +342,7 @@ CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024
320# 342#
321# CONFIG_RAID_ATTRS is not set 343# CONFIG_RAID_ATTRS is not set
322CONFIG_SCSI=y 344CONFIG_SCSI=y
345# CONFIG_SCSI_TGT is not set
323# CONFIG_SCSI_NETLINK is not set 346# CONFIG_SCSI_NETLINK is not set
324CONFIG_SCSI_PROC_FS=y 347CONFIG_SCSI_PROC_FS=y
325 348
@@ -339,6 +362,7 @@ CONFIG_BLK_DEV_SD=y
339CONFIG_SCSI_MULTI_LUN=y 362CONFIG_SCSI_MULTI_LUN=y
340# CONFIG_SCSI_CONSTANTS is not set 363# CONFIG_SCSI_CONSTANTS is not set
341# CONFIG_SCSI_LOGGING is not set 364# CONFIG_SCSI_LOGGING is not set
365# CONFIG_SCSI_SCAN_ASYNC is not set
342 366
343# 367#
344# SCSI Transports 368# SCSI Transports
@@ -378,18 +402,16 @@ CONFIG_SCSI_SYM53C8XX_DMA_ADDRESSING_MODE=0
378CONFIG_SCSI_SYM53C8XX_DEFAULT_TAGS=16 402CONFIG_SCSI_SYM53C8XX_DEFAULT_TAGS=16
379CONFIG_SCSI_SYM53C8XX_MAX_TAGS=64 403CONFIG_SCSI_SYM53C8XX_MAX_TAGS=64
380CONFIG_SCSI_SYM53C8XX_MMIO=y 404CONFIG_SCSI_SYM53C8XX_MMIO=y
381# CONFIG_SCSI_IPR is not set
382# CONFIG_SCSI_QLOGIC_1280 is not set 405# CONFIG_SCSI_QLOGIC_1280 is not set
383# CONFIG_SCSI_QLA_FC is not set 406# CONFIG_SCSI_QLA_FC is not set
407# CONFIG_SCSI_QLA_ISCSI is not set
384# CONFIG_SCSI_LPFC is not set 408# CONFIG_SCSI_LPFC is not set
385# CONFIG_SCSI_DC395x is not set 409# CONFIG_SCSI_DC395x is not set
386# CONFIG_SCSI_DC390T is not set 410# CONFIG_SCSI_DC390T is not set
387# CONFIG_SCSI_NSP32 is not set 411# CONFIG_SCSI_NSP32 is not set
388# CONFIG_SCSI_DEBUG is not set 412# CONFIG_SCSI_DEBUG is not set
389 413# CONFIG_SCSI_ESP_CORE is not set
390# 414# CONFIG_SCSI_SRP is not set
391# Serial ATA (prod) and Parallel ATA (experimental) drivers
392#
393# CONFIG_ATA is not set 415# CONFIG_ATA is not set
394 416
395# 417#
@@ -408,6 +430,7 @@ CONFIG_SCSI_SYM53C8XX_MMIO=y
408# 430#
409# IEEE 1394 (FireWire) support 431# IEEE 1394 (FireWire) support
410# 432#
433# CONFIG_FIREWIRE is not set
411# CONFIG_IEEE1394 is not set 434# CONFIG_IEEE1394 is not set
412 435
413# 436#
@@ -428,10 +451,6 @@ CONFIG_NETDEVICES=y
428# ARCnet devices 451# ARCnet devices
429# 452#
430# CONFIG_ARCNET is not set 453# CONFIG_ARCNET is not set
431
432#
433# PHY device support
434#
435# CONFIG_PHYLIB is not set 454# CONFIG_PHYLIB is not set
436 455
437# 456#
@@ -479,10 +498,8 @@ CONFIG_NET_PCI=y
479# CONFIG_SUNDANCE is not set 498# CONFIG_SUNDANCE is not set
480# CONFIG_TLAN is not set 499# CONFIG_TLAN is not set
481# CONFIG_VIA_RHINE is not set 500# CONFIG_VIA_RHINE is not set
482 501# CONFIG_SC92031 is not set
483# 502CONFIG_NETDEV_1000=y
484# Ethernet (1000 Mbit)
485#
486# CONFIG_ACENIC is not set 503# CONFIG_ACENIC is not set
487# CONFIG_DL2K is not set 504# CONFIG_DL2K is not set
488# CONFIG_E1000 is not set 505# CONFIG_E1000 is not set
@@ -498,14 +515,16 @@ CONFIG_NET_PCI=y
498# CONFIG_TIGON3 is not set 515# CONFIG_TIGON3 is not set
499# CONFIG_BNX2 is not set 516# CONFIG_BNX2 is not set
500# CONFIG_QLA3XXX is not set 517# CONFIG_QLA3XXX is not set
501 518# CONFIG_ATL1 is not set
502# 519CONFIG_NETDEV_10000=y
503# Ethernet (10000 Mbit)
504#
505# CONFIG_CHELSIO_T1 is not set 520# CONFIG_CHELSIO_T1 is not set
521# CONFIG_CHELSIO_T3 is not set
506# CONFIG_IXGB is not set 522# CONFIG_IXGB is not set
507# CONFIG_S2IO is not set 523# CONFIG_S2IO is not set
508# CONFIG_MYRI10GE is not set 524# CONFIG_MYRI10GE is not set
525# CONFIG_NETXEN_NIC is not set
526# CONFIG_MLX4_CORE is not set
527CONFIG_MLX4_DEBUG=y
509 528
510# 529#
511# Token Ring devices 530# Token Ring devices
@@ -513,13 +532,10 @@ CONFIG_NET_PCI=y
513# CONFIG_TR is not set 532# CONFIG_TR is not set
514 533
515# 534#
516# Wireless LAN (non-hamradio) 535# Wireless LAN
517#
518# CONFIG_NET_RADIO is not set
519
520#
521# Wan interfaces
522# 536#
537# CONFIG_WLAN_PRE80211 is not set
538# CONFIG_WLAN_80211 is not set
523# CONFIG_WAN is not set 539# CONFIG_WAN is not set
524# CONFIG_FDDI is not set 540# CONFIG_FDDI is not set
525# CONFIG_HIPPI is not set 541# CONFIG_HIPPI is not set
@@ -571,9 +587,17 @@ CONFIG_KEYBOARD_ATKBD=y
571# CONFIG_KEYBOARD_STOWAWAY is not set 587# CONFIG_KEYBOARD_STOWAWAY is not set
572CONFIG_INPUT_MOUSE=y 588CONFIG_INPUT_MOUSE=y
573CONFIG_MOUSE_PS2=y 589CONFIG_MOUSE_PS2=y
590CONFIG_MOUSE_PS2_ALPS=y
591CONFIG_MOUSE_PS2_LOGIPS2PP=y
592CONFIG_MOUSE_PS2_SYNAPTICS=y
593CONFIG_MOUSE_PS2_LIFEBOOK=y
594CONFIG_MOUSE_PS2_TRACKPOINT=y
595# CONFIG_MOUSE_PS2_TOUCHKIT is not set
574# CONFIG_MOUSE_SERIAL is not set 596# CONFIG_MOUSE_SERIAL is not set
597# CONFIG_MOUSE_APPLETOUCH is not set
575# CONFIG_MOUSE_VSXXXAA is not set 598# CONFIG_MOUSE_VSXXXAA is not set
576# CONFIG_INPUT_JOYSTICK is not set 599# CONFIG_INPUT_JOYSTICK is not set
600# CONFIG_INPUT_TABLET is not set
577# CONFIG_INPUT_TOUCHSCREEN is not set 601# CONFIG_INPUT_TOUCHSCREEN is not set
578# CONFIG_INPUT_MISC is not set 602# CONFIG_INPUT_MISC is not set
579 603
@@ -619,10 +643,6 @@ CONFIG_LEGACY_PTY_COUNT=256
619# IPMI 643# IPMI
620# 644#
621# CONFIG_IPMI_HANDLER is not set 645# CONFIG_IPMI_HANDLER is not set
622
623#
624# Watchdog Cards
625#
626CONFIG_WATCHDOG=y 646CONFIG_WATCHDOG=y
627# CONFIG_WATCHDOG_NOWAYOUT is not set 647# CONFIG_WATCHDOG_NOWAYOUT is not set
628 648
@@ -639,13 +659,8 @@ CONFIG_WATCHDOG=y
639# CONFIG_WDTPCI is not set 659# CONFIG_WDTPCI is not set
640CONFIG_HW_RANDOM=y 660CONFIG_HW_RANDOM=y
641# CONFIG_GEN_RTC is not set 661# CONFIG_GEN_RTC is not set
642# CONFIG_DTLK is not set
643# CONFIG_R3964 is not set 662# CONFIG_R3964 is not set
644# CONFIG_APPLICOM is not set 663# CONFIG_APPLICOM is not set
645
646#
647# Ftape, the floppy tape device driver
648#
649# CONFIG_DRM is not set 664# CONFIG_DRM is not set
650# CONFIG_RAW_DRIVER is not set 665# CONFIG_RAW_DRIVER is not set
651 666
@@ -653,11 +668,7 @@ CONFIG_HW_RANDOM=y
653# TPM devices 668# TPM devices
654# 669#
655# CONFIG_TCG_TPM is not set 670# CONFIG_TCG_TPM is not set
656# CONFIG_TELCLOCK is not set 671CONFIG_DEVPORT=y
657
658#
659# I2C support
660#
661# CONFIG_I2C is not set 672# CONFIG_I2C is not set
662 673
663# 674#
@@ -669,44 +680,60 @@ CONFIG_HW_RANDOM=y
669# 680#
670# Dallas's 1-wire bus 681# Dallas's 1-wire bus
671# 682#
672 683# CONFIG_W1 is not set
673#
674# Hardware Monitoring support
675#
676CONFIG_HWMON=y 684CONFIG_HWMON=y
677# CONFIG_HWMON_VID is not set 685# CONFIG_HWMON_VID is not set
678# CONFIG_SENSORS_ABITUGURU is not set 686# CONFIG_SENSORS_ABITUGURU is not set
679# CONFIG_SENSORS_F71805F is not set 687# CONFIG_SENSORS_F71805F is not set
688# CONFIG_SENSORS_PC87427 is not set
689# CONFIG_SENSORS_SMSC47M1 is not set
690# CONFIG_SENSORS_SMSC47B397 is not set
680# CONFIG_SENSORS_VT1211 is not set 691# CONFIG_SENSORS_VT1211 is not set
692# CONFIG_SENSORS_W83627HF is not set
681# CONFIG_HWMON_DEBUG_CHIP is not set 693# CONFIG_HWMON_DEBUG_CHIP is not set
682 694
683# 695#
684# Misc devices 696# Multifunction device drivers
685# 697#
698# CONFIG_MFD_SM501 is not set
686 699
687# 700#
688# Multimedia devices 701# Multimedia devices
689# 702#
690# CONFIG_VIDEO_DEV is not set 703# CONFIG_VIDEO_DEV is not set
691CONFIG_VIDEO_V4L2=y 704# CONFIG_DVB_CORE is not set
705CONFIG_DAB=y
692 706
693# 707#
694# Digital Video Broadcasting Devices 708# Graphics support
695# 709#
696# CONFIG_DVB is not set 710# CONFIG_BACKLIGHT_LCD_SUPPORT is not set
697 711
698# 712#
699# Graphics support 713# Display device support
700# 714#
701CONFIG_FIRMWARE_EDID=y 715# CONFIG_DISPLAY_SUPPORT is not set
716# CONFIG_VGASTATE is not set
702CONFIG_FB=y 717CONFIG_FB=y
718CONFIG_FIRMWARE_EDID=y
719# CONFIG_FB_DDC is not set
703CONFIG_FB_CFB_FILLRECT=y 720CONFIG_FB_CFB_FILLRECT=y
704CONFIG_FB_CFB_COPYAREA=y 721CONFIG_FB_CFB_COPYAREA=y
705CONFIG_FB_CFB_IMAGEBLIT=y 722CONFIG_FB_CFB_IMAGEBLIT=y
723# CONFIG_FB_SYS_FILLRECT is not set
724# CONFIG_FB_SYS_COPYAREA is not set
725# CONFIG_FB_SYS_IMAGEBLIT is not set
726# CONFIG_FB_SYS_FOPS is not set
727CONFIG_FB_DEFERRED_IO=y
728# CONFIG_FB_SVGALIB is not set
706# CONFIG_FB_MACMODES is not set 729# CONFIG_FB_MACMODES is not set
707# CONFIG_FB_BACKLIGHT is not set 730# CONFIG_FB_BACKLIGHT is not set
708CONFIG_FB_MODE_HELPERS=y 731CONFIG_FB_MODE_HELPERS=y
709# CONFIG_FB_TILEBLITTING is not set 732# CONFIG_FB_TILEBLITTING is not set
733
734#
735# Frame buffer hardware drivers
736#
710# CONFIG_FB_CIRRUS is not set 737# CONFIG_FB_CIRRUS is not set
711# CONFIG_FB_PM2 is not set 738# CONFIG_FB_PM2 is not set
712# CONFIG_FB_CYBER2000 is not set 739# CONFIG_FB_CYBER2000 is not set
@@ -720,13 +747,17 @@ CONFIG_FB_MODE_HELPERS=y
720# CONFIG_FB_RADEON is not set 747# CONFIG_FB_RADEON is not set
721# CONFIG_FB_ATY128 is not set 748# CONFIG_FB_ATY128 is not set
722# CONFIG_FB_ATY is not set 749# CONFIG_FB_ATY is not set
750# CONFIG_FB_S3 is not set
723# CONFIG_FB_SAVAGE is not set 751# CONFIG_FB_SAVAGE is not set
724# CONFIG_FB_SIS is not set 752# CONFIG_FB_SIS is not set
725# CONFIG_FB_NEOMAGIC is not set 753# CONFIG_FB_NEOMAGIC is not set
726CONFIG_FB_KYRO=y 754CONFIG_FB_KYRO=y
727# CONFIG_FB_3DFX is not set 755# CONFIG_FB_3DFX is not set
728# CONFIG_FB_VOODOO1 is not set 756# CONFIG_FB_VOODOO1 is not set
757# CONFIG_FB_VT8623 is not set
729# CONFIG_FB_TRIDENT is not set 758# CONFIG_FB_TRIDENT is not set
759# CONFIG_FB_ARK is not set
760# CONFIG_FB_PM3 is not set
730# CONFIG_FB_VIRTUAL is not set 761# CONFIG_FB_VIRTUAL is not set
731 762
732# 763#
@@ -746,10 +777,6 @@ CONFIG_FONT_8x16=y
746# CONFIG_FONT_SUN8x16 is not set 777# CONFIG_FONT_SUN8x16 is not set
747# CONFIG_FONT_SUN12x22 is not set 778# CONFIG_FONT_SUN12x22 is not set
748# CONFIG_FONT_10x18 is not set 779# CONFIG_FONT_10x18 is not set
749
750#
751# Logo configuration
752#
753CONFIG_LOGO=y 780CONFIG_LOGO=y
754# CONFIG_LOGO_LINUX_MONO is not set 781# CONFIG_LOGO_LINUX_MONO is not set
755# CONFIG_LOGO_LINUX_VGA16 is not set 782# CONFIG_LOGO_LINUX_VGA16 is not set
@@ -757,7 +784,6 @@ CONFIG_LOGO=y
757# CONFIG_LOGO_SUPERH_MONO is not set 784# CONFIG_LOGO_SUPERH_MONO is not set
758# CONFIG_LOGO_SUPERH_VGA16 is not set 785# CONFIG_LOGO_SUPERH_VGA16 is not set
759CONFIG_LOGO_SUPERH_CLUT224=y 786CONFIG_LOGO_SUPERH_CLUT224=y
760# CONFIG_BACKLIGHT_LCD_SUPPORT is not set
761 787
762# 788#
763# Sound 789# Sound
@@ -765,6 +791,12 @@ CONFIG_LOGO_SUPERH_CLUT224=y
765# CONFIG_SOUND is not set 791# CONFIG_SOUND is not set
766 792
767# 793#
794# HID Devices
795#
796CONFIG_HID=y
797# CONFIG_HID_DEBUG is not set
798
799#
768# USB support 800# USB support
769# 801#
770CONFIG_USB_ARCH_HAS_HCD=y 802CONFIG_USB_ARCH_HAS_HCD=y
@@ -780,10 +812,6 @@ CONFIG_USB_ARCH_HAS_EHCI=y
780# USB Gadget Support 812# USB Gadget Support
781# 813#
782# CONFIG_USB_GADGET is not set 814# CONFIG_USB_GADGET is not set
783
784#
785# MMC/SD Card support
786#
787# CONFIG_MMC is not set 815# CONFIG_MMC is not set
788 816
789# 817#
@@ -836,6 +864,7 @@ CONFIG_EXT3_FS=y
836CONFIG_EXT3_FS_XATTR=y 864CONFIG_EXT3_FS_XATTR=y
837# CONFIG_EXT3_FS_POSIX_ACL is not set 865# CONFIG_EXT3_FS_POSIX_ACL is not set
838# CONFIG_EXT3_FS_SECURITY is not set 866# CONFIG_EXT3_FS_SECURITY is not set
867# CONFIG_EXT4DEV_FS is not set
839CONFIG_JBD=y 868CONFIG_JBD=y
840# CONFIG_JBD_DEBUG is not set 869# CONFIG_JBD_DEBUG is not set
841CONFIG_FS_MBCACHE=y 870CONFIG_FS_MBCACHE=y
@@ -843,6 +872,7 @@ CONFIG_FS_MBCACHE=y
843# CONFIG_JFS_FS is not set 872# CONFIG_JFS_FS is not set
844# CONFIG_FS_POSIX_ACL is not set 873# CONFIG_FS_POSIX_ACL is not set
845# CONFIG_XFS_FS is not set 874# CONFIG_XFS_FS is not set
875# CONFIG_GFS2_FS is not set
846# CONFIG_OCFS2_FS is not set 876# CONFIG_OCFS2_FS is not set
847CONFIG_MINIX_FS=y 877CONFIG_MINIX_FS=y
848CONFIG_ROMFS_FS=y 878CONFIG_ROMFS_FS=y
@@ -912,6 +942,7 @@ CONFIG_LOCKD=y
912CONFIG_LOCKD_V4=y 942CONFIG_LOCKD_V4=y
913CONFIG_NFS_COMMON=y 943CONFIG_NFS_COMMON=y
914CONFIG_SUNRPC=y 944CONFIG_SUNRPC=y
945# CONFIG_SUNRPC_BIND34 is not set
915# CONFIG_RPCSEC_GSS_KRB5 is not set 946# CONFIG_RPCSEC_GSS_KRB5 is not set
916# CONFIG_RPCSEC_GSS_SPKM3 is not set 947# CONFIG_RPCSEC_GSS_SPKM3 is not set
917# CONFIG_SMB_FS is not set 948# CONFIG_SMB_FS is not set
@@ -941,6 +972,7 @@ CONFIG_MSDOS_PARTITION=y
941# CONFIG_SUN_PARTITION is not set 972# CONFIG_SUN_PARTITION is not set
942# CONFIG_KARMA_PARTITION is not set 973# CONFIG_KARMA_PARTITION is not set
943# CONFIG_EFI_PARTITION is not set 974# CONFIG_EFI_PARTITION is not set
975# CONFIG_SYSV68_PARTITION is not set
944 976
945# 977#
946# Native Language Support 978# Native Language Support
@@ -948,6 +980,11 @@ CONFIG_MSDOS_PARTITION=y
948# CONFIG_NLS is not set 980# CONFIG_NLS is not set
949 981
950# 982#
983# Distributed Lock Manager
984#
985# CONFIG_DLM is not set
986
987#
951# Profiling support 988# Profiling support
952# 989#
953# CONFIG_PROFILING is not set 990# CONFIG_PROFILING is not set
@@ -959,28 +996,29 @@ CONFIG_MSDOS_PARTITION=y
959CONFIG_ENABLE_MUST_CHECK=y 996CONFIG_ENABLE_MUST_CHECK=y
960CONFIG_MAGIC_SYSRQ=y 997CONFIG_MAGIC_SYSRQ=y
961# CONFIG_UNUSED_SYMBOLS is not set 998# CONFIG_UNUSED_SYMBOLS is not set
999CONFIG_DEBUG_FS=y
1000# CONFIG_HEADERS_CHECK is not set
962CONFIG_DEBUG_KERNEL=y 1001CONFIG_DEBUG_KERNEL=y
963CONFIG_LOG_BUF_SHIFT=14 1002# CONFIG_DEBUG_SHIRQ is not set
964CONFIG_DETECT_SOFTLOCKUP=y 1003CONFIG_DETECT_SOFTLOCKUP=y
965CONFIG_SCHEDSTATS=y 1004CONFIG_SCHEDSTATS=y
1005# CONFIG_TIMER_STATS is not set
966# CONFIG_DEBUG_SLAB is not set 1006# CONFIG_DEBUG_SLAB is not set
967# CONFIG_DEBUG_RT_MUTEXES is not set 1007# CONFIG_DEBUG_RT_MUTEXES is not set
968# CONFIG_RT_MUTEX_TESTER is not set 1008# CONFIG_RT_MUTEX_TESTER is not set
969# CONFIG_DEBUG_SPINLOCK is not set 1009# CONFIG_DEBUG_SPINLOCK is not set
970# CONFIG_DEBUG_MUTEXES is not set 1010# CONFIG_DEBUG_MUTEXES is not set
971# CONFIG_DEBUG_RWSEMS is not set
972# CONFIG_DEBUG_SPINLOCK_SLEEP is not set 1011# CONFIG_DEBUG_SPINLOCK_SLEEP is not set
973# CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set 1012# CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set
974# CONFIG_DEBUG_KOBJECT is not set 1013# CONFIG_DEBUG_KOBJECT is not set
975CONFIG_DEBUG_BUGVERBOSE=y 1014CONFIG_DEBUG_BUGVERBOSE=y
976# CONFIG_DEBUG_INFO is not set 1015# CONFIG_DEBUG_INFO is not set
977CONFIG_DEBUG_FS=y
978# CONFIG_DEBUG_VM is not set 1016# CONFIG_DEBUG_VM is not set
979# CONFIG_DEBUG_LIST is not set 1017# CONFIG_DEBUG_LIST is not set
980CONFIG_FRAME_POINTER=y 1018CONFIG_FRAME_POINTER=y
981# CONFIG_UNWIND_INFO is not set
982CONFIG_FORCED_INLINING=y 1019CONFIG_FORCED_INLINING=y
983# CONFIG_RCU_TORTURE_TEST is not set 1020# CONFIG_RCU_TORTURE_TEST is not set
1021# CONFIG_FAULT_INJECTION is not set
984# CONFIG_EARLY_PRINTK is not set 1022# CONFIG_EARLY_PRINTK is not set
985# CONFIG_DEBUG_KERNEL_WITH_GDB_STUB is not set 1023# CONFIG_DEBUG_KERNEL_WITH_GDB_STUB is not set
986CONFIG_SH64_PROC_TLB=y 1024CONFIG_SH64_PROC_TLB=y
@@ -1004,10 +1042,15 @@ CONFIG_SH64_SR_WATCH=y
1004# 1042#
1005# Library routines 1043# Library routines
1006# 1044#
1045CONFIG_BITREVERSE=y
1007# CONFIG_CRC_CCITT is not set 1046# CONFIG_CRC_CCITT is not set
1008# CONFIG_CRC16 is not set 1047# CONFIG_CRC16 is not set
1048# CONFIG_CRC_ITU_T is not set
1009CONFIG_CRC32=y 1049CONFIG_CRC32=y
1010# CONFIG_LIBCRC32C is not set 1050# CONFIG_LIBCRC32C is not set
1011CONFIG_PLIST=y 1051CONFIG_PLIST=y
1052CONFIG_HAS_IOMEM=y
1053CONFIG_HAS_IOPORT=y
1054CONFIG_HAS_DMA=y
1012CONFIG_GENERIC_HARDIRQS=y 1055CONFIG_GENERIC_HARDIRQS=y
1013CONFIG_GENERIC_IRQ_PROBE=y 1056CONFIG_GENERIC_IRQ_PROBE=y
diff --git a/arch/sh64/kernel/entry.S b/arch/sh64/kernel/entry.S
index 40d45346248d..7013fcb6665c 100644
--- a/arch/sh64/kernel/entry.S
+++ b/arch/sh64/kernel/entry.S
@@ -947,14 +947,14 @@ ret_with_reschedule:
947 ! FIXME:!!! 947 ! FIXME:!!!
948 ! no handling of TIF_SYSCALL_TRACE yet!! 948 ! no handling of TIF_SYSCALL_TRACE yet!!
949 949
950 movi (1 << TIF_NEED_RESCHED), r8 950 movi _TIF_NEED_RESCHED, r8
951 and r8, r7, r8 951 and r8, r7, r8
952 pta work_resched, tr0 952 pta work_resched, tr0
953 bne r8, ZERO, tr0 953 bne r8, ZERO, tr0
954 954
955 pta restore_all, tr1 955 pta restore_all, tr1
956 956
957 movi (1 << TIF_SIGPENDING), r8 957 movi (_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK), r8
958 and r8, r7, r8 958 and r8, r7, r8
959 pta work_notifysig, tr0 959 pta work_notifysig, tr0
960 bne r8, ZERO, tr0 960 bne r8, ZERO, tr0
diff --git a/arch/sh64/kernel/irq.c b/arch/sh64/kernel/irq.c
index f68b4f6c9b31..9412b7166700 100644
--- a/arch/sh64/kernel/irq.c
+++ b/arch/sh64/kernel/irq.c
@@ -94,6 +94,7 @@ asmlinkage void do_NMI(unsigned long vector_num, struct pt_regs * regs)
94 */ 94 */
95asmlinkage int do_IRQ(unsigned long vector_num, struct pt_regs * regs) 95asmlinkage int do_IRQ(unsigned long vector_num, struct pt_regs * regs)
96{ 96{
97 struct pt_regs *old_regs = set_irq_regs(regs);
97 int irq; 98 int irq;
98 99
99 irq_enter(); 100 irq_enter();
@@ -101,13 +102,14 @@ asmlinkage int do_IRQ(unsigned long vector_num, struct pt_regs * regs)
101 irq = irq_demux(vector_num); 102 irq = irq_demux(vector_num);
102 103
103 if (irq >= 0) { 104 if (irq >= 0) {
104 __do_IRQ(irq, regs); 105 __do_IRQ(irq);
105 } else { 106 } else {
106 printk("unexpected IRQ trap at vector %03lx\n", vector_num); 107 printk("unexpected IRQ trap at vector %03lx\n", vector_num);
107 } 108 }
108 109
109 irq_exit(); 110 irq_exit();
110 111
112 set_irq_regs(old_regs);
111 return 1; 113 return 1;
112} 114}
113 115
diff --git a/arch/sh64/kernel/pci_sh5.c b/arch/sh64/kernel/pci_sh5.c
index 49862e165c06..fb51660847c8 100644
--- a/arch/sh64/kernel/pci_sh5.c
+++ b/arch/sh64/kernel/pci_sh5.c
@@ -340,8 +340,9 @@ static int __init map_cayman_irq(struct pci_dev *dev, u8 slot, u8 pin)
340 return result; 340 return result;
341} 341}
342 342
343irqreturn_t pcish5_err_irq(int irq, void *dev_id, struct pt_regs *regs) 343static irqreturn_t pcish5_err_irq(int irq, void *dev_id)
344{ 344{
345 struct pt_regs *regs = get_irq_regs();
345 unsigned pci_int, pci_air, pci_cir, pci_aint; 346 unsigned pci_int, pci_air, pci_cir, pci_aint;
346 347
347 pci_int = SH5PCI_READ(INT); 348 pci_int = SH5PCI_READ(INT);
@@ -368,15 +369,13 @@ irqreturn_t pcish5_err_irq(int irq, void *dev_id, struct pt_regs *regs)
368 return IRQ_HANDLED; 369 return IRQ_HANDLED;
369} 370}
370 371
371irqreturn_t pcish5_serr_irq(int irq, void *dev_id, struct pt_regs *regs) 372static irqreturn_t pcish5_serr_irq(int irq, void *dev_id)
372{ 373{
373 printk("SERR IRQ\n"); 374 printk("SERR IRQ\n");
374 375
375 return IRQ_NONE; 376 return IRQ_NONE;
376} 377}
377 378
378#define ROUND_UP(x, a) (((x) + (a) - 1) & ~((a) - 1))
379
380static void __init 379static void __init
381pcibios_size_bridge(struct pci_bus *bus, struct resource *ior, 380pcibios_size_bridge(struct pci_bus *bus, struct resource *ior,
382 struct resource *memr) 381 struct resource *memr)
@@ -433,8 +432,8 @@ pcibios_size_bridge(struct pci_bus *bus, struct resource *ior,
433 mem_res.end -= mem_res.start; 432 mem_res.end -= mem_res.start;
434 433
435 /* Align the sizes up by bridge rules */ 434 /* Align the sizes up by bridge rules */
436 io_res.end = ROUND_UP(io_res.end, 4*1024) - 1; 435 io_res.end = ALIGN(io_res.end, 4*1024) - 1;
437 mem_res.end = ROUND_UP(mem_res.end, 1*1024*1024) - 1; 436 mem_res.end = ALIGN(mem_res.end, 1*1024*1024) - 1;
438 437
439 /* Adjust the bridge's allocation requirements */ 438 /* Adjust the bridge's allocation requirements */
440 bridge->resource[0].end = bridge->resource[0].start + io_res.end; 439 bridge->resource[0].end = bridge->resource[0].start + io_res.end;
@@ -447,18 +446,16 @@ pcibios_size_bridge(struct pci_bus *bus, struct resource *ior,
447 446
448 /* adjust parent's resource requirements */ 447 /* adjust parent's resource requirements */
449 if (ior) { 448 if (ior) {
450 ior->end = ROUND_UP(ior->end, 4*1024); 449 ior->end = ALIGN(ior->end, 4*1024);
451 ior->end += io_res.end; 450 ior->end += io_res.end;
452 } 451 }
453 452
454 if (memr) { 453 if (memr) {
455 memr->end = ROUND_UP(memr->end, 1*1024*1024); 454 memr->end = ALIGN(memr->end, 1*1024*1024);
456 memr->end += mem_res.end; 455 memr->end += mem_res.end;
457 } 456 }
458} 457}
459 458
460#undef ROUND_UP
461
462static void __init pcibios_size_bridges(void) 459static void __init pcibios_size_bridges(void)
463{ 460{
464 struct resource io_res, mem_res; 461 struct resource io_res, mem_res;
diff --git a/arch/sh64/kernel/pci_sh5.h b/arch/sh64/kernel/pci_sh5.h
index 8f21f5d2aa3e..c71159dd04b9 100644
--- a/arch/sh64/kernel/pci_sh5.h
+++ b/arch/sh64/kernel/pci_sh5.h
@@ -4,7 +4,7 @@
4 * May be copied or modified under the terms of the GNU General Public 4 * May be copied or modified under the terms of the GNU General Public
5 * License. See linux/COPYING for more information. 5 * License. See linux/COPYING for more information.
6 * 6 *
7 * Defintions for the SH5 PCI hardware. 7 * Definitions for the SH5 PCI hardware.
8 */ 8 */
9 9
10/* Product ID */ 10/* Product ID */
diff --git a/arch/sh64/kernel/process.c b/arch/sh64/kernel/process.c
index 525d0ec19b78..1b89c9dfb93d 100644
--- a/arch/sh64/kernel/process.c
+++ b/arch/sh64/kernel/process.c
@@ -387,7 +387,7 @@ ATTRIB_NORET void kernel_thread_helper(void *arg, int (*fn)(void *))
387 * NOTE! Only a kernel-only process(ie the swapper or direct descendants 387 * NOTE! Only a kernel-only process(ie the swapper or direct descendants
388 * who haven't done an "execve()") should use this: it will work within 388 * who haven't done an "execve()") should use this: it will work within
389 * a system call from a "real" process, but the process memory space will 389 * a system call from a "real" process, but the process memory space will
390 * not be free'd until both the parent and the child have exited. 390 * not be freed until both the parent and the child have exited.
391 */ 391 */
392int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags) 392int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags)
393{ 393{
diff --git a/arch/sh64/kernel/signal.c b/arch/sh64/kernel/signal.c
index b76bdfa473d6..c8525ade0564 100644
--- a/arch/sh64/kernel/signal.c
+++ b/arch/sh64/kernel/signal.c
@@ -698,7 +698,9 @@ int do_signal(struct pt_regs *regs, sigset_t *oldset)
698 if (try_to_freeze()) 698 if (try_to_freeze())
699 goto no_signal; 699 goto no_signal;
700 700
701 if (!oldset) 701 if (test_thread_flag(TIF_RESTORE_SIGMASK))
702 oldset = &current->saved_sigmask;
703 else if (!oldset)
702 oldset = &current->blocked; 704 oldset = &current->blocked;
703 705
704 signr = get_signal_to_deliver(&info, &ka, regs, 0); 706 signr = get_signal_to_deliver(&info, &ka, regs, 0);
@@ -706,6 +708,15 @@ int do_signal(struct pt_regs *regs, sigset_t *oldset)
706 if (signr > 0) { 708 if (signr > 0) {
707 /* Whee! Actually deliver the signal. */ 709 /* Whee! Actually deliver the signal. */
708 handle_signal(signr, &info, &ka, oldset, regs); 710 handle_signal(signr, &info, &ka, oldset, regs);
711
712 /*
713 * If a signal was successfully delivered, the saved sigmask
714 * is in its frame, and we can clear the TIF_RESTORE_SIGMASK
715 * flag.
716 */
717 if (test_thread_flag(TIF_RESTORE_SIGMASK))
718 clear_thread_flag(TIF_RESTORE_SIGMASK);
719
709 return 1; 720 return 1;
710 } 721 }
711 722
@@ -713,13 +724,27 @@ no_signal:
713 /* Did we come from a system call? */ 724 /* Did we come from a system call? */
714 if (regs->syscall_nr >= 0) { 725 if (regs->syscall_nr >= 0) {
715 /* Restart the system call - no handlers present */ 726 /* Restart the system call - no handlers present */
716 if (regs->regs[REG_RET] == -ERESTARTNOHAND || 727 switch (regs->regs[REG_RET]) {
717 regs->regs[REG_RET] == -ERESTARTSYS || 728 case -ERESTARTNOHAND:
718 regs->regs[REG_RET] == -ERESTARTNOINTR) { 729 case -ERESTARTSYS:
730 case -ERESTARTNOINTR:
719 /* Decode Syscall # */ 731 /* Decode Syscall # */
720 regs->regs[REG_RET] = regs->syscall_nr; 732 regs->regs[REG_RET] = regs->syscall_nr;
721 regs->pc -= 4; 733 regs->pc -= 4;
734 break;
735
736 case -ERESTART_RESTARTBLOCK:
737 regs->regs[REG_RET] = __NR_restart_syscall;
738 regs->pc -= 4;
739 break;
722 } 740 }
723 } 741 }
742
743 /* No signal to deliver -- put the saved sigmask back */
744 if (test_thread_flag(TIF_RESTORE_SIGMASK)) {
745 clear_thread_flag(TIF_RESTORE_SIGMASK);
746 sigprocmask(SIG_SETMASK, &current->saved_sigmask, NULL);
747 }
748
724 return 0; 749 return 0;
725} 750}
diff --git a/arch/sh64/kernel/syscalls.S b/arch/sh64/kernel/syscalls.S
index c0079d54c850..a5c680d29384 100644
--- a/arch/sh64/kernel/syscalls.S
+++ b/arch/sh64/kernel/syscalls.S
@@ -2,7 +2,7 @@
2 * arch/sh64/kernel/syscalls.S 2 * arch/sh64/kernel/syscalls.S
3 * 3 *
4 * Copyright (C) 2000, 2001 Paolo Alberelli 4 * Copyright (C) 2000, 2001 Paolo Alberelli
5 * Copyright (C) 2004 Paul Mundt 5 * Copyright (C) 2004 - 2007 Paul Mundt
6 * Copyright (C) 2003, 2004 Richard Curnow 6 * Copyright (C) 2003, 2004 Richard Curnow
7 * 7 *
8 * This file is subject to the terms and conditions of the GNU General Public 8 * This file is subject to the terms and conditions of the GNU General Public
@@ -20,7 +20,7 @@
20 */ 20 */
21 .globl sys_call_table 21 .globl sys_call_table
22sys_call_table: 22sys_call_table:
23 .long sys_ni_syscall /* 0 - old "setup()" system call */ 23 .long sys_restart_syscall /* 0 - old "setup()" system call */
24 .long sys_exit 24 .long sys_exit
25 .long sys_fork 25 .long sys_fork
26 .long sys_read 26 .long sys_read
@@ -347,4 +347,34 @@ sys_call_table:
347 .long sys_inotify_init 347 .long sys_inotify_init
348 .long sys_inotify_add_watch 348 .long sys_inotify_add_watch
349 .long sys_inotify_rm_watch /* 320 */ 349 .long sys_inotify_rm_watch /* 320 */
350 350 .long sys_ni_syscall
351 .long sys_migrate_pages
352 .long sys_openat
353 .long sys_mkdirat
354 .long sys_mknodat /* 325 */
355 .long sys_fchownat
356 .long sys_futimesat
357 .long sys_fstatat64
358 .long sys_unlinkat
359 .long sys_renameat /* 330 */
360 .long sys_linkat
361 .long sys_symlinkat
362 .long sys_readlinkat
363 .long sys_fchmodat
364 .long sys_faccessat /* 335 */
365 .long sys_pselect6
366 .long sys_ppoll
367 .long sys_unshare
368 .long sys_set_robust_list
369 .long sys_get_robust_list /* 340 */
370 .long sys_splice
371 .long sys_sync_file_range
372 .long sys_tee
373 .long sys_vmsplice
374 .long sys_move_pages /* 345 */
375 .long sys_getcpu
376 .long sys_epoll_pwait
377 .long sys_utimensat
378 .long sys_signalfd
379 .long sys_timerfd /* 350 */
380 .long sys_eventfd
diff --git a/arch/sh64/kernel/time.c b/arch/sh64/kernel/time.c
index 390b40de7cef..b37f4f4981d2 100644
--- a/arch/sh64/kernel/time.c
+++ b/arch/sh64/kernel/time.c
@@ -123,7 +123,7 @@ static unsigned long long usecs_per_jiffy = 1000000/HZ; /* Approximation */
123static unsigned long long scaled_recip_ctc_ticks_per_jiffy; 123static unsigned long long scaled_recip_ctc_ticks_per_jiffy;
124 124
125/* Estimate number of microseconds that have elapsed since the last timer tick, 125/* Estimate number of microseconds that have elapsed since the last timer tick,
126 by scaling the delta that has occured in the CTC register. 126 by scaling the delta that has occurred in the CTC register.
127 127
128 WARNING WARNING WARNING : This algorithm relies on the CTC decrementing at 128 WARNING WARNING WARNING : This algorithm relies on the CTC decrementing at
129 the CPU clock rate. If the CPU sleeps, the CTC stops counting. Bear this 129 the CPU clock rate. If the CPU sleeps, the CTC stops counting. Bear this
@@ -282,7 +282,7 @@ static long last_rtc_update = 0;
282 * timer_interrupt() needs to keep up the real-time clock, 282 * timer_interrupt() needs to keep up the real-time clock,
283 * as well as call the "do_timer()" routine every clocktick 283 * as well as call the "do_timer()" routine every clocktick
284 */ 284 */
285static inline void do_timer_interrupt(int irq, struct pt_regs *regs) 285static inline void do_timer_interrupt(void)
286{ 286{
287 unsigned long long current_ctc; 287 unsigned long long current_ctc;
288 asm ("getcon cr62, %0" : "=r" (current_ctc)); 288 asm ("getcon cr62, %0" : "=r" (current_ctc));
@@ -290,9 +290,10 @@ static inline void do_timer_interrupt(int irq, struct pt_regs *regs)
290 290
291 do_timer(1); 291 do_timer(1);
292#ifndef CONFIG_SMP 292#ifndef CONFIG_SMP
293 update_process_times(user_mode(regs)); 293 update_process_times(user_mode(get_irq_regs()));
294#endif 294#endif
295 profile_tick(CPU_PROFILING, regs); 295 if (current->pid)
296 profile_tick(CPU_PROFILING);
296 297
297#ifdef CONFIG_HEARTBEAT 298#ifdef CONFIG_HEARTBEAT
298 { 299 {
@@ -323,7 +324,7 @@ static inline void do_timer_interrupt(int irq, struct pt_regs *regs)
323 * Time Stamp Counter value at the time of the timer interrupt, so that 324 * Time Stamp Counter value at the time of the timer interrupt, so that
324 * we later on can estimate the time of day more exactly. 325 * we later on can estimate the time of day more exactly.
325 */ 326 */
326static irqreturn_t timer_interrupt(int irq, void *dev_id, struct pt_regs *regs) 327static irqreturn_t timer_interrupt(int irq, void *dev_id)
327{ 328{
328 unsigned long timer_status; 329 unsigned long timer_status;
329 330
@@ -340,7 +341,7 @@ static irqreturn_t timer_interrupt(int irq, void *dev_id, struct pt_regs *regs)
340 * locally disabled. -arca 341 * locally disabled. -arca
341 */ 342 */
342 write_lock(&xtime_lock); 343 write_lock(&xtime_lock);
343 do_timer_interrupt(irq, regs); 344 do_timer_interrupt();
344 write_unlock(&xtime_lock); 345 write_unlock(&xtime_lock);
345 346
346 return IRQ_HANDLED; 347 return IRQ_HANDLED;
@@ -465,9 +466,10 @@ static __init unsigned int get_cpu_hz(void)
465#endif 466#endif
466} 467}
467 468
468static irqreturn_t sh64_rtc_interrupt(int irq, void *dev_id, 469static irqreturn_t sh64_rtc_interrupt(int irq, void *dev_id)
469 struct pt_regs *regs)
470{ 470{
471 struct pt_regs *regs = get_irq_regs();
472
471 ctrl_outb(0, RCR1); /* Disable Carry Interrupts */ 473 ctrl_outb(0, RCR1); /* Disable Carry Interrupts */
472 regs->regs[3] = 1; /* Using r3 */ 474 regs->regs[3] = 1; /* Using r3 */
473 475
diff --git a/arch/sh64/lib/.gitignore b/arch/sh64/lib/.gitignore
new file mode 100644
index 000000000000..3508c2cb23c4
--- /dev/null
+++ b/arch/sh64/lib/.gitignore
@@ -0,0 +1 @@
syscalltab.h
diff --git a/arch/sh64/mach-cayman/irq.c b/arch/sh64/mach-cayman/irq.c
index 228ce61c3515..aaad36d37d1f 100644
--- a/arch/sh64/mach-cayman/irq.c
+++ b/arch/sh64/mach-cayman/irq.c
@@ -29,13 +29,13 @@ unsigned long epld_virt;
29/* Note the SMSC SuperIO chip and SMSC LAN chip interrupts are all muxed onto 29/* Note the SMSC SuperIO chip and SMSC LAN chip interrupts are all muxed onto
30 the same SH-5 interrupt */ 30 the same SH-5 interrupt */
31 31
32static irqreturn_t cayman_interrupt_smsc(int irq, void *dev_id, struct pt_regs *regs) 32static irqreturn_t cayman_interrupt_smsc(int irq, void *dev_id)
33{ 33{
34 printk(KERN_INFO "CAYMAN: spurious SMSC interrupt\n"); 34 printk(KERN_INFO "CAYMAN: spurious SMSC interrupt\n");
35 return IRQ_NONE; 35 return IRQ_NONE;
36} 36}
37 37
38static irqreturn_t cayman_interrupt_pci2(int irq, void *dev_id, struct pt_regs *regs) 38static irqreturn_t cayman_interrupt_pci2(int irq, void *dev_id)
39{ 39{
40 printk(KERN_INFO "CAYMAN: spurious PCI interrupt, IRQ %d\n", irq); 40 printk(KERN_INFO "CAYMAN: spurious PCI interrupt, IRQ %d\n", irq);
41 return IRQ_NONE; 41 return IRQ_NONE;
diff --git a/arch/sh64/mach-cayman/setup.c b/arch/sh64/mach-cayman/setup.c
index 3ed87cd059d0..c3611cc2735f 100644
--- a/arch/sh64/mach-cayman/setup.c
+++ b/arch/sh64/mach-cayman/setup.c
@@ -213,7 +213,7 @@ static int __init smsc_superio_setup(void)
213 SMSC_SUPERIO_WRITE_INDEXED(0x00, 0xc7); /* GP47 = nIOWOP */ 213 SMSC_SUPERIO_WRITE_INDEXED(0x00, 0xc7); /* GP47 = nIOWOP */
214#endif 214#endif
215 215
216 /* Exit the configuraton state */ 216 /* Exit the configuration state */
217 outb(SMSC_EXIT_CONFIG_KEY, SMSC_CONFIG_PORT_ADDR); 217 outb(SMSC_EXIT_CONFIG_KEY, SMSC_CONFIG_PORT_ADDR);
218 218
219 return 0; 219 return 0;
diff --git a/arch/sh64/mm/fault.c b/arch/sh64/mm/fault.c
index 4dd8ee8f01ce..3cd93ba5d826 100644
--- a/arch/sh64/mm/fault.c
+++ b/arch/sh64/mm/fault.c
@@ -135,7 +135,7 @@ asmlinkage void do_page_fault(struct pt_regs *regs, unsigned long writeaccess,
135 /* SIM 135 /* SIM
136 * Note this is now called with interrupts still disabled 136 * Note this is now called with interrupts still disabled
137 * This is to cope with being called for a missing IO port 137 * This is to cope with being called for a missing IO port
138 * address with interupts disabled. This should be fixed as 138 * address with interrupts disabled. This should be fixed as
139 * soon as we have a better 'fast path' miss handler. 139 * soon as we have a better 'fast path' miss handler.
140 * 140 *
141 * Plus take care how you try and debug this stuff. 141 * Plus take care how you try and debug this stuff.
diff --git a/arch/sh64/mm/init.c b/arch/sh64/mm/init.c
index 5dc08787259c..559717f30d1f 100644
--- a/arch/sh64/mm/init.c
+++ b/arch/sh64/mm/init.c
@@ -84,7 +84,7 @@ void show_mem(void)
84 printk("%d reserved pages\n",reserved); 84 printk("%d reserved pages\n",reserved);
85 printk("%d pages shared\n",shared); 85 printk("%d pages shared\n",shared);
86 printk("%d pages swap cached\n",cached); 86 printk("%d pages swap cached\n",cached);
87 printk("%ld pages in page table cache\n",pgtable_cache_size); 87 printk("%ld pages in page table cache\n", quicklist_total_size());
88} 88}
89 89
90/* 90/*
diff --git a/arch/sh64/mm/tlbmiss.c b/arch/sh64/mm/tlbmiss.c
index d4c5334186d0..b767d6cff72f 100644
--- a/arch/sh64/mm/tlbmiss.c
+++ b/arch/sh64/mm/tlbmiss.c
@@ -14,7 +14,7 @@
14 * IMPORTANT NOTES : 14 * IMPORTANT NOTES :
15 * The do_fast_page_fault function is called from a context in entry.S where very few registers 15 * The do_fast_page_fault function is called from a context in entry.S where very few registers
16 * have been saved. In particular, the code in this file must be compiled not to use ANY 16 * have been saved. In particular, the code in this file must be compiled not to use ANY
17 * caller-save regiseters that are not part of the restricted save set. Also, it means that 17 * caller-save registers that are not part of the restricted save set. Also, it means that
18 * code in this file must not make calls to functions elsewhere in the kernel, or else the 18 * code in this file must not make calls to functions elsewhere in the kernel, or else the
19 * excepting context will see corruption in its caller-save registers. Plus, the entry.S save 19 * excepting context will see corruption in its caller-save registers. Plus, the entry.S save
20 * area is non-reentrant, so this code has to run with SR.BL==1, i.e. no interrupts taken inside 20 * area is non-reentrant, so this code has to run with SR.BL==1, i.e. no interrupts taken inside
@@ -249,7 +249,7 @@ asmlinkage int do_fast_page_fault(unsigned long long ssr_md, unsigned long long
249 /* SIM 249 /* SIM
250 * Note this is now called with interrupts still disabled 250 * Note this is now called with interrupts still disabled
251 * This is to cope with being called for a missing IO port 251 * This is to cope with being called for a missing IO port
252 * address with interupts disabled. This should be fixed as 252 * address with interrupts disabled. This should be fixed as
253 * soon as we have a better 'fast path' miss handler. 253 * soon as we have a better 'fast path' miss handler.
254 * 254 *
255 * Plus take care how you try and debug this stuff. 255 * Plus take care how you try and debug this stuff.
diff --git a/include/asm-sh64/dma-mapping.h b/include/asm-sh64/dma-mapping.h
index 5efe906c59f7..c7c0f059cdc4 100644
--- a/include/asm-sh64/dma-mapping.h
+++ b/include/asm-sh64/dma-mapping.h
@@ -35,6 +35,10 @@ static inline void dma_free_coherent(struct device *dev, size_t size,
35 consistent_free(NULL, size, vaddr, dma_handle); 35 consistent_free(NULL, size, vaddr, dma_handle);
36} 36}
37 37
38#define dma_alloc_noncoherent(d, s, h, f) dma_alloc_coherent(d, s, h, f)
39#define dma_free_noncoherent(d, s, v, h) dma_free_coherent(d, s, v, h)
40#define dma_is_consistent(d, h) (1)
41
38static inline void dma_cache_sync(struct device *dev, void *vaddr, size_t size, 42static inline void dma_cache_sync(struct device *dev, void *vaddr, size_t size,
39 enum dma_data_direction dir) 43 enum dma_data_direction dir)
40{ 44{
@@ -49,7 +53,7 @@ static inline dma_addr_t dma_map_single(struct device *dev,
49 if (dev->bus == &pci_bus_type) 53 if (dev->bus == &pci_bus_type)
50 return virt_to_bus(ptr); 54 return virt_to_bus(ptr);
51#endif 55#endif
52 dma_cache_sync(ptr, size, dir); 56 dma_cache_sync(dev, ptr, size, dir);
53 57
54 return virt_to_bus(ptr); 58 return virt_to_bus(ptr);
55} 59}
@@ -63,7 +67,7 @@ static inline int dma_map_sg(struct device *dev, struct scatterlist *sg,
63 67
64 for (i = 0; i < nents; i++) { 68 for (i = 0; i < nents; i++) {
65#if !defined(CONFIG_PCI) || defined(CONFIG_SH_PCIDMA_NONCOHERENT) 69#if !defined(CONFIG_PCI) || defined(CONFIG_SH_PCIDMA_NONCOHERENT)
66 dma_cache_sync(page_address(sg[i].page) + sg[i].offset, 70 dma_cache_sync(dev, page_address(sg[i].page) + sg[i].offset,
67 sg[i].length, dir); 71 sg[i].length, dir);
68#endif 72#endif
69 sg[i].dma_address = page_to_phys(sg[i].page) + sg[i].offset; 73 sg[i].dma_address = page_to_phys(sg[i].page) + sg[i].offset;
@@ -94,7 +98,7 @@ static inline void dma_sync_single(struct device *dev, dma_addr_t dma_handle,
94 if (dev->bus == &pci_bus_type) 98 if (dev->bus == &pci_bus_type)
95 return; 99 return;
96#endif 100#endif
97 dma_cache_sync(bus_to_virt(dma_handle), size, dir); 101 dma_cache_sync(dev, bus_to_virt(dma_handle), size, dir);
98} 102}
99 103
100static inline void dma_sync_single_range(struct device *dev, 104static inline void dma_sync_single_range(struct device *dev,
@@ -106,7 +110,7 @@ static inline void dma_sync_single_range(struct device *dev,
106 if (dev->bus == &pci_bus_type) 110 if (dev->bus == &pci_bus_type)
107 return; 111 return;
108#endif 112#endif
109 dma_cache_sync(bus_to_virt(dma_handle) + offset, size, dir); 113 dma_cache_sync(dev, bus_to_virt(dma_handle) + offset, size, dir);
110} 114}
111 115
112static inline void dma_sync_sg(struct device *dev, struct scatterlist *sg, 116static inline void dma_sync_sg(struct device *dev, struct scatterlist *sg,
@@ -116,7 +120,7 @@ static inline void dma_sync_sg(struct device *dev, struct scatterlist *sg,
116 120
117 for (i = 0; i < nelems; i++) { 121 for (i = 0; i < nelems; i++) {
118#if !defined(CONFIG_PCI) || defined(CONFIG_SH_PCIDMA_NONCOHERENT) 122#if !defined(CONFIG_PCI) || defined(CONFIG_SH_PCIDMA_NONCOHERENT)
119 dma_cache_sync(page_address(sg[i].page) + sg[i].offset, 123 dma_cache_sync(dev, page_address(sg[i].page) + sg[i].offset,
120 sg[i].length, dir); 124 sg[i].length, dir);
121#endif 125#endif
122 sg[i].dma_address = page_to_phys(sg[i].page) + sg[i].offset; 126 sg[i].dma_address = page_to_phys(sg[i].page) + sg[i].offset;
diff --git a/include/asm-sh64/irq_regs.h b/include/asm-sh64/irq_regs.h
new file mode 100644
index 000000000000..3dd9c0b70270
--- /dev/null
+++ b/include/asm-sh64/irq_regs.h
@@ -0,0 +1 @@
#include <asm-generic/irq_regs.h>
diff --git a/include/asm-sh64/pgalloc.h b/include/asm-sh64/pgalloc.h
index cb803e56cb64..6eccab770a6d 100644
--- a/include/asm-sh64/pgalloc.h
+++ b/include/asm-sh64/pgalloc.h
@@ -14,13 +14,9 @@
14 * 14 *
15 */ 15 */
16 16
17#include <linux/threads.h>
18#include <linux/mm.h> 17#include <linux/mm.h>
19 18#include <linux/quicklist.h>
20#define pgd_quicklist (current_cpu_data.pgd_quick) 19#include <asm/page.h>
21#define pmd_quicklist (current_cpu_data.pmd_quick)
22#define pte_quicklist (current_cpu_data.pte_quick)
23#define pgtable_cache_size (current_cpu_data.pgtable_cache_sz)
24 20
25static inline void pgd_init(unsigned long page) 21static inline void pgd_init(unsigned long page)
26{ 22{
@@ -45,84 +41,37 @@ static inline pgd_t *get_pgd_slow(void)
45 return ret; 41 return ret;
46} 42}
47 43
48static inline pgd_t *get_pgd_fast(void) 44static inline pgd_t *pgd_alloc(struct mm_struct *mm)
49{
50 unsigned long *ret;
51
52 if ((ret = pgd_quicklist) != NULL) {
53 pgd_quicklist = (unsigned long *)(*ret);
54 ret[0] = 0;
55 pgtable_cache_size--;
56 } else
57 ret = (unsigned long *)get_pgd_slow();
58
59 if (ret) {
60 memset(ret, 0, USER_PTRS_PER_PGD * sizeof(pgd_t));
61 }
62 return (pgd_t *)ret;
63}
64
65static inline void free_pgd_fast(pgd_t *pgd)
66{
67 *(unsigned long *)pgd = (unsigned long) pgd_quicklist;
68 pgd_quicklist = (unsigned long *) pgd;
69 pgtable_cache_size++;
70}
71
72static inline void free_pgd_slow(pgd_t *pgd)
73{ 45{
74 kfree((void *)pgd); 46 return quicklist_alloc(0, GFP_KERNEL, NULL);
75} 47}
76 48
77extern pte_t *get_pte_slow(pmd_t *pmd, unsigned long address_preadjusted); 49static inline void pgd_free(pgd_t *pgd)
78extern pte_t *get_pte_kernel_slow(pmd_t *pmd, unsigned long address_preadjusted);
79
80static inline pte_t *get_pte_fast(void)
81{ 50{
82 unsigned long *ret; 51 quicklist_free(0, NULL, pgd);
83
84 if((ret = (unsigned long *)pte_quicklist) != NULL) {
85 pte_quicklist = (unsigned long *)(*ret);
86 ret[0] = ret[1];
87 pgtable_cache_size--;
88 }
89 return (pte_t *)ret;
90} 52}
91 53
92static inline void free_pte_fast(pte_t *pte) 54static inline struct page *pte_alloc_one(struct mm_struct *mm,
55 unsigned long address)
93{ 56{
94 *(unsigned long *)pte = (unsigned long) pte_quicklist; 57 void *pg = quicklist_alloc(0, GFP_KERNEL, NULL);
95 pte_quicklist = (unsigned long *) pte; 58 return pg ? virt_to_page(pg) : NULL;
96 pgtable_cache_size++;
97} 59}
98 60
99static inline void pte_free_kernel(pte_t *pte) 61static inline void pte_free_kernel(pte_t *pte)
100{ 62{
101 free_page((unsigned long)pte); 63 quicklist_free(0, NULL, pte);
102} 64}
103 65
104static inline void pte_free(struct page *pte) 66static inline void pte_free(struct page *pte)
105{ 67{
106 __free_page(pte); 68 quicklist_free_page(0, NULL, pte);
107} 69}
108 70
109static inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm, 71static inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm,
110 unsigned long address) 72 unsigned long address)
111{ 73{
112 pte_t *pte; 74 return quicklist_alloc(0, GFP_KERNEL, NULL);
113
114 pte = (pte_t *)__get_free_page(GFP_KERNEL | __GFP_REPEAT|__GFP_ZERO);
115
116 return pte;
117}
118
119static inline struct page *pte_alloc_one(struct mm_struct *mm, unsigned long address)
120{
121 struct page *pte;
122
123 pte = alloc_pages(GFP_KERNEL|__GFP_REPEAT|__GFP_ZERO, 0);
124
125 return pte;
126} 75}
127 76
128#define __pte_free_tlb(tlb,pte) tlb_remove_page((tlb),(pte)) 77#define __pte_free_tlb(tlb,pte) tlb_remove_page((tlb),(pte))
@@ -142,31 +91,23 @@ static inline struct page *pte_alloc_one(struct mm_struct *mm, unsigned long add
142 91
143#elif defined(CONFIG_SH64_PGTABLE_3_LEVEL) 92#elif defined(CONFIG_SH64_PGTABLE_3_LEVEL)
144 93
145static __inline__ pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long address) 94static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long address)
146{ 95{
147 pmd_t *pmd; 96 return quicklist_alloc(0, GFP_KERNEL, NULL);
148 pmd = (pmd_t *) __get_free_page(GFP_KERNEL|__GFP_REPEAT|__GFP_ZERO);
149 return pmd;
150} 97}
151 98
152static __inline__ void pmd_free(pmd_t *pmd) 99static inline void pmd_free(pmd_t *pmd)
153{ 100{
154 free_page((unsigned long) pmd); 101 quicklist_free(0, NULL, pmd);
155} 102}
156 103
157#define pgd_populate(mm, pgd, pmd) pgd_set(pgd, pmd) 104#define pgd_populate(mm, pgd, pmd) pgd_set(pgd, pmd)
158#define __pmd_free_tlb(tlb,pmd) pmd_free(pmd) 105#define __pmd_free_tlb(tlb,pmd) pmd_free(pmd)
159 106
160#else 107#else
161#error "No defined page table size" 108#error "No defined page table size"
162#endif 109#endif
163 110
164#define check_pgt_cache() do { } while (0)
165#define pgd_free(pgd) free_pgd_slow(pgd)
166#define pgd_alloc(mm) get_pgd_fast()
167
168extern int do_check_pgt_cache(int, int);
169
170#define pmd_populate_kernel(mm, pmd, pte) \ 111#define pmd_populate_kernel(mm, pmd, pte) \
171 set_pmd(pmd, __pmd(_PAGE_TABLE + (unsigned long) (pte))) 112 set_pmd(pmd, __pmd(_PAGE_TABLE + (unsigned long) (pte)))
172 113
@@ -176,4 +117,9 @@ static inline void pmd_populate(struct mm_struct *mm, pmd_t *pmd,
176 set_pmd(pmd, __pmd(_PAGE_TABLE + (unsigned long) page_address (pte))); 117 set_pmd(pmd, __pmd(_PAGE_TABLE + (unsigned long) page_address (pte)));
177} 118}
178 119
120static inline void check_pgt_cache(void)
121{
122 quicklist_trim(0, NULL, 25, 16);
123}
124
179#endif /* __ASM_SH64_PGALLOC_H */ 125#endif /* __ASM_SH64_PGALLOC_H */
diff --git a/include/asm-sh64/sci.h b/include/asm-sh64/sci.h
new file mode 100644
index 000000000000..793c568b7820
--- /dev/null
+++ b/include/asm-sh64/sci.h
@@ -0,0 +1 @@
#include <asm-sh/sci.h>
diff --git a/include/asm-sh64/thread_info.h b/include/asm-sh64/thread_info.h
index 1f825cb163c3..f6d5117c53af 100644
--- a/include/asm-sh64/thread_info.h
+++ b/include/asm-sh64/thread_info.h
@@ -78,7 +78,13 @@ static inline struct thread_info *current_thread_info(void)
78#define TIF_SIGPENDING 2 /* signal pending */ 78#define TIF_SIGPENDING 2 /* signal pending */
79#define TIF_NEED_RESCHED 3 /* rescheduling necessary */ 79#define TIF_NEED_RESCHED 3 /* rescheduling necessary */
80#define TIF_MEMDIE 4 80#define TIF_MEMDIE 4
81#define TIF_RESTORE_SIGMASK 5 /* Restore signal mask in do_signal */
81 82
83#define _TIF_SYSCALL_TRACE (1 << TIF_SYSCALL_TRACE)
84#define _TIF_SIGPENDING (1 << TIF_SIGPENDING)
85#define _TIF_NEED_RESCHED (1 << TIF_NEED_RESCHED)
86#define _TIF_MEMDIE (1 << TIF_MEMDIE)
87#define _TIF_RESTORE_SIGMASK (1 << TIF_RESTORE_SIGMASK)
82 88
83#endif /* __KERNEL__ */ 89#endif /* __KERNEL__ */
84 90
diff --git a/include/asm-sh64/unistd.h b/include/asm-sh64/unistd.h
index 1f38a7aacaaf..ea3adc600b41 100644
--- a/include/asm-sh64/unistd.h
+++ b/include/asm-sh64/unistd.h
@@ -9,14 +9,14 @@
9 * include/asm-sh64/unistd.h 9 * include/asm-sh64/unistd.h
10 * 10 *
11 * Copyright (C) 2000, 2001 Paolo Alberelli 11 * Copyright (C) 2000, 2001 Paolo Alberelli
12 * Copyright (C) 2003 Paul Mundt 12 * Copyright (C) 2003 - 2007 Paul Mundt
13 * Copyright (C) 2004 Sean McGoogan 13 * Copyright (C) 2004 Sean McGoogan
14 * 14 *
15 * This file contains the system call numbers. 15 * This file contains the system call numbers.
16 * 16 *
17 */ 17 */
18 18
19#define __NR_setup 0 /* used only by init, to get system going */ 19#define __NR_restart_syscall 0
20#define __NR_exit 1 20#define __NR_exit 1
21#define __NR_fork 2 21#define __NR_fork 2
22#define __NR_read 3 22#define __NR_read 3
@@ -196,8 +196,8 @@
196#define __NR_rt_sigtimedwait 177 196#define __NR_rt_sigtimedwait 177
197#define __NR_rt_sigqueueinfo 178 197#define __NR_rt_sigqueueinfo 178
198#define __NR_rt_sigsuspend 179 198#define __NR_rt_sigsuspend 179
199#define __NR_pread 180 199#define __NR_pread64 180
200#define __NR_pwrite 181 200#define __NR_pwrite64 181
201#define __NR_chown 182 201#define __NR_chown 182
202#define __NR_getcwd 183 202#define __NR_getcwd 183
203#define __NR_capget 184 203#define __NR_capget 184
@@ -343,10 +343,41 @@
343#define __NR_inotify_init 318 343#define __NR_inotify_init 318
344#define __NR_inotify_add_watch 319 344#define __NR_inotify_add_watch 319
345#define __NR_inotify_rm_watch 320 345#define __NR_inotify_rm_watch 320
346/* 321 is unused */
347#define __NR_migrate_pages 322
348#define __NR_openat 323
349#define __NR_mkdirat 324
350#define __NR_mknodat 325
351#define __NR_fchownat 326
352#define __NR_futimesat 327
353#define __NR_fstatat64 328
354#define __NR_unlinkat 329
355#define __NR_renameat 330
356#define __NR_linkat 331
357#define __NR_symlinkat 332
358#define __NR_readlinkat 333
359#define __NR_fchmodat 334
360#define __NR_faccessat 335
361#define __NR_pselect6 336
362#define __NR_ppoll 337
363#define __NR_unshare 338
364#define __NR_set_robust_list 339
365#define __NR_get_robust_list 340
366#define __NR_splice 341
367#define __NR_sync_file_range 342
368#define __NR_tee 343
369#define __NR_vmsplice 344
370#define __NR_move_pages 345
371#define __NR_getcpu 346
372#define __NR_epoll_pwait 347
373#define __NR_utimensat 348
374#define __NR_signalfd 349
375#define __NR_timerfd 350
376#define __NR_eventfd 351
346 377
347#ifdef __KERNEL__ 378#ifdef __KERNEL__
348 379
349#define NR_syscalls 321 380#define NR_syscalls 352
350 381
351#define __ARCH_WANT_IPC_PARSE_VERSION 382#define __ARCH_WANT_IPC_PARSE_VERSION
352#define __ARCH_WANT_OLD_READDIR 383#define __ARCH_WANT_OLD_READDIR
diff --git a/mm/Kconfig b/mm/Kconfig
index a17da8bafe62..8ac412b45f18 100644
--- a/mm/Kconfig
+++ b/mm/Kconfig
@@ -166,5 +166,5 @@ config ZONE_DMA_FLAG
166config NR_QUICK 166config NR_QUICK
167 int 167 int
168 depends on QUICKLIST 168 depends on QUICKLIST
169 default "2" if SUPERH 169 default "2" if (SUPERH && !SUPERH64)
170 default "1" 170 default "1"