Merge branch 'for-3.11' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k

Pull m68k updates from Geert Uytterhoeven.

* 'for-3.11' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k:
  m68k/q40: Enable PC parallel port in defconfig
  m68k/q40: Undefine insl/outsl before redefining them
  m68k/uaccess: Fix asm constraints for userspace access
  swim: Release memory region after incorrect return/goto
  m68k/irq: Vector ints need a valid interrupt handler
  m68k/math-emu: unsigned issue, 'unsigned long' will never be less than zero
  m68k: remove CONFIG_EARLY_PRINTK dependency on CONFIG_EMBEDDED, default to n
  m68k/sun3: remove inline marking of EXPORT_SYMBOL functions
  [SCSI] a3000: use module_platform_driver_probe()
  [SCSI] a4000t: use module_platform_driver_probe()
  m68k: Remove inline strcpy() and strcat() implementations
This commit is contained in:
Linus Torvalds 2013-07-03 11:11:23 -07:00
commit 0e97456ab5
15 changed files with 25 additions and 94 deletions

View File

@ -11,9 +11,8 @@ config BOOTPARAM_STRING
depends on BOOTPARAM
config EARLY_PRINTK
bool "Early printk" if EMBEDDED
bool "Early printk"
depends on MVME16x || MAC
default y
help
Write kernel log output directly to a serial port.

View File

@ -214,6 +214,7 @@ CONFIG_DEVTMPFS=y
# CONFIG_FW_LOADER_USER_HELPER is not set
CONFIG_CONNECTOR=m
CONFIG_PARPORT=m
CONFIG_PARPORT_PC=m
CONFIG_PARPORT_AMIGA=m
CONFIG_PARPORT_MFC3=m
CONFIG_PARPORT_ATARI=m
@ -325,6 +326,7 @@ CONFIG_ZORRO8390=y
# CONFIG_NET_VENDOR_SEEQ is not set
# CONFIG_NET_VENDOR_STMICRO is not set
# CONFIG_NET_VENDOR_WIZNET is not set
CONFIG_PLIP=m
CONFIG_PPP=m
CONFIG_PPP_BSDCOMP=m
CONFIG_PPP_DEFLATE=m

View File

@ -199,6 +199,9 @@ CONFIG_DEVTMPFS=y
# CONFIG_FIRMWARE_IN_KERNEL is not set
# CONFIG_FW_LOADER_USER_HELPER is not set
CONFIG_CONNECTOR=m
CONFIG_PARPORT=m
CONFIG_PARPORT_PC=m
CONFIG_PARPORT_1284=y
CONFIG_BLK_DEV_LOOP=y
CONFIG_BLK_DEV_CRYPTOLOOP=m
CONFIG_BLK_DEV_DRBD=m
@ -267,6 +270,7 @@ CONFIG_NE2000=m
# CONFIG_NET_VENDOR_SMSC is not set
# CONFIG_NET_VENDOR_STMICRO is not set
# CONFIG_NET_VENDOR_WIZNET is not set
CONFIG_PLIP=m
CONFIG_PPP=m
CONFIG_PPP_BSDCOMP=m
CONFIG_PPP_DEFLATE=m
@ -292,9 +296,11 @@ CONFIG_SERIO_Q40KBD=y
CONFIG_VT_HW_CONSOLE_BINDING=y
# CONFIG_LEGACY_PTYS is not set
# CONFIG_DEVKMEM is not set
CONFIG_PRINTER=m
# CONFIG_HW_RANDOM is not set
CONFIG_NTP_PPS=y
CONFIG_PPS_CLIENT_LDISC=m
CONFIG_PPS_CLIENT_PARPORT=m
CONFIG_PTP_1588_CLOCK=m
# CONFIG_HWMON is not set
CONFIG_FB=y

View File

@ -11,6 +11,8 @@
#ifndef _ASM_M68K_PARPORT_H
#define _ASM_M68K_PARPORT_H 1
#undef insl
#undef outsl
#define insl(port,buf,len) isa_insb(port,buf,(len)<<2)
#define outsl(port,buf,len) isa_outsb(port,buf,(len)<<2)

View File

@ -4,20 +4,6 @@
#include <linux/types.h>
#include <linux/compiler.h>
static inline char *__kernel_strcpy(char *dest, const char *src)
{
char *xdest = dest;
asm volatile ("\n"
"1: move.b (%1)+,(%0)+\n"
" jne 1b"
: "+a" (dest), "+a" (src)
: : "memory");
return xdest;
}
#ifndef __IN_STRING_C
#define __HAVE_ARCH_STRNLEN
static inline size_t strnlen(const char *s, size_t count)
{
@ -34,16 +20,6 @@ static inline size_t strnlen(const char *s, size_t count)
return sc - s;
}
#define __HAVE_ARCH_STRCPY
#if __GNUC__ >= 4
#define strcpy(d, s) (__builtin_constant_p(s) && \
__builtin_strlen(s) <= 32 ? \
__builtin_strcpy(d, s) : \
__kernel_strcpy(d, s))
#else
#define strcpy(d, s) __kernel_strcpy(d, s)
#endif
#define __HAVE_ARCH_STRNCPY
static inline char *strncpy(char *dest, const char *src, size_t n)
{
@ -61,12 +37,6 @@ static inline char *strncpy(char *dest, const char *src, size_t n)
return xdest;
}
#define __HAVE_ARCH_STRCAT
#define strcat(d, s) ({ \
char *__d = (d); \
strcpy(__d + strlen(__d), (s)); \
})
#ifndef CONFIG_COLDFIRE
#define __HAVE_ARCH_STRCMP
static inline int strcmp(const char *cs, const char *ct)
@ -100,6 +70,4 @@ extern void *memset(void *, int, __kernel_size_t);
extern void *memcpy(void *, const void *, __kernel_size_t);
#define memcpy(d, s, n) __builtin_memcpy(d, s, n)
#endif
#endif /* _M68K_STRING_H_ */

View File

@ -90,7 +90,7 @@ asm volatile ("\n" \
__put_user_asm(__pu_err, __pu_val, ptr, b, d, -EFAULT); \
break; \
case 2: \
__put_user_asm(__pu_err, __pu_val, ptr, w, d, -EFAULT); \
__put_user_asm(__pu_err, __pu_val, ptr, w, r, -EFAULT); \
break; \
case 4: \
__put_user_asm(__pu_err, __pu_val, ptr, l, r, -EFAULT); \
@ -158,7 +158,7 @@ asm volatile ("\n" \
__get_user_asm(__gu_err, x, ptr, u8, b, d, -EFAULT); \
break; \
case 2: \
__get_user_asm(__gu_err, x, ptr, u16, w, d, -EFAULT); \
__get_user_asm(__gu_err, x, ptr, u16, w, r, -EFAULT); \
break; \
case 4: \
__get_user_asm(__gu_err, x, ptr, u32, l, r, -EFAULT); \
@ -245,7 +245,7 @@ __constant_copy_from_user(void *to, const void __user *from, unsigned long n)
__get_user_asm(res, *(u8 *)to, (u8 __user *)from, u8, b, d, 1);
break;
case 2:
__get_user_asm(res, *(u16 *)to, (u16 __user *)from, u16, w, d, 2);
__get_user_asm(res, *(u16 *)to, (u16 __user *)from, u16, w, r, 2);
break;
case 3:
__constant_copy_from_user_asm(res, to, from, tmp, 3, w, b,);
@ -326,7 +326,7 @@ __constant_copy_to_user(void __user *to, const void *from, unsigned long n)
__put_user_asm(res, *(u8 *)from, (u8 __user *)to, b, d, 1);
break;
case 2:
__put_user_asm(res, *(u16 *)from, (u16 __user *)to, w, d, 2);
__put_user_asm(res, *(u16 *)from, (u16 __user *)to, w, r, 2);
break;
case 3:
__constant_copy_to_user_asm(res, to, from, tmp, 3, w, b,);

View File

@ -101,7 +101,7 @@ void __init m68k_setup_user_interrupt(unsigned int vec, unsigned int cnt)
BUG_ON(IRQ_USER + cnt > NR_IRQS);
m68k_first_user_vec = vec;
for (i = 0; i < cnt; i++)
irq_set_chip(IRQ_USER + i, &user_irq_chip);
irq_set_chip_and_handler(i, &user_irq_chip, handle_simple_irq);
*user_irqvec_fixup = vec - IRQ_USER;
flush_icache();
}

View File

@ -6,7 +6,7 @@
lib-y := ashldi3.o ashrdi3.o lshrdi3.o muldi3.o \
memcpy.o memset.o memmove.o
lib-$(CONFIG_MMU) += string.o uaccess.o
lib-$(CONFIG_MMU) += uaccess.o
lib-$(CONFIG_CPU_HAS_NO_MULDIV64) += mulsi3.o divsi3.o udivsi3.o
lib-$(CONFIG_CPU_HAS_NO_MULDIV64) += modsi3.o umodsi3.o

View File

@ -1,22 +0,0 @@
/*
* This file is subject to the terms and conditions of the GNU General Public
* License. See the file COPYING in the main directory of this archive
* for more details.
*/
#define __IN_STRING_C
#include <linux/module.h>
#include <linux/string.h>
char *strcpy(char *dest, const char *src)
{
return __kernel_strcpy(dest, src);
}
EXPORT_SYMBOL(strcpy);
char *strcat(char *dest, const char *src)
{
return __kernel_strcpy(dest + strlen(dest), src);
}
EXPORT_SYMBOL(strcat);

View File

@ -52,7 +52,7 @@ unsigned long __generic_copy_from_user(void *to, const void __user *from,
" .long 3b,30b\n"
" .long 5b,50b\n"
" .previous"
: "=d" (res), "+a" (from), "+a" (to), "=&r" (tmp)
: "=d" (res), "+a" (from), "+a" (to), "=&d" (tmp)
: "0" (n / 4), "d" (n & 3));
return res;
@ -96,7 +96,7 @@ unsigned long __generic_copy_to_user(void __user *to, const void *from,
" .long 7b,50b\n"
" .long 8b,50b\n"
" .previous"
: "=d" (res), "+a" (from), "+a" (to), "=&r" (tmp)
: "=d" (res), "+a" (from), "+a" (to), "=&d" (tmp)
: "0" (n / 4), "d" (n & 3));
return res;
@ -141,7 +141,7 @@ unsigned long __clear_user(void __user *to, unsigned long n)
" .long 7b,40b\n"
" .previous"
: "=d" (res), "+a" (to)
: "r" (0), "0" (n / 4), "d" (n & 3));
: "d" (0), "0" (n / 4), "d" (n & 3));
return res;
}

View File

@ -519,7 +519,7 @@ static void fp_roundint(struct fp_ext *dest, int mode)
return;
break;
case 0x401e:
if (!(oldmant.m32[1] >= 0))
if (oldmant.m32[1] & 0x80000000)
return;
if (oldmant.m32[0] & 1)
break;

View File

@ -275,7 +275,7 @@ void dvma_init(void)
}
inline unsigned long dvma_map_align(unsigned long kaddr, int len, int align)
unsigned long dvma_map_align(unsigned long kaddr, int len, int align)
{
unsigned long baddr;

View File

@ -893,7 +893,7 @@ static int swim_probe(struct platform_device *dev)
swim_base = ioremap(res->start, resource_size(res));
if (!swim_base) {
return -ENOMEM;
ret = -ENOMEM;
goto out_release_io;
}

View File

@ -280,18 +280,7 @@ static struct platform_driver amiga_a3000_scsi_driver = {
},
};
static int __init amiga_a3000_scsi_init(void)
{
return platform_driver_probe(&amiga_a3000_scsi_driver,
amiga_a3000_scsi_probe);
}
module_init(amiga_a3000_scsi_init);
static void __exit amiga_a3000_scsi_exit(void)
{
platform_driver_unregister(&amiga_a3000_scsi_driver);
}
module_exit(amiga_a3000_scsi_exit);
module_platform_driver_probe(amiga_a3000_scsi_driver, amiga_a3000_scsi_probe);
MODULE_DESCRIPTION("Amiga 3000 built-in SCSI");
MODULE_LICENSE("GPL");

View File

@ -116,20 +116,7 @@ static struct platform_driver amiga_a4000t_scsi_driver = {
},
};
static int __init amiga_a4000t_scsi_init(void)
{
return platform_driver_probe(&amiga_a4000t_scsi_driver,
amiga_a4000t_scsi_probe);
}
module_init(amiga_a4000t_scsi_init);
static void __exit amiga_a4000t_scsi_exit(void)
{
platform_driver_unregister(&amiga_a4000t_scsi_driver);
}
module_exit(amiga_a4000t_scsi_exit);
module_platform_driver_probe(amiga_a4000t_scsi_driver, amiga_a4000t_scsi_probe);
MODULE_AUTHOR("Alan Hourihane <alanh@fairlite.demon.co.uk> / "
"Kars de Jong <jongk@linux-m68k.org>");