diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-02-05 19:11:54 -0500 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-02-05 19:11:54 -0500 |
| commit | 09cd5b8f9dbdc161aec404eea572fbca7d162920 (patch) | |
| tree | a5e8beeaefd7bbf05d7fe302bf9e6cad5b041445 | |
| parent | cc5724ce10c21cb44f9413266bb100ab89b18e2a (diff) | |
| parent | c20f326a62c046ee958c3aa584f183201adb229f (diff) | |
Merge branch 'sh/for-2.6.29' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6
* 'sh/for-2.6.29' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6:
sh: Fix up T-bit error handling in SH-4A mutex fastpath.
sh: Fix up spurious syscall restarting.
sh: fcnvds fix with denormalized numbers on SH-4 FPU.
sh: Only reserve memory under CONFIG_ZERO_PAGE_OFFSET when it != 0.
sh: Handle calling csum_partial with misaligned data
sh: ap325rxa: Enable ov772x in defconfig.
sh: ap325rxa: Add ov772x support.
sh: ap325rxa: control camera power toggling.
sh: mach-migor: Enable ov772x and tw9910 in defconfig.
| -rw-r--r-- | arch/sh/boards/board-ap325rxa.c | 63 | ||||
| -rw-r--r-- | arch/sh/configs/ap325rxa_defconfig | 27 | ||||
| -rw-r--r-- | arch/sh/configs/migor_defconfig | 42 | ||||
| -rw-r--r-- | arch/sh/include/asm/mutex-llsc.h | 21 | ||||
| -rw-r--r-- | arch/sh/include/asm/syscall_32.h | 22 | ||||
| -rw-r--r-- | arch/sh/include/asm/syscall_64.h | 22 | ||||
| -rw-r--r-- | arch/sh/kernel/cpu/sh4/fpu.c | 2 | ||||
| -rw-r--r-- | arch/sh/kernel/setup.c | 8 | ||||
| -rw-r--r-- | arch/sh/kernel/signal_32.c | 4 | ||||
| -rw-r--r-- | arch/sh/kernel/signal_64.c | 4 | ||||
| -rw-r--r-- | arch/sh/lib/checksum.S | 69 |
11 files changed, 184 insertions, 100 deletions
diff --git a/arch/sh/boards/board-ap325rxa.c b/arch/sh/boards/board-ap325rxa.c index caf4c33f4e84..7c35787d29b4 100644 --- a/arch/sh/boards/board-ap325rxa.c +++ b/arch/sh/boards/board-ap325rxa.c | |||
| @@ -22,6 +22,7 @@ | |||
| 22 | #include <linux/gpio.h> | 22 | #include <linux/gpio.h> |
| 23 | #include <linux/spi/spi.h> | 23 | #include <linux/spi/spi.h> |
| 24 | #include <linux/spi/spi_gpio.h> | 24 | #include <linux/spi/spi_gpio.h> |
| 25 | #include <media/ov772x.h> | ||
| 25 | #include <media/soc_camera_platform.h> | 26 | #include <media/soc_camera_platform.h> |
| 26 | #include <media/sh_mobile_ceu.h> | 27 | #include <media/sh_mobile_ceu.h> |
| 27 | #include <video/sh_mobile_lcdc.h> | 28 | #include <video/sh_mobile_lcdc.h> |
| @@ -216,7 +217,14 @@ static struct platform_device lcdc_device = { | |||
| 216 | }, | 217 | }, |
| 217 | }; | 218 | }; |
| 218 | 219 | ||
| 220 | static void camera_power(int val) | ||
| 221 | { | ||
| 222 | gpio_set_value(GPIO_PTZ5, val); /* RST_CAM/RSTB */ | ||
| 223 | mdelay(10); | ||
| 224 | } | ||
| 225 | |||
| 219 | #ifdef CONFIG_I2C | 226 | #ifdef CONFIG_I2C |
| 227 | /* support for the old ncm03j camera */ | ||
| 220 | static unsigned char camera_ncm03j_magic[] = | 228 | static unsigned char camera_ncm03j_magic[] = |
| 221 | { | 229 | { |
| 222 | 0x87, 0x00, 0x88, 0x08, 0x89, 0x01, 0x8A, 0xE8, | 230 | 0x87, 0x00, 0x88, 0x08, 0x89, 0x01, 0x8A, 0xE8, |
| @@ -237,6 +245,23 @@ static unsigned char camera_ncm03j_magic[] = | |||
| 237 | 0x63, 0xD4, 0x64, 0xEA, 0xD6, 0x0F, | 245 | 0x63, 0xD4, 0x64, 0xEA, 0xD6, 0x0F, |
| 238 | }; | 246 | }; |
| 239 | 247 | ||
| 248 | static int camera_probe(void) | ||
| 249 | { | ||
| 250 | struct i2c_adapter *a = i2c_get_adapter(0); | ||
| 251 | struct i2c_msg msg; | ||
| 252 | int ret; | ||
| 253 | |||
| 254 | camera_power(1); | ||
| 255 | msg.addr = 0x6e; | ||
| 256 | msg.buf = camera_ncm03j_magic; | ||
| 257 | msg.len = 2; | ||
| 258 | msg.flags = 0; | ||
| 259 | ret = i2c_transfer(a, &msg, 1); | ||
| 260 | camera_power(0); | ||
| 261 | |||
| 262 | return ret; | ||
| 263 | } | ||
| 264 | |||
| 240 | static int camera_set_capture(struct soc_camera_platform_info *info, | 265 | static int camera_set_capture(struct soc_camera_platform_info *info, |
| 241 | int enable) | 266 | int enable) |
| 242 | { | 267 | { |
| @@ -245,9 +270,11 @@ static int camera_set_capture(struct soc_camera_platform_info *info, | |||
| 245 | int ret = 0; | 270 | int ret = 0; |
| 246 | int i; | 271 | int i; |
| 247 | 272 | ||
| 273 | camera_power(0); | ||
| 248 | if (!enable) | 274 | if (!enable) |
| 249 | return 0; /* no disable for now */ | 275 | return 0; /* no disable for now */ |
| 250 | 276 | ||
| 277 | camera_power(1); | ||
| 251 | for (i = 0; i < ARRAY_SIZE(camera_ncm03j_magic); i += 2) { | 278 | for (i = 0; i < ARRAY_SIZE(camera_ncm03j_magic); i += 2) { |
| 252 | u_int8_t buf[8]; | 279 | u_int8_t buf[8]; |
| 253 | 280 | ||
| @@ -286,8 +313,35 @@ static struct platform_device camera_device = { | |||
| 286 | .platform_data = &camera_info, | 313 | .platform_data = &camera_info, |
| 287 | }, | 314 | }, |
| 288 | }; | 315 | }; |
| 316 | |||
| 317 | static int __init camera_setup(void) | ||
| 318 | { | ||
| 319 | if (camera_probe() > 0) | ||
| 320 | platform_device_register(&camera_device); | ||
| 321 | |||
| 322 | return 0; | ||
| 323 | } | ||
| 324 | late_initcall(camera_setup); | ||
| 325 | |||
| 289 | #endif /* CONFIG_I2C */ | 326 | #endif /* CONFIG_I2C */ |
| 290 | 327 | ||
| 328 | static int ov7725_power(struct device *dev, int mode) | ||
| 329 | { | ||
| 330 | camera_power(0); | ||
| 331 | if (mode) | ||
| 332 | camera_power(1); | ||
| 333 | |||
| 334 | return 0; | ||
| 335 | } | ||
| 336 | |||
| 337 | static struct ov772x_camera_info ov7725_info = { | ||
| 338 | .buswidth = SOCAM_DATAWIDTH_8, | ||
| 339 | .flags = OV772X_FLAG_VFLIP | OV772X_FLAG_HFLIP, | ||
| 340 | .link = { | ||
| 341 | .power = ov7725_power, | ||
| 342 | }, | ||
| 343 | }; | ||
| 344 | |||
| 291 | static struct sh_mobile_ceu_info sh_mobile_ceu_info = { | 345 | static struct sh_mobile_ceu_info sh_mobile_ceu_info = { |
| 292 | .flags = SOCAM_PCLK_SAMPLE_RISING | SOCAM_HSYNC_ACTIVE_HIGH | | 346 | .flags = SOCAM_PCLK_SAMPLE_RISING | SOCAM_HSYNC_ACTIVE_HIGH | |
| 293 | SOCAM_VSYNC_ACTIVE_HIGH | SOCAM_MASTER | SOCAM_DATAWIDTH_8, | 347 | SOCAM_VSYNC_ACTIVE_HIGH | SOCAM_MASTER | SOCAM_DATAWIDTH_8, |
| @@ -338,9 +392,6 @@ static struct platform_device *ap325rxa_devices[] __initdata = { | |||
| 338 | &ap325rxa_nor_flash_device, | 392 | &ap325rxa_nor_flash_device, |
| 339 | &lcdc_device, | 393 | &lcdc_device, |
| 340 | &ceu_device, | 394 | &ceu_device, |
| 341 | #ifdef CONFIG_I2C | ||
| 342 | &camera_device, | ||
| 343 | #endif | ||
| 344 | &nand_flash_device, | 395 | &nand_flash_device, |
| 345 | &sdcard_cn3_device, | 396 | &sdcard_cn3_device, |
| 346 | }; | 397 | }; |
| @@ -349,6 +400,10 @@ static struct i2c_board_info __initdata ap325rxa_i2c_devices[] = { | |||
| 349 | { | 400 | { |
| 350 | I2C_BOARD_INFO("pcf8563", 0x51), | 401 | I2C_BOARD_INFO("pcf8563", 0x51), |
| 351 | }, | 402 | }, |
| 403 | { | ||
| 404 | I2C_BOARD_INFO("ov772x", 0x21), | ||
| 405 | .platform_data = &ov7725_info, | ||
| 406 | }, | ||
| 352 | }; | 407 | }; |
| 353 | 408 | ||
| 354 | static struct spi_board_info ap325rxa_spi_devices[] = { | 409 | static struct spi_board_info ap325rxa_spi_devices[] = { |
| @@ -426,7 +481,7 @@ static int __init ap325rxa_devices_setup(void) | |||
| 426 | gpio_request(GPIO_PTZ6, NULL); | 481 | gpio_request(GPIO_PTZ6, NULL); |
| 427 | gpio_direction_output(GPIO_PTZ6, 0); /* STBY_CAM */ | 482 | gpio_direction_output(GPIO_PTZ6, 0); /* STBY_CAM */ |
| 428 | gpio_request(GPIO_PTZ5, NULL); | 483 | gpio_request(GPIO_PTZ5, NULL); |
| 429 | gpio_direction_output(GPIO_PTZ5, 1); /* RST_CAM */ | 484 | gpio_direction_output(GPIO_PTZ5, 0); /* RST_CAM */ |
| 430 | gpio_request(GPIO_PTZ4, NULL); | 485 | gpio_request(GPIO_PTZ4, NULL); |
| 431 | gpio_direction_output(GPIO_PTZ4, 0); /* SADDR */ | 486 | gpio_direction_output(GPIO_PTZ4, 0); /* SADDR */ |
| 432 | 487 | ||
diff --git a/arch/sh/configs/ap325rxa_defconfig b/arch/sh/configs/ap325rxa_defconfig index 5c423fa8e6b8..352f87d50fdc 100644 --- a/arch/sh/configs/ap325rxa_defconfig +++ b/arch/sh/configs/ap325rxa_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.28 | 3 | # Linux kernel version: 2.6.29-rc2 |
| 4 | # Fri Jan 9 16:54:19 2009 | 4 | # Tue Jan 27 11:45:08 2009 |
| 5 | # | 5 | # |
| 6 | CONFIG_SUPERH=y | 6 | CONFIG_SUPERH=y |
| 7 | CONFIG_SUPERH32=y | 7 | CONFIG_SUPERH32=y |
| @@ -45,12 +45,12 @@ CONFIG_BSD_PROCESS_ACCT=y | |||
| 45 | # CONFIG_AUDIT is not set | 45 | # CONFIG_AUDIT is not set |
| 46 | # CONFIG_IKCONFIG is not set | 46 | # CONFIG_IKCONFIG is not set |
| 47 | CONFIG_LOG_BUF_SHIFT=14 | 47 | CONFIG_LOG_BUF_SHIFT=14 |
| 48 | # CONFIG_CGROUPS is not set | ||
| 49 | CONFIG_GROUP_SCHED=y | 48 | CONFIG_GROUP_SCHED=y |
| 50 | CONFIG_FAIR_GROUP_SCHED=y | 49 | CONFIG_FAIR_GROUP_SCHED=y |
| 51 | # CONFIG_RT_GROUP_SCHED is not set | 50 | # CONFIG_RT_GROUP_SCHED is not set |
| 52 | CONFIG_USER_SCHED=y | 51 | CONFIG_USER_SCHED=y |
| 53 | # CONFIG_CGROUP_SCHED is not set | 52 | # CONFIG_CGROUP_SCHED is not set |
| 53 | # CONFIG_CGROUPS is not set | ||
| 54 | CONFIG_SYSFS_DEPRECATED=y | 54 | CONFIG_SYSFS_DEPRECATED=y |
| 55 | CONFIG_SYSFS_DEPRECATED_V2=y | 55 | CONFIG_SYSFS_DEPRECATED_V2=y |
| 56 | # CONFIG_RELAY is not set | 56 | # CONFIG_RELAY is not set |
| @@ -378,6 +378,7 @@ CONFIG_WIRELESS=y | |||
| 378 | # CONFIG_WIRELESS_EXT is not set | 378 | # CONFIG_WIRELESS_EXT is not set |
| 379 | # CONFIG_LIB80211 is not set | 379 | # CONFIG_LIB80211 is not set |
| 380 | # CONFIG_MAC80211 is not set | 380 | # CONFIG_MAC80211 is not set |
| 381 | # CONFIG_WIMAX is not set | ||
| 381 | # CONFIG_RFKILL is not set | 382 | # CONFIG_RFKILL is not set |
| 382 | # CONFIG_NET_9P is not set | 383 | # CONFIG_NET_9P is not set |
| 383 | 384 | ||
| @@ -400,6 +401,7 @@ CONFIG_MTD=y | |||
| 400 | # CONFIG_MTD_DEBUG is not set | 401 | # CONFIG_MTD_DEBUG is not set |
| 401 | CONFIG_MTD_CONCAT=y | 402 | CONFIG_MTD_CONCAT=y |
| 402 | CONFIG_MTD_PARTITIONS=y | 403 | CONFIG_MTD_PARTITIONS=y |
| 404 | # CONFIG_MTD_TESTS is not set | ||
| 403 | # CONFIG_MTD_REDBOOT_PARTS is not set | 405 | # CONFIG_MTD_REDBOOT_PARTS is not set |
| 404 | CONFIG_MTD_CMDLINE_PARTS=y | 406 | CONFIG_MTD_CMDLINE_PARTS=y |
| 405 | # CONFIG_MTD_AR7_PARTS is not set | 407 | # CONFIG_MTD_AR7_PARTS is not set |
| @@ -447,9 +449,7 @@ CONFIG_MTD_CFI_UTIL=y | |||
| 447 | # | 449 | # |
| 448 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set | 450 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set |
| 449 | CONFIG_MTD_PHYSMAP=y | 451 | CONFIG_MTD_PHYSMAP=y |
| 450 | CONFIG_MTD_PHYSMAP_START=0xffffffff | 452 | # CONFIG_MTD_PHYSMAP_COMPAT is not set |
| 451 | CONFIG_MTD_PHYSMAP_LEN=0 | ||
| 452 | CONFIG_MTD_PHYSMAP_BANKWIDTH=0 | ||
| 453 | # CONFIG_MTD_PLATRAM is not set | 453 | # CONFIG_MTD_PLATRAM is not set |
| 454 | 454 | ||
| 455 | # | 455 | # |
| @@ -480,6 +480,12 @@ CONFIG_MTD_NAND_SH_FLCTL=y | |||
| 480 | # CONFIG_MTD_ONENAND is not set | 480 | # CONFIG_MTD_ONENAND is not set |
| 481 | 481 | ||
| 482 | # | 482 | # |
| 483 | # LPDDR flash memory drivers | ||
| 484 | # | ||
| 485 | # CONFIG_MTD_LPDDR is not set | ||
| 486 | # CONFIG_MTD_QINFO_PROBE is not set | ||
| 487 | |||
| 488 | # | ||
| 483 | # UBI - Unsorted block images | 489 | # UBI - Unsorted block images |
| 484 | # | 490 | # |
| 485 | CONFIG_MTD_UBI=y | 491 | CONFIG_MTD_UBI=y |
| @@ -607,6 +613,10 @@ CONFIG_SMSC911X=y | |||
| 607 | # CONFIG_WLAN_PRE80211 is not set | 613 | # CONFIG_WLAN_PRE80211 is not set |
| 608 | # CONFIG_WLAN_80211 is not set | 614 | # CONFIG_WLAN_80211 is not set |
| 609 | # CONFIG_IWLWIFI_LEDS is not set | 615 | # CONFIG_IWLWIFI_LEDS is not set |
| 616 | |||
| 617 | # | ||
| 618 | # Enable WiMAX (Networking options) to see the WiMAX drivers | ||
| 619 | # | ||
| 610 | # CONFIG_WAN is not set | 620 | # CONFIG_WAN is not set |
| 611 | # CONFIG_PPP is not set | 621 | # CONFIG_PPP is not set |
| 612 | # CONFIG_SLIP is not set | 622 | # CONFIG_SLIP is not set |
| @@ -790,6 +800,7 @@ CONFIG_SSB_POSSIBLE=y | |||
| 790 | # CONFIG_PMIC_DA903X is not set | 800 | # CONFIG_PMIC_DA903X is not set |
| 791 | # CONFIG_MFD_WM8400 is not set | 801 | # CONFIG_MFD_WM8400 is not set |
| 792 | # CONFIG_MFD_WM8350_I2C is not set | 802 | # CONFIG_MFD_WM8350_I2C is not set |
| 803 | # CONFIG_MFD_PCF50633 is not set | ||
| 793 | # CONFIG_REGULATOR is not set | 804 | # CONFIG_REGULATOR is not set |
| 794 | 805 | ||
| 795 | # | 806 | # |
| @@ -837,7 +848,7 @@ CONFIG_SOC_CAMERA=y | |||
| 837 | # CONFIG_SOC_CAMERA_MT9V022 is not set | 848 | # CONFIG_SOC_CAMERA_MT9V022 is not set |
| 838 | # CONFIG_SOC_CAMERA_TW9910 is not set | 849 | # CONFIG_SOC_CAMERA_TW9910 is not set |
| 839 | CONFIG_SOC_CAMERA_PLATFORM=y | 850 | CONFIG_SOC_CAMERA_PLATFORM=y |
| 840 | # CONFIG_SOC_CAMERA_OV772X is not set | 851 | CONFIG_SOC_CAMERA_OV772X=y |
| 841 | CONFIG_VIDEO_SH_MOBILE_CEU=y | 852 | CONFIG_VIDEO_SH_MOBILE_CEU=y |
| 842 | # CONFIG_RADIO_ADAPTERS is not set | 853 | # CONFIG_RADIO_ADAPTERS is not set |
| 843 | # CONFIG_DAB is not set | 854 | # CONFIG_DAB is not set |
| @@ -1012,6 +1023,7 @@ CONFIG_FS_POSIX_ACL=y | |||
| 1012 | CONFIG_FILE_LOCKING=y | 1023 | CONFIG_FILE_LOCKING=y |
| 1013 | # CONFIG_XFS_FS is not set | 1024 | # CONFIG_XFS_FS is not set |
| 1014 | # CONFIG_OCFS2_FS is not set | 1025 | # CONFIG_OCFS2_FS is not set |
| 1026 | # CONFIG_BTRFS_FS is not set | ||
| 1015 | CONFIG_DNOTIFY=y | 1027 | CONFIG_DNOTIFY=y |
| 1016 | CONFIG_INOTIFY=y | 1028 | CONFIG_INOTIFY=y |
| 1017 | CONFIG_INOTIFY_USER=y | 1029 | CONFIG_INOTIFY_USER=y |
| @@ -1060,6 +1072,7 @@ CONFIG_MISC_FILESYSTEMS=y | |||
| 1060 | # CONFIG_JFFS2_FS is not set | 1072 | # CONFIG_JFFS2_FS is not set |
| 1061 | # CONFIG_UBIFS_FS is not set | 1073 | # CONFIG_UBIFS_FS is not set |
| 1062 | # CONFIG_CRAMFS is not set | 1074 | # CONFIG_CRAMFS is not set |
| 1075 | # CONFIG_SQUASHFS is not set | ||
| 1063 | # CONFIG_VXFS_FS is not set | 1076 | # CONFIG_VXFS_FS is not set |
| 1064 | # CONFIG_MINIX_FS is not set | 1077 | # CONFIG_MINIX_FS is not set |
| 1065 | # CONFIG_OMFS_FS is not set | 1078 | # CONFIG_OMFS_FS is not set |
diff --git a/arch/sh/configs/migor_defconfig b/arch/sh/configs/migor_defconfig index 7758263514bc..678576796bdf 100644 --- a/arch/sh/configs/migor_defconfig +++ b/arch/sh/configs/migor_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.28 | 3 | # Linux kernel version: 2.6.29-rc1 |
| 4 | # Fri Jan 9 17:09:35 2009 | 4 | # Thu Jan 22 09:16:16 2009 |
| 5 | # | 5 | # |
| 6 | CONFIG_SUPERH=y | 6 | CONFIG_SUPERH=y |
| 7 | CONFIG_SUPERH32=y | 7 | CONFIG_SUPERH32=y |
| @@ -45,8 +45,12 @@ CONFIG_SYSVIPC_SYSCTL=y | |||
| 45 | CONFIG_IKCONFIG=y | 45 | CONFIG_IKCONFIG=y |
| 46 | CONFIG_IKCONFIG_PROC=y | 46 | CONFIG_IKCONFIG_PROC=y |
| 47 | CONFIG_LOG_BUF_SHIFT=14 | 47 | CONFIG_LOG_BUF_SHIFT=14 |
| 48 | # CONFIG_CGROUPS is not set | ||
| 49 | # CONFIG_GROUP_SCHED is not set | 48 | # CONFIG_GROUP_SCHED is not set |
| 49 | |||
| 50 | # | ||
| 51 | # Control Group support | ||
| 52 | # | ||
| 53 | # CONFIG_CGROUPS is not set | ||
| 50 | CONFIG_SYSFS_DEPRECATED=y | 54 | CONFIG_SYSFS_DEPRECATED=y |
| 51 | CONFIG_SYSFS_DEPRECATED_V2=y | 55 | CONFIG_SYSFS_DEPRECATED_V2=y |
| 52 | # CONFIG_RELAY is not set | 56 | # CONFIG_RELAY is not set |
| @@ -389,6 +393,7 @@ CONFIG_WIRELESS_EXT=y | |||
| 389 | CONFIG_WIRELESS_EXT_SYSFS=y | 393 | CONFIG_WIRELESS_EXT_SYSFS=y |
| 390 | # CONFIG_LIB80211 is not set | 394 | # CONFIG_LIB80211 is not set |
| 391 | # CONFIG_MAC80211 is not set | 395 | # CONFIG_MAC80211 is not set |
| 396 | # CONFIG_WIMAX is not set | ||
| 392 | # CONFIG_RFKILL is not set | 397 | # CONFIG_RFKILL is not set |
| 393 | # CONFIG_NET_9P is not set | 398 | # CONFIG_NET_9P is not set |
| 394 | 399 | ||
| @@ -411,6 +416,7 @@ CONFIG_MTD=y | |||
| 411 | # CONFIG_MTD_DEBUG is not set | 416 | # CONFIG_MTD_DEBUG is not set |
| 412 | CONFIG_MTD_CONCAT=y | 417 | CONFIG_MTD_CONCAT=y |
| 413 | CONFIG_MTD_PARTITIONS=y | 418 | CONFIG_MTD_PARTITIONS=y |
| 419 | # CONFIG_MTD_TESTS is not set | ||
| 414 | # CONFIG_MTD_REDBOOT_PARTS is not set | 420 | # CONFIG_MTD_REDBOOT_PARTS is not set |
| 415 | CONFIG_MTD_CMDLINE_PARTS=y | 421 | CONFIG_MTD_CMDLINE_PARTS=y |
| 416 | # CONFIG_MTD_AR7_PARTS is not set | 422 | # CONFIG_MTD_AR7_PARTS is not set |
| @@ -458,9 +464,7 @@ CONFIG_MTD_CFI_UTIL=y | |||
| 458 | # | 464 | # |
| 459 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set | 465 | # CONFIG_MTD_COMPLEX_MAPPINGS is not set |
| 460 | CONFIG_MTD_PHYSMAP=y | 466 | CONFIG_MTD_PHYSMAP=y |
| 461 | CONFIG_MTD_PHYSMAP_START=0xffffffff | 467 | # CONFIG_MTD_PHYSMAP_COMPAT is not set |
| 462 | CONFIG_MTD_PHYSMAP_LEN=0 | ||
| 463 | CONFIG_MTD_PHYSMAP_BANKWIDTH=0 | ||
| 464 | # CONFIG_MTD_PLATRAM is not set | 468 | # CONFIG_MTD_PLATRAM is not set |
| 465 | 469 | ||
| 466 | # | 470 | # |
| @@ -488,6 +492,12 @@ CONFIG_MTD_NAND_PLATFORM=y | |||
| 488 | # CONFIG_MTD_ONENAND is not set | 492 | # CONFIG_MTD_ONENAND is not set |
| 489 | 493 | ||
| 490 | # | 494 | # |
| 495 | # LPDDR flash memory drivers | ||
| 496 | # | ||
| 497 | # CONFIG_MTD_LPDDR is not set | ||
| 498 | # CONFIG_MTD_QINFO_PROBE is not set | ||
| 499 | |||
| 500 | # | ||
| 491 | # UBI - Unsorted block images | 501 | # UBI - Unsorted block images |
| 492 | # | 502 | # |
| 493 | # CONFIG_MTD_UBI is not set | 503 | # CONFIG_MTD_UBI is not set |
| @@ -587,6 +597,10 @@ CONFIG_SMC91X=y | |||
| 587 | # CONFIG_WLAN_PRE80211 is not set | 597 | # CONFIG_WLAN_PRE80211 is not set |
| 588 | # CONFIG_WLAN_80211 is not set | 598 | # CONFIG_WLAN_80211 is not set |
| 589 | # CONFIG_IWLWIFI_LEDS is not set | 599 | # CONFIG_IWLWIFI_LEDS is not set |
| 600 | |||
| 601 | # | ||
| 602 | # Enable WiMAX (Networking options) to see the WiMAX drivers | ||
| 603 | # | ||
| 590 | # CONFIG_WAN is not set | 604 | # CONFIG_WAN is not set |
| 591 | # CONFIG_PPP is not set | 605 | # CONFIG_PPP is not set |
| 592 | # CONFIG_SLIP is not set | 606 | # CONFIG_SLIP is not set |
| @@ -761,6 +775,7 @@ CONFIG_SSB_POSSIBLE=y | |||
| 761 | # CONFIG_PMIC_DA903X is not set | 775 | # CONFIG_PMIC_DA903X is not set |
| 762 | # CONFIG_MFD_WM8400 is not set | 776 | # CONFIG_MFD_WM8400 is not set |
| 763 | # CONFIG_MFD_WM8350_I2C is not set | 777 | # CONFIG_MFD_WM8350_I2C is not set |
| 778 | # CONFIG_MFD_PCF50633 is not set | ||
| 764 | # CONFIG_REGULATOR is not set | 779 | # CONFIG_REGULATOR is not set |
| 765 | 780 | ||
| 766 | # | 781 | # |
| @@ -806,9 +821,9 @@ CONFIG_SOC_CAMERA=y | |||
| 806 | # CONFIG_SOC_CAMERA_MT9M111 is not set | 821 | # CONFIG_SOC_CAMERA_MT9M111 is not set |
| 807 | # CONFIG_SOC_CAMERA_MT9T031 is not set | 822 | # CONFIG_SOC_CAMERA_MT9T031 is not set |
| 808 | # CONFIG_SOC_CAMERA_MT9V022 is not set | 823 | # CONFIG_SOC_CAMERA_MT9V022 is not set |
| 809 | # CONFIG_SOC_CAMERA_TW9910 is not set | 824 | CONFIG_SOC_CAMERA_TW9910=y |
| 810 | CONFIG_SOC_CAMERA_PLATFORM=y | 825 | # CONFIG_SOC_CAMERA_PLATFORM is not set |
| 811 | # CONFIG_SOC_CAMERA_OV772X is not set | 826 | CONFIG_SOC_CAMERA_OV772X=y |
| 812 | CONFIG_VIDEO_SH_MOBILE_CEU=y | 827 | CONFIG_VIDEO_SH_MOBILE_CEU=y |
| 813 | # CONFIG_RADIO_ADAPTERS is not set | 828 | # CONFIG_RADIO_ADAPTERS is not set |
| 814 | # CONFIG_DAB is not set | 829 | # CONFIG_DAB is not set |
| @@ -866,11 +881,13 @@ CONFIG_USB_GADGET_SELECTED=y | |||
| 866 | # CONFIG_USB_GADGET_PXA25X is not set | 881 | # CONFIG_USB_GADGET_PXA25X is not set |
| 867 | # CONFIG_USB_GADGET_PXA27X is not set | 882 | # CONFIG_USB_GADGET_PXA27X is not set |
| 868 | # CONFIG_USB_GADGET_S3C2410 is not set | 883 | # CONFIG_USB_GADGET_S3C2410 is not set |
| 884 | # CONFIG_USB_GADGET_IMX is not set | ||
| 869 | CONFIG_USB_GADGET_M66592=y | 885 | CONFIG_USB_GADGET_M66592=y |
| 870 | CONFIG_USB_M66592=y | 886 | CONFIG_USB_M66592=y |
| 871 | CONFIG_SUPERH_BUILT_IN_M66592=y | 887 | CONFIG_SUPERH_BUILT_IN_M66592=y |
| 872 | # CONFIG_USB_GADGET_AMD5536UDC is not set | 888 | # CONFIG_USB_GADGET_AMD5536UDC is not set |
| 873 | # CONFIG_USB_GADGET_FSL_QE is not set | 889 | # CONFIG_USB_GADGET_FSL_QE is not set |
| 890 | # CONFIG_USB_GADGET_CI13XXX is not set | ||
| 874 | # CONFIG_USB_GADGET_NET2280 is not set | 891 | # CONFIG_USB_GADGET_NET2280 is not set |
| 875 | # CONFIG_USB_GADGET_GOKU is not set | 892 | # CONFIG_USB_GADGET_GOKU is not set |
| 876 | # CONFIG_USB_GADGET_DUMMY_HCD is not set | 893 | # CONFIG_USB_GADGET_DUMMY_HCD is not set |
| @@ -883,6 +900,11 @@ CONFIG_USB_G_SERIAL=y | |||
| 883 | # CONFIG_USB_MIDI_GADGET is not set | 900 | # CONFIG_USB_MIDI_GADGET is not set |
| 884 | # CONFIG_USB_G_PRINTER is not set | 901 | # CONFIG_USB_G_PRINTER is not set |
| 885 | # CONFIG_USB_CDC_COMPOSITE is not set | 902 | # CONFIG_USB_CDC_COMPOSITE is not set |
| 903 | |||
| 904 | # | ||
| 905 | # OTG and related infrastructure | ||
| 906 | # | ||
| 907 | # CONFIG_USB_GPIO_VBUS is not set | ||
| 886 | # CONFIG_MMC is not set | 908 | # CONFIG_MMC is not set |
| 887 | # CONFIG_MEMSTICK is not set | 909 | # CONFIG_MEMSTICK is not set |
| 888 | # CONFIG_NEW_LEDS is not set | 910 | # CONFIG_NEW_LEDS is not set |
| @@ -961,6 +983,7 @@ CONFIG_UIO_PDRV_GENIRQ=y | |||
| 961 | CONFIG_FILE_LOCKING=y | 983 | CONFIG_FILE_LOCKING=y |
| 962 | # CONFIG_XFS_FS is not set | 984 | # CONFIG_XFS_FS is not set |
| 963 | # CONFIG_OCFS2_FS is not set | 985 | # CONFIG_OCFS2_FS is not set |
| 986 | # CONFIG_BTRFS_FS is not set | ||
| 964 | # CONFIG_DNOTIFY is not set | 987 | # CONFIG_DNOTIFY is not set |
| 965 | # CONFIG_INOTIFY is not set | 988 | # CONFIG_INOTIFY is not set |
| 966 | # CONFIG_QUOTA is not set | 989 | # CONFIG_QUOTA is not set |
| @@ -1004,6 +1027,7 @@ CONFIG_MISC_FILESYSTEMS=y | |||
| 1004 | # CONFIG_EFS_FS is not set | 1027 | # CONFIG_EFS_FS is not set |
| 1005 | # CONFIG_JFFS2_FS is not set | 1028 | # CONFIG_JFFS2_FS is not set |
| 1006 | # CONFIG_CRAMFS is not set | 1029 | # CONFIG_CRAMFS is not set |
| 1030 | # CONFIG_SQUASHFS is not set | ||
| 1007 | # CONFIG_VXFS_FS is not set | 1031 | # CONFIG_VXFS_FS is not set |
| 1008 | # CONFIG_MINIX_FS is not set | 1032 | # CONFIG_MINIX_FS is not set |
| 1009 | # CONFIG_OMFS_FS is not set | 1033 | # CONFIG_OMFS_FS is not set |
diff --git a/arch/sh/include/asm/mutex-llsc.h b/arch/sh/include/asm/mutex-llsc.h index ee839ee58ac8..090358a7e1bb 100644 --- a/arch/sh/include/asm/mutex-llsc.h +++ b/arch/sh/include/asm/mutex-llsc.h | |||
| @@ -21,38 +21,36 @@ | |||
| 21 | static inline void | 21 | static inline void |
| 22 | __mutex_fastpath_lock(atomic_t *count, void (*fail_fn)(atomic_t *)) | 22 | __mutex_fastpath_lock(atomic_t *count, void (*fail_fn)(atomic_t *)) |
| 23 | { | 23 | { |
| 24 | int __ex_flag, __res; | 24 | int __done, __res; |
| 25 | 25 | ||
| 26 | __asm__ __volatile__ ( | 26 | __asm__ __volatile__ ( |
| 27 | "movli.l @%2, %0 \n" | 27 | "movli.l @%2, %0 \n" |
| 28 | "add #-1, %0 \n" | 28 | "add #-1, %0 \n" |
| 29 | "movco.l %0, @%2 \n" | 29 | "movco.l %0, @%2 \n" |
| 30 | "movt %1 \n" | 30 | "movt %1 \n" |
| 31 | : "=&z" (__res), "=&r" (__ex_flag) | 31 | : "=&z" (__res), "=&r" (__done) |
| 32 | : "r" (&(count)->counter) | 32 | : "r" (&(count)->counter) |
| 33 | : "t"); | 33 | : "t"); |
| 34 | 34 | ||
| 35 | __res |= !__ex_flag; | 35 | if (unlikely(!__done || __res != 0)) |
| 36 | if (unlikely(__res != 0)) | ||
| 37 | fail_fn(count); | 36 | fail_fn(count); |
| 38 | } | 37 | } |
| 39 | 38 | ||
| 40 | static inline int | 39 | static inline int |
| 41 | __mutex_fastpath_lock_retval(atomic_t *count, int (*fail_fn)(atomic_t *)) | 40 | __mutex_fastpath_lock_retval(atomic_t *count, int (*fail_fn)(atomic_t *)) |
| 42 | { | 41 | { |
| 43 | int __ex_flag, __res; | 42 | int __done, __res; |
| 44 | 43 | ||
| 45 | __asm__ __volatile__ ( | 44 | __asm__ __volatile__ ( |
| 46 | "movli.l @%2, %0 \n" | 45 | "movli.l @%2, %0 \n" |
| 47 | "add #-1, %0 \n" | 46 | "add #-1, %0 \n" |
| 48 | "movco.l %0, @%2 \n" | 47 | "movco.l %0, @%2 \n" |
| 49 | "movt %1 \n" | 48 | "movt %1 \n" |
| 50 | : "=&z" (__res), "=&r" (__ex_flag) | 49 | : "=&z" (__res), "=&r" (__done) |
| 51 | : "r" (&(count)->counter) | 50 | : "r" (&(count)->counter) |
| 52 | : "t"); | 51 | : "t"); |
| 53 | 52 | ||
| 54 | __res |= !__ex_flag; | 53 | if (unlikely(!__done || __res != 0)) |
| 55 | if (unlikely(__res != 0)) | ||
| 56 | __res = fail_fn(count); | 54 | __res = fail_fn(count); |
| 57 | 55 | ||
| 58 | return __res; | 56 | return __res; |
| @@ -61,19 +59,18 @@ __mutex_fastpath_lock_retval(atomic_t *count, int (*fail_fn)(atomic_t *)) | |||
| 61 | static inline void | 59 | static inline void |
| 62 | __mutex_fastpath_unlock(atomic_t *count, void (*fail_fn)(atomic_t *)) | 60 | __mutex_fastpath_unlock(atomic_t *count, void (*fail_fn)(atomic_t *)) |
| 63 | { | 61 | { |
| 64 | int __ex_flag, __res; | 62 | int __done, __res; |
| 65 | 63 | ||
| 66 | __asm__ __volatile__ ( | 64 | __asm__ __volatile__ ( |
| 67 | "movli.l @%2, %0 \n\t" | 65 | "movli.l @%2, %0 \n\t" |
| 68 | "add #1, %0 \n\t" | 66 | "add #1, %0 \n\t" |
| 69 | "movco.l %0, @%2 \n\t" | 67 | "movco.l %0, @%2 \n\t" |
| 70 | "movt %1 \n\t" | 68 | "movt %1 \n\t" |
| 71 | : "=&z" (__res), "=&r" (__ex_flag) | 69 | : "=&z" (__res), "=&r" (__done) |
| 72 | : "r" (&(count)->counter) | 70 | : "r" (&(count)->counter) |
| 73 | : "t"); | 71 | : "t"); |
| 74 | 72 | ||
| 75 | __res |= !__ex_flag; | 73 | if (unlikely(!__done || __res <= 0)) |
| 76 | if (unlikely(__res <= 0)) | ||
| 77 | fail_fn(count); | 74 | fail_fn(count); |
| 78 | } | 75 | } |
| 79 | 76 | ||
diff --git a/arch/sh/include/asm/syscall_32.h b/arch/sh/include/asm/syscall_32.h index 05a868a71ef5..5bc34681d994 100644 --- a/arch/sh/include/asm/syscall_32.h +++ b/arch/sh/include/asm/syscall_32.h | |||
| @@ -21,23 +21,10 @@ static inline void syscall_rollback(struct task_struct *task, | |||
| 21 | */ | 21 | */ |
| 22 | } | 22 | } |
| 23 | 23 | ||
| 24 | static inline bool syscall_has_error(struct pt_regs *regs) | ||
| 25 | { | ||
| 26 | return (regs->sr & 0x1) ? true : false; | ||
| 27 | } | ||
| 28 | static inline void syscall_set_error(struct pt_regs *regs) | ||
| 29 | { | ||
| 30 | regs->sr |= 0x1; | ||
| 31 | } | ||
| 32 | static inline void syscall_clear_error(struct pt_regs *regs) | ||
| 33 | { | ||
| 34 | regs->sr &= ~0x1; | ||
| 35 | } | ||
| 36 | |||
| 37 | static inline long syscall_get_error(struct task_struct *task, | 24 | static inline long syscall_get_error(struct task_struct *task, |
| 38 | struct pt_regs *regs) | 25 | struct pt_regs *regs) |
| 39 | { | 26 | { |
| 40 | return syscall_has_error(regs) ? regs->regs[0] : 0; | 27 | return IS_ERR_VALUE(regs->regs[0]) ? regs->regs[0] : 0; |
| 41 | } | 28 | } |
| 42 | 29 | ||
| 43 | static inline long syscall_get_return_value(struct task_struct *task, | 30 | static inline long syscall_get_return_value(struct task_struct *task, |
| @@ -50,13 +37,10 @@ static inline void syscall_set_return_value(struct task_struct *task, | |||
| 50 | struct pt_regs *regs, | 37 | struct pt_regs *regs, |
| 51 | int error, long val) | 38 | int error, long val) |
| 52 | { | 39 | { |
| 53 | if (error) { | 40 | if (error) |
| 54 | syscall_set_error(regs); | ||
| 55 | regs->regs[0] = -error; | 41 | regs->regs[0] = -error; |
| 56 | } else { | 42 | else |
| 57 | syscall_clear_error(regs); | ||
| 58 | regs->regs[0] = val; | 43 | regs->regs[0] = val; |
| 59 | } | ||
| 60 | } | 44 | } |
| 61 | 45 | ||
| 62 | static inline void syscall_get_arguments(struct task_struct *task, | 46 | static inline void syscall_get_arguments(struct task_struct *task, |
diff --git a/arch/sh/include/asm/syscall_64.h b/arch/sh/include/asm/syscall_64.h index e1143b9784d6..c3561ca72bee 100644 --- a/arch/sh/include/asm/syscall_64.h +++ b/arch/sh/include/asm/syscall_64.h | |||
| @@ -21,23 +21,10 @@ static inline void syscall_rollback(struct task_struct *task, | |||
| 21 | */ | 21 | */ |
| 22 | } | 22 | } |
| 23 | 23 | ||
| 24 | static inline bool syscall_has_error(struct pt_regs *regs) | ||
| 25 | { | ||
| 26 | return (regs->sr & 0x1) ? true : false; | ||
| 27 | } | ||
| 28 | static inline void syscall_set_error(struct pt_regs *regs) | ||
| 29 | { | ||
| 30 | regs->sr |= 0x1; | ||
| 31 | } | ||
| 32 | static inline void syscall_clear_error(struct pt_regs *regs) | ||
| 33 | { | ||
| 34 | regs->sr &= ~0x1; | ||
| 35 | } | ||
| 36 | |||
| 37 | static inline long syscall_get_error(struct task_struct *task, | 24 | static inline long syscall_get_error(struct task_struct *task, |
| 38 | struct pt_regs *regs) | 25 | struct pt_regs *regs) |
| 39 | { | 26 | { |
| 40 | return syscall_has_error(regs) ? regs->regs[9] : 0; | 27 | return IS_ERR_VALUE(regs->regs[9]) ? regs->regs[9] : 0; |
| 41 | } | 28 | } |
| 42 | 29 | ||
| 43 | static inline long syscall_get_return_value(struct task_struct *task, | 30 | static inline long syscall_get_return_value(struct task_struct *task, |
| @@ -50,13 +37,10 @@ static inline void syscall_set_return_value(struct task_struct *task, | |||
| 50 | struct pt_regs *regs, | 37 | struct pt_regs *regs, |
| 51 | int error, long val) | 38 | int error, long val) |
| 52 | { | 39 | { |
| 53 | if (error) { | 40 | if (error) |
| 54 | syscall_set_error(regs); | ||
| 55 | regs->regs[9] = -error; | 41 | regs->regs[9] = -error; |
| 56 | } else { | 42 | else |
| 57 | syscall_clear_error(regs); | ||
| 58 | regs->regs[9] = val; | 43 | regs->regs[9] = val; |
| 59 | } | ||
| 60 | } | 44 | } |
| 61 | 45 | ||
| 62 | static inline void syscall_get_arguments(struct task_struct *task, | 46 | static inline void syscall_get_arguments(struct task_struct *task, |
diff --git a/arch/sh/kernel/cpu/sh4/fpu.c b/arch/sh/kernel/cpu/sh4/fpu.c index 2780917c0088..e3ea5411da6d 100644 --- a/arch/sh/kernel/cpu/sh4/fpu.c +++ b/arch/sh/kernel/cpu/sh4/fpu.c | |||
| @@ -423,7 +423,7 @@ static int ieee_fpe_handler(struct pt_regs *regs) | |||
| 423 | int m; | 423 | int m; |
| 424 | unsigned int hx; | 424 | unsigned int hx; |
| 425 | 425 | ||
| 426 | m = (finsn >> 9) & 0x7; | 426 | m = (finsn >> 8) & 0x7; |
| 427 | hx = tsk->thread.fpu.hard.fp_regs[m]; | 427 | hx = tsk->thread.fpu.hard.fp_regs[m]; |
| 428 | 428 | ||
| 429 | if ((tsk->thread.fpu.hard.fpscr & FPSCR_CAUSE_ERROR) | 429 | if ((tsk->thread.fpu.hard.fpscr & FPSCR_CAUSE_ERROR) |
diff --git a/arch/sh/kernel/setup.c b/arch/sh/kernel/setup.c index 534247508572..370d2cfa34eb 100644 --- a/arch/sh/kernel/setup.c +++ b/arch/sh/kernel/setup.c | |||
| @@ -262,11 +262,11 @@ void __init setup_bootmem_allocator(unsigned long free_pfn) | |||
| 262 | BOOTMEM_DEFAULT); | 262 | BOOTMEM_DEFAULT); |
| 263 | 263 | ||
| 264 | /* | 264 | /* |
| 265 | * reserve physical page 0 - it's a special BIOS page on many boxes, | 265 | * Reserve physical pages below CONFIG_ZERO_PAGE_OFFSET. |
| 266 | * enabling clean reboots, SMP operation, laptop functions. | ||
| 267 | */ | 266 | */ |
| 268 | reserve_bootmem(__MEMORY_START, CONFIG_ZERO_PAGE_OFFSET, | 267 | if (CONFIG_ZERO_PAGE_OFFSET != 0) |
| 269 | BOOTMEM_DEFAULT); | 268 | reserve_bootmem(__MEMORY_START, CONFIG_ZERO_PAGE_OFFSET, |
| 269 | BOOTMEM_DEFAULT); | ||
| 270 | 270 | ||
| 271 | sparse_memory_present_with_active_regions(0); | 271 | sparse_memory_present_with_active_regions(0); |
| 272 | 272 | ||
diff --git a/arch/sh/kernel/signal_32.c b/arch/sh/kernel/signal_32.c index 77c21bde376a..17784e19ae34 100644 --- a/arch/sh/kernel/signal_32.c +++ b/arch/sh/kernel/signal_32.c | |||
| @@ -510,7 +510,6 @@ handle_syscall_restart(unsigned long save_r0, struct pt_regs *regs, | |||
| 510 | case -ERESTARTNOHAND: | 510 | case -ERESTARTNOHAND: |
| 511 | no_system_call_restart: | 511 | no_system_call_restart: |
| 512 | regs->regs[0] = -EINTR; | 512 | regs->regs[0] = -EINTR; |
| 513 | regs->sr |= 1; | ||
| 514 | break; | 513 | break; |
| 515 | 514 | ||
| 516 | case -ERESTARTSYS: | 515 | case -ERESTARTSYS: |
| @@ -589,8 +588,7 @@ static void do_signal(struct pt_regs *regs, unsigned int save_r0) | |||
| 589 | 588 | ||
| 590 | signr = get_signal_to_deliver(&info, &ka, regs, NULL); | 589 | signr = get_signal_to_deliver(&info, &ka, regs, NULL); |
| 591 | if (signr > 0) { | 590 | if (signr > 0) { |
| 592 | if (regs->sr & 1) | 591 | handle_syscall_restart(save_r0, regs, &ka.sa); |
| 593 | handle_syscall_restart(save_r0, regs, &ka.sa); | ||
| 594 | 592 | ||
| 595 | /* Whee! Actually deliver the signal. */ | 593 | /* Whee! Actually deliver the signal. */ |
| 596 | if (handle_signal(signr, &ka, &info, oldset, | 594 | if (handle_signal(signr, &ka, &info, oldset, |
diff --git a/arch/sh/kernel/signal_64.c b/arch/sh/kernel/signal_64.c index b22fdfaaa191..0663a0ee6021 100644 --- a/arch/sh/kernel/signal_64.c +++ b/arch/sh/kernel/signal_64.c | |||
| @@ -60,7 +60,6 @@ handle_syscall_restart(struct pt_regs *regs, struct sigaction *sa) | |||
| 60 | case -ERESTARTNOHAND: | 60 | case -ERESTARTNOHAND: |
| 61 | no_system_call_restart: | 61 | no_system_call_restart: |
| 62 | regs->regs[REG_RET] = -EINTR; | 62 | regs->regs[REG_RET] = -EINTR; |
| 63 | regs->sr |= 1; | ||
| 64 | break; | 63 | break; |
| 65 | 64 | ||
| 66 | case -ERESTARTSYS: | 65 | case -ERESTARTSYS: |
| @@ -109,8 +108,7 @@ static int do_signal(struct pt_regs *regs, sigset_t *oldset) | |||
| 109 | 108 | ||
| 110 | signr = get_signal_to_deliver(&info, &ka, regs, 0); | 109 | signr = get_signal_to_deliver(&info, &ka, regs, 0); |
| 111 | if (signr > 0) { | 110 | if (signr > 0) { |
| 112 | if (regs->sr & 1) | 111 | handle_syscall_restart(regs, &ka.sa); |
| 113 | handle_syscall_restart(regs, &ka.sa); | ||
| 114 | 112 | ||
| 115 | /* Whee! Actually deliver the signal. */ | 113 | /* Whee! Actually deliver the signal. */ |
| 116 | if (handle_signal(signr, &info, &ka, oldset, regs) == 0) { | 114 | if (handle_signal(signr, &info, &ka, oldset, regs) == 0) { |
diff --git a/arch/sh/lib/checksum.S b/arch/sh/lib/checksum.S index cbdd0d40e545..356c8ec92893 100644 --- a/arch/sh/lib/checksum.S +++ b/arch/sh/lib/checksum.S | |||
| @@ -36,8 +36,7 @@ | |||
| 36 | */ | 36 | */ |
| 37 | 37 | ||
| 38 | /* | 38 | /* |
| 39 | * unsigned int csum_partial(const unsigned char *buf, int len, | 39 | * asmlinkage __wsum csum_partial(const void *buf, int len, __wsum sum); |
| 40 | * unsigned int sum); | ||
| 41 | */ | 40 | */ |
| 42 | 41 | ||
| 43 | .text | 42 | .text |
| @@ -49,11 +48,31 @@ ENTRY(csum_partial) | |||
| 49 | * Fortunately, it is easy to convert 2-byte alignment to 4-byte | 48 | * Fortunately, it is easy to convert 2-byte alignment to 4-byte |
| 50 | * alignment for the unrolled loop. | 49 | * alignment for the unrolled loop. |
| 51 | */ | 50 | */ |
| 52 | mov r5, r1 | ||
| 53 | mov r4, r0 | 51 | mov r4, r0 |
| 54 | tst #2, r0 ! Check alignment. | 52 | tst #3, r0 ! Check alignment. |
| 55 | bt 2f ! Jump if alignment is ok. | 53 | bt/s 2f ! Jump if alignment is ok. |
| 54 | mov r4, r7 ! Keep a copy to check for alignment | ||
| 56 | ! | 55 | ! |
| 56 | tst #1, r0 ! Check alignment. | ||
| 57 | bt 21f ! Jump if alignment is boundary of 2bytes. | ||
| 58 | |||
| 59 | ! buf is odd | ||
| 60 | tst r5, r5 | ||
| 61 | add #-1, r5 | ||
| 62 | bt 9f | ||
| 63 | mov.b @r4+, r0 | ||
| 64 | extu.b r0, r0 | ||
| 65 | addc r0, r6 ! t=0 from previous tst | ||
| 66 | mov r6, r0 | ||
| 67 | shll8 r6 | ||
| 68 | shlr16 r0 | ||
| 69 | shlr8 r0 | ||
| 70 | or r0, r6 | ||
| 71 | mov r4, r0 | ||
| 72 | tst #2, r0 | ||
| 73 | bt 2f | ||
| 74 | 21: | ||
| 75 | ! buf is 2 byte aligned (len could be 0) | ||
| 57 | add #-2, r5 ! Alignment uses up two bytes. | 76 | add #-2, r5 ! Alignment uses up two bytes. |
| 58 | cmp/pz r5 ! | 77 | cmp/pz r5 ! |
| 59 | bt/s 1f ! Jump if we had at least two bytes. | 78 | bt/s 1f ! Jump if we had at least two bytes. |
| @@ -61,16 +80,17 @@ ENTRY(csum_partial) | |||
| 61 | bra 6f | 80 | bra 6f |
| 62 | add #2, r5 ! r5 was < 2. Deal with it. | 81 | add #2, r5 ! r5 was < 2. Deal with it. |
| 63 | 1: | 82 | 1: |
| 64 | mov r5, r1 ! Save new len for later use. | ||
| 65 | mov.w @r4+, r0 | 83 | mov.w @r4+, r0 |
| 66 | extu.w r0, r0 | 84 | extu.w r0, r0 |
| 67 | addc r0, r6 | 85 | addc r0, r6 |
| 68 | bf 2f | 86 | bf 2f |
| 69 | add #1, r6 | 87 | add #1, r6 |
| 70 | 2: | 88 | 2: |
| 89 | ! buf is 4 byte aligned (len could be 0) | ||
| 90 | mov r5, r1 | ||
| 71 | mov #-5, r0 | 91 | mov #-5, r0 |
| 72 | shld r0, r5 | 92 | shld r0, r1 |
| 73 | tst r5, r5 | 93 | tst r1, r1 |
| 74 | bt/s 4f ! if it's =0, go to 4f | 94 | bt/s 4f ! if it's =0, go to 4f |
| 75 | clrt | 95 | clrt |
| 76 | .align 2 | 96 | .align 2 |
| @@ -92,30 +112,31 @@ ENTRY(csum_partial) | |||
| 92 | addc r0, r6 | 112 | addc r0, r6 |
| 93 | addc r2, r6 | 113 | addc r2, r6 |
| 94 | movt r0 | 114 | movt r0 |
| 95 | dt r5 | 115 | dt r1 |
| 96 | bf/s 3b | 116 | bf/s 3b |
| 97 | cmp/eq #1, r0 | 117 | cmp/eq #1, r0 |
| 98 | ! here, we know r5==0 | 118 | ! here, we know r1==0 |
| 99 | addc r5, r6 ! add carry to r6 | 119 | addc r1, r6 ! add carry to r6 |
| 100 | 4: | 120 | 4: |
| 101 | mov r1, r0 | 121 | mov r5, r0 |
| 102 | and #0x1c, r0 | 122 | and #0x1c, r0 |
| 103 | tst r0, r0 | 123 | tst r0, r0 |
| 104 | bt/s 6f | 124 | bt 6f |
| 105 | mov r0, r5 | 125 | ! 4 bytes or more remaining |
| 106 | shlr2 r5 | 126 | mov r0, r1 |
| 127 | shlr2 r1 | ||
| 107 | mov #0, r2 | 128 | mov #0, r2 |
| 108 | 5: | 129 | 5: |
| 109 | addc r2, r6 | 130 | addc r2, r6 |
| 110 | mov.l @r4+, r2 | 131 | mov.l @r4+, r2 |
| 111 | movt r0 | 132 | movt r0 |
| 112 | dt r5 | 133 | dt r1 |
| 113 | bf/s 5b | 134 | bf/s 5b |
| 114 | cmp/eq #1, r0 | 135 | cmp/eq #1, r0 |
| 115 | addc r2, r6 | 136 | addc r2, r6 |
| 116 | addc r5, r6 ! r5==0 here, so it means add carry-bit | 137 | addc r1, r6 ! r1==0 here, so it means add carry-bit |
| 117 | 6: | 138 | 6: |
| 118 | mov r1, r5 | 139 | ! 3 bytes or less remaining |
| 119 | mov #3, r0 | 140 | mov #3, r0 |
| 120 | and r0, r5 | 141 | and r0, r5 |
| 121 | tst r5, r5 | 142 | tst r5, r5 |
| @@ -139,8 +160,18 @@ ENTRY(csum_partial) | |||
| 139 | 8: | 160 | 8: |
| 140 | addc r0, r6 | 161 | addc r0, r6 |
| 141 | mov #0, r0 | 162 | mov #0, r0 |
| 142 | addc r0, r6 | 163 | addc r0, r6 |
| 143 | 9: | 164 | 9: |
| 165 | ! Check if the buffer was misaligned, if so realign sum | ||
| 166 | mov r7, r0 | ||
| 167 | tst #1, r0 | ||
| 168 | bt 10f | ||
| 169 | mov r6, r0 | ||
| 170 | shll8 r6 | ||
| 171 | shlr16 r0 | ||
| 172 | shlr8 r0 | ||
| 173 | or r0, r6 | ||
| 174 | 10: | ||
| 144 | rts | 175 | rts |
| 145 | mov r6, r0 | 176 | mov r6, r0 |
| 146 | 177 | ||
