Skip to content

Commit

Permalink
Merge branch 'for-linus' of git://git390.marist.edu/pub/scm/linux-2.6
Browse files Browse the repository at this point in the history
* 'for-linus' of git://git390.marist.edu/pub/scm/linux-2.6:
  [S390] Use strim instead of strstrip to avoid false warnings.
  [S390] qdio: add counter for input queue full condition
  [S390] qdio: remove superfluous log entries and WARN_ONs.
  [S390] ptrace: dont abuse PT_PTRACED
  [S390] cio: fix channel path vary
  [S390] drivers: Correct size given to memset
  [S390] tape: Add pr_fmt() macro to all tape source files
  [S390] rename NT_PRXSTATUS to NT_S390_HIGHREGS
  [S390] tty: PTR_ERR return of wrong pointer in fs3270_open()
  [S390] s390: PTR_ERR return of wrong pointer in fallback_init_cip()
  [S390] dasd: PTR_ERR return of wrong pointer in
  [S390] dasd: move dasd-diag kmsg to dasd
  [S390] cio: fix drvdata usage for the console subchannel
  [S390] wire up sys_recvmmsg
  • Loading branch information
Linus Torvalds committed Dec 19, 2009
2 parents b4c30aa + 1d802e2 commit ecd5907
Show file tree
Hide file tree
Showing 30 changed files with 95 additions and 62 deletions.
2 changes: 1 addition & 1 deletion arch/s390/crypto/aes_s390.c
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ static int fallback_init_cip(struct crypto_tfm *tfm)
if (IS_ERR(sctx->fallback.cip)) {
pr_err("Allocating AES fallback algorithm %s failed\n",
name);
return PTR_ERR(sctx->fallback.blk);
return PTR_ERR(sctx->fallback.cip);
}

return 0;
Expand Down
4 changes: 2 additions & 2 deletions arch/s390/hypfs/hypfs_diag.c
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ static inline void part_hdr__part_name(enum diag204_format type, void *hdr,
LPAR_NAME_LEN);
EBCASC(name, LPAR_NAME_LEN);
name[LPAR_NAME_LEN] = 0;
strstrip(name);
strim(name);
}

struct cpu_info {
Expand Down Expand Up @@ -523,7 +523,7 @@ static int diag224_idx2name(int index, char *name)
memcpy(name, diag224_cpu_names + ((index + 1) * CPU_NAME_LEN),
CPU_NAME_LEN);
name[CPU_NAME_LEN] = 0;
strstrip(name);
strim(name);
return 0;
}

Expand Down
2 changes: 1 addition & 1 deletion arch/s390/hypfs/hypfs_vm.c
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ static int hpyfs_vm_create_guest(struct super_block *sb,
/* guest dir */
memcpy(guest_name, data->guest_name, NAME_LEN);
EBCASC(guest_name, NAME_LEN);
strstrip(guest_name);
strim(guest_name);
guest_dir = hypfs_mkdir(sb, systems_dir, guest_name);
if (IS_ERR(guest_dir))
return PTR_ERR(guest_dir);
Expand Down
3 changes: 2 additions & 1 deletion arch/s390/include/asm/unistd.h
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,8 @@
#define __NR_pwritev 329
#define __NR_rt_tgsigqueueinfo 330
#define __NR_perf_event_open 331
#define NR_syscalls 332
#define __NR_recvmmsg 332
#define NR_syscalls 333

/*
* There are some system calls that are not present on 64 bit, some
Expand Down
9 changes: 9 additions & 0 deletions arch/s390/kernel/compat_wrapper.S
Original file line number Diff line number Diff line change
Expand Up @@ -1853,3 +1853,12 @@ sys32_execve_wrapper:
llgtr %r3,%r3 # compat_uptr_t *
llgtr %r4,%r4 # compat_uptr_t *
jg sys32_execve # branch to system call

.globl compat_sys_recvmmsg_wrapper
compat_sys_recvmmsg_wrapper:
lgfr %r2,%r2 # int
llgtr %r3,%r3 # struct compat_mmsghdr *
llgfr %r4,%r4 # unsigned int
llgfr %r5,%r5 # unsigned int
llgtr %r6,%r6 # struct compat_timespec *
jg compat_sys_recvmmsg
6 changes: 3 additions & 3 deletions arch/s390/kernel/ipl.c
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ static ssize_t sys_##_prefix##_##_name##_store(struct kobject *kobj, \
const char *buf, size_t len) \
{ \
strncpy(_value, buf, sizeof(_value) - 1); \
strstrip(_value); \
strim(_value); \
return len; \
} \
static struct kobj_attribute sys_##_prefix##_##_name##_attr = \
Expand Down Expand Up @@ -472,7 +472,7 @@ static ssize_t ipl_ccw_loadparm_show(struct kobject *kobj,
return sprintf(page, "#unknown#\n");
memcpy(loadparm, &sclp_ipl_info.loadparm, LOADPARM_LEN);
EBCASC(loadparm, LOADPARM_LEN);
strstrip(loadparm);
strim(loadparm);
return sprintf(page, "%s\n", loadparm);
}

Expand Down Expand Up @@ -776,7 +776,7 @@ static void reipl_get_ascii_loadparm(char *loadparm,
memcpy(loadparm, ibp->ipl_info.ccw.load_parm, LOADPARM_LEN);
EBCASC(loadparm, LOADPARM_LEN);
loadparm[LOADPARM_LEN] = 0;
strstrip(loadparm);
strim(loadparm);
}

static ssize_t reipl_generic_loadparm_show(struct ipl_parameter_block *ipb,
Expand Down
2 changes: 1 addition & 1 deletion arch/s390/kernel/ptrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -959,7 +959,7 @@ static const struct user_regset s390_compat_regsets[] = {
.set = s390_fpregs_set,
},
[REGSET_GENERAL_EXTENDED] = {
.core_note_type = NT_PRXSTATUS,
.core_note_type = NT_S390_HIGH_GPRS,
.n = sizeof(s390_compat_regs_high) / sizeof(compat_long_t),
.size = sizeof(compat_long_t),
.align = sizeof(compat_long_t),
Expand Down
1 change: 1 addition & 0 deletions arch/s390/kernel/syscalls.S
Original file line number Diff line number Diff line change
Expand Up @@ -340,3 +340,4 @@ SYSCALL(sys_preadv,sys_preadv,compat_sys_preadv_wrapper)
SYSCALL(sys_pwritev,sys_pwritev,compat_sys_pwritev_wrapper)
SYSCALL(sys_rt_tgsigqueueinfo,sys_rt_tgsigqueueinfo,compat_sys_rt_tgsigqueueinfo_wrapper) /* 330 */
SYSCALL(sys_perf_event_open,sys_perf_event_open,sys_perf_event_open_wrapper)
SYSCALL(sys_recvmmsg,sys_recvmmsg,compat_sys_recvmmsg_wrapper)
6 changes: 3 additions & 3 deletions arch/s390/kernel/traps.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#include <linux/kernel.h>
#include <linux/string.h>
#include <linux/errno.h>
#include <linux/ptrace.h>
#include <linux/tracehook.h>
#include <linux/timer.h>
#include <linux/mm.h>
#include <linux/smp.h>
Expand Down Expand Up @@ -382,7 +382,7 @@ void __kprobes do_single_step(struct pt_regs *regs)
SIGTRAP) == NOTIFY_STOP){
return;
}
if ((current->ptrace & PT_PTRACED) != 0)
if (tracehook_consider_fatal_signal(current, SIGTRAP))
force_sig(SIGTRAP, current);
}

Expand Down Expand Up @@ -483,7 +483,7 @@ static void illegal_op(struct pt_regs * regs, long interruption_code)
if (get_user(*((__u16 *) opcode), (__u16 __user *) location))
return;
if (*((__u16 *) opcode) == S390_BREAKPOINT_U16) {
if (current->ptrace & PT_PTRACED)
if (tracehook_consider_fatal_signal(current, SIGTRAP))
force_sig(SIGTRAP, current);
else
signal = SIGILL;
Expand Down
2 changes: 1 addition & 1 deletion drivers/s390/block/dasd_alias.c
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ int dasd_alias_make_device_known_to_lcu(struct dasd_device *device)
spin_unlock_irqrestore(&aliastree.lock, flags);
newlcu = _allocate_lcu(uid);
if (IS_ERR(newlcu))
return PTR_ERR(lcu);
return PTR_ERR(newlcu);
spin_lock_irqsave(&aliastree.lock, flags);
lcu = _find_lcu(server, uid);
if (!lcu) {
Expand Down
42 changes: 22 additions & 20 deletions drivers/s390/block/dasd_diag.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
*
*/

#define KMSG_COMPONENT "dasd-diag"
#define KMSG_COMPONENT "dasd"

#include <linux/stddef.h>
#include <linux/kernel.h>
Expand Down Expand Up @@ -146,16 +146,16 @@ dasd_diag_erp(struct dasd_device *device)
rc = mdsk_init_io(device, device->block->bp_block, 0, NULL);
if (rc == 4) {
if (!(device->features & DASD_FEATURE_READONLY)) {
dev_warn(&device->cdev->dev,
"The access mode of a DIAG device changed"
" to read-only");
pr_warning("%s: The access mode of a DIAG device "
"changed to read-only\n",
dev_name(&device->cdev->dev));
device->features |= DASD_FEATURE_READONLY;
}
rc = 0;
}
if (rc)
dev_warn(&device->cdev->dev, "DIAG ERP failed with "
"rc=%d\n", rc);
pr_warning("%s: DIAG ERP failed with "
"rc=%d\n", dev_name(&device->cdev->dev), rc);
}

/* Start a given request at the device. Return zero on success, non-zero
Expand Down Expand Up @@ -371,8 +371,9 @@ dasd_diag_check_device(struct dasd_device *device)
private->pt_block = 2;
break;
default:
dev_warn(&device->cdev->dev, "Device type %d is not supported "
"in DIAG mode\n", private->rdc_data.vdev_class);
pr_warning("%s: Device type %d is not supported "
"in DIAG mode\n", dev_name(&device->cdev->dev),
private->rdc_data.vdev_class);
rc = -EOPNOTSUPP;
goto out;
}
Expand Down Expand Up @@ -413,8 +414,8 @@ dasd_diag_check_device(struct dasd_device *device)
private->iob.flaga = DASD_DIAG_FLAGA_DEFAULT;
rc = dia250(&private->iob, RW_BIO);
if (rc == 3) {
dev_warn(&device->cdev->dev,
"A 64-bit DIAG call failed\n");
pr_warning("%s: A 64-bit DIAG call failed\n",
dev_name(&device->cdev->dev));
rc = -EOPNOTSUPP;
goto out_label;
}
Expand All @@ -423,8 +424,9 @@ dasd_diag_check_device(struct dasd_device *device)
break;
}
if (bsize > PAGE_SIZE) {
dev_warn(&device->cdev->dev, "Accessing the DASD failed because"
" of an incorrect format (rc=%d)\n", rc);
pr_warning("%s: Accessing the DASD failed because of an "
"incorrect format (rc=%d)\n",
dev_name(&device->cdev->dev), rc);
rc = -EIO;
goto out_label;
}
Expand All @@ -442,18 +444,18 @@ dasd_diag_check_device(struct dasd_device *device)
block->s2b_shift++;
rc = mdsk_init_io(device, block->bp_block, 0, NULL);
if (rc && (rc != 4)) {
dev_warn(&device->cdev->dev, "DIAG initialization "
"failed with rc=%d\n", rc);
pr_warning("%s: DIAG initialization failed with rc=%d\n",
dev_name(&device->cdev->dev), rc);
rc = -EIO;
} else {
if (rc == 4)
device->features |= DASD_FEATURE_READONLY;
dev_info(&device->cdev->dev,
"New DASD with %ld byte/block, total size %ld KB%s\n",
(unsigned long) block->bp_block,
(unsigned long) (block->blocks <<
block->s2b_shift) >> 1,
(rc == 4) ? ", read-only device" : "");
pr_info("%s: New DASD with %ld byte/block, total size %ld "
"KB%s\n", dev_name(&device->cdev->dev),
(unsigned long) block->bp_block,
(unsigned long) (block->blocks <<
block->s2b_shift) >> 1,
(rc == 4) ? ", read-only device" : "");
rc = 0;
}
out_label:
Expand Down
2 changes: 1 addition & 1 deletion drivers/s390/char/fs3270.c
Original file line number Diff line number Diff line change
Expand Up @@ -467,7 +467,7 @@ fs3270_open(struct inode *inode, struct file *filp)
if (IS_ERR(ib)) {
raw3270_put_view(&fp->view);
raw3270_del_view(&fp->view);
rc = PTR_ERR(fp);
rc = PTR_ERR(ib);
goto out;
}
fp->rdbuf = ib;
Expand Down
1 change: 1 addition & 0 deletions drivers/s390/char/tape_34xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
*/

#define KMSG_COMPONENT "tape_34xx"
#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt

#include <linux/module.h>
#include <linux/init.h>
Expand Down
3 changes: 2 additions & 1 deletion drivers/s390/char/tape_3590.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
*/

#define KMSG_COMPONENT "tape_3590"
#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt

#include <linux/module.h>
#include <linux/init.h>
Expand Down Expand Up @@ -136,7 +137,7 @@ static void int_to_ext_kekl(struct tape3592_kekl *in,
out->type_on_tape = TAPE390_KEKL_TYPE_LABEL;
memcpy(out->label, in->label, sizeof(in->label));
EBCASC(out->label, sizeof(in->label));
strstrip(out->label);
strim(out->label);
}

static void int_to_ext_kekl_pair(struct tape3592_kekl_pair *in,
Expand Down
1 change: 1 addition & 0 deletions drivers/s390/char/tape_block.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
*/

#define KMSG_COMPONENT "tape"
#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt

#include <linux/fs.h>
#include <linux/module.h>
Expand Down
3 changes: 3 additions & 0 deletions drivers/s390/char/tape_char.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@
* Martin Schwidefsky <schwidefsky@de.ibm.com>
*/

#define KMSG_COMPONENT "tape"
#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt

#include <linux/module.h>
#include <linux/types.h>
#include <linux/proc_fs.h>
Expand Down
4 changes: 4 additions & 0 deletions drivers/s390/char/tape_class.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@
* Author: Stefan Bader <shbader@de.ibm.com>
* Based on simple class device code by Greg K-H
*/

#define KMSG_COMPONENT "tape"
#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt

#include "tape_class.h"

MODULE_AUTHOR("Stefan Bader <shbader@de.ibm.com>");
Expand Down
2 changes: 2 additions & 0 deletions drivers/s390/char/tape_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
*/

#define KMSG_COMPONENT "tape"
#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt

#include <linux/module.h>
#include <linux/init.h> // for kernel parameters
#include <linux/kmod.h> // for requesting modules
Expand Down
3 changes: 3 additions & 0 deletions drivers/s390/char/tape_proc.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
* PROCFS Functions
*/

#define KMSG_COMPONENT "tape"
#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt

#include <linux/module.h>
#include <linux/vmalloc.h>
#include <linux/seq_file.h>
Expand Down
3 changes: 3 additions & 0 deletions drivers/s390/char/tape_std.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
* Stefan Bader <shbader@de.ibm.com>
*/

#define KMSG_COMPONENT "tape"
#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt

#include <linux/stddef.h>
#include <linux/kernel.h>
#include <linux/bio.h>
Expand Down
3 changes: 0 additions & 3 deletions drivers/s390/cio/ccwreq.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,13 @@ static u16 ccwreq_next_path(struct ccw_device *cdev)
*/
static void ccwreq_stop(struct ccw_device *cdev, int rc)
{
struct subchannel *sch = to_subchannel(cdev->dev.parent);
struct ccw_request *req = &cdev->private->req;

if (req->done)
return;
req->done = 1;
ccw_device_set_timeout(cdev, 0);
memset(&cdev->private->irb, 0, sizeof(struct irb));
sch->lpm = sch->schib.pmcw.pam;
if (rc && rc != -ENODEV && req->drc)
rc = req->drc;
req->callback(cdev, req->data, rc);
Expand All @@ -80,7 +78,6 @@ static void ccwreq_do(struct ccw_device *cdev)
continue;
}
/* Perform start function. */
sch->lpm = 0xff;
memset(&cdev->private->irb, 0, sizeof(struct irb));
rc = cio_start(sch, cp, (u8) req->mask);
if (rc == 0) {
Expand Down
1 change: 1 addition & 0 deletions drivers/s390/cio/device.c
Original file line number Diff line number Diff line change
Expand Up @@ -1519,6 +1519,7 @@ static int ccw_device_console_enable(struct ccw_device *cdev,
sch->driver = &io_subchannel_driver;
/* Initialize the ccw_device structure. */
cdev->dev.parent= &sch->dev;
sch_set_cdev(sch, cdev);
io_subchannel_recog(cdev, sch);
/* Now wait for the async. recognition to come to an end. */
spin_lock_irq(cdev->ccwlock);
Expand Down
Loading

0 comments on commit ecd5907

Please sign in to comment.