Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 102308
b: refs/heads/master
c: 98abed0
h: refs/heads/master
v: v3
  • Loading branch information
Roland McGrath committed Jul 17, 2008
1 parent 15bac6e commit aa3172a
Show file tree
Hide file tree
Showing 36 changed files with 5,109 additions and 4,123 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7259d936c6af216198ae6af3a25ac6c9dbdbe779
refs/heads/master: 98abed02007b19bbfd68b6d06a5485afc3eeb01b
1 change: 1 addition & 0 deletions trunk/Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
FRED=42
VERSION = 2
PATCHLEVEL = 6
SUBLEVEL = 26
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/s390/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ config WARN_STACK_SIZE
int "Maximum frame size considered safe (128-2048)"
range 128 2048
depends on WARN_STACK
default "2048"
default "256"
help
This allows you to specify the maximum frame size a function may
have without the compiler complaining about it.
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/s390/kernel/stacktrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
#include <linux/sched.h>
#include <linux/stacktrace.h>
#include <linux/kallsyms.h>
#include <linux/module.h>

static unsigned long save_context_stack(struct stack_trace *trace,
unsigned long sp,
Expand Down
25 changes: 7 additions & 18 deletions trunk/drivers/s390/block/dasd_diag.c
Original file line number Diff line number Diff line change
Expand Up @@ -333,8 +333,7 @@ dasd_diag_check_device(struct dasd_device *device)
if (IS_ERR(block)) {
DEV_MESSAGE(KERN_WARNING, device, "%s",
"could not allocate dasd block structure");
device->private = NULL;
kfree(private);
kfree(device->private);
return PTR_ERR(block);
}
device->block = block;
Expand All @@ -349,8 +348,7 @@ dasd_diag_check_device(struct dasd_device *device)
if (rc) {
DEV_MESSAGE(KERN_WARNING, device, "failed to retrieve device "
"information (rc=%d)", rc);
rc = -EOPNOTSUPP;
goto out;
return -ENOTSUPP;
}

/* Figure out position of label block */
Expand All @@ -364,8 +362,7 @@ dasd_diag_check_device(struct dasd_device *device)
default:
DEV_MESSAGE(KERN_WARNING, device, "unsupported device class "
"(class=%d)", private->rdc_data.vdev_class);
rc = -EOPNOTSUPP;
goto out;
return -ENOTSUPP;
}

DBF_DEV_EVENT(DBF_INFO, device,
Expand All @@ -382,8 +379,7 @@ dasd_diag_check_device(struct dasd_device *device)
if (label == NULL) {
DEV_MESSAGE(KERN_WARNING, device, "%s",
"No memory to allocate initialization request");
rc = -ENOMEM;
goto out;
return -ENOMEM;
}
rc = 0;
end_block = 0;
Expand All @@ -407,7 +403,7 @@ dasd_diag_check_device(struct dasd_device *device)
DEV_MESSAGE(KERN_WARNING, device, "%s",
"DIAG call failed");
rc = -EOPNOTSUPP;
goto out_label;
goto out;
}
mdsk_term_io(device);
if (rc == 0)
Expand All @@ -417,7 +413,7 @@ dasd_diag_check_device(struct dasd_device *device)
DEV_MESSAGE(KERN_WARNING, device, "device access failed "
"(rc=%d)", rc);
rc = -EIO;
goto out_label;
goto out;
}
/* check for label block */
if (memcmp(label->label_id, DASD_DIAG_CMS1,
Expand All @@ -443,15 +439,8 @@ dasd_diag_check_device(struct dasd_device *device)
(unsigned long) (block->blocks <<
block->s2b_shift) >> 1);
}
out_label:
free_page((long) label);
out:
if (rc) {
device->block = NULL;
dasd_free_block(block);
device->private = NULL;
kfree(private);
}
free_page((long) label);
return rc;
}

Expand Down
4 changes: 1 addition & 3 deletions trunk/drivers/s390/block/dasd_eckd.c
Original file line number Diff line number Diff line change
Expand Up @@ -1418,10 +1418,8 @@ static void dasd_eckd_handle_unsolicited_interrupt(struct dasd_device *device,


/* service information message SIM */
if (irb->esw.esw0.erw.cons && (irb->ecw[27] & DASD_SENSE_BIT_0) &&
((irb->ecw[6] & DASD_SIM_SENSE) == DASD_SIM_SENSE)) {
if ((irb->ecw[6] & DASD_SIM_SENSE) == DASD_SIM_SENSE) {
dasd_3990_erp_handle_sim(device, irb->ecw);
dasd_schedule_device_bh(device);
return;
}

Expand Down
7 changes: 1 addition & 6 deletions trunk/drivers/s390/block/dasd_fba.c
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,7 @@ dasd_fba_check_characteristics(struct dasd_device *device)
if (IS_ERR(block)) {
DEV_MESSAGE(KERN_WARNING, device, "%s",
"could not allocate dasd block structure");
device->private = NULL;
kfree(private);
kfree(device->private);
return PTR_ERR(block);
}
device->block = block;
Expand All @@ -153,10 +152,6 @@ dasd_fba_check_characteristics(struct dasd_device *device)
DEV_MESSAGE(KERN_WARNING, device,
"Read device characteristics returned error %d",
rc);
device->block = NULL;
dasd_free_block(block);
device->private = NULL;
kfree(private);
return rc;
}

Expand Down
10 changes: 5 additions & 5 deletions trunk/drivers/s390/char/vmur.c
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ static int get_urd_class(struct urdev *urd)
cc = diag210(&ur_diag210);
switch (cc) {
case 0:
return -EOPNOTSUPP;
return -ENOTSUPP;
case 2:
return ur_diag210.vrdcvcla; /* virtual device class */
case 3:
Expand Down Expand Up @@ -621,7 +621,7 @@ static int verify_device(struct urdev *urd)
case DEV_CLASS_UR_I:
return verify_uri_device(urd);
default:
return -EOPNOTSUPP;
return -ENOTSUPP;
}
}

Expand Down Expand Up @@ -654,7 +654,7 @@ static int get_file_reclen(struct urdev *urd)
case DEV_CLASS_UR_I:
return get_uri_file_reclen(urd);
default:
return -EOPNOTSUPP;
return -ENOTSUPP;
}
}

Expand Down Expand Up @@ -827,7 +827,7 @@ static int ur_probe(struct ccw_device *cdev)
goto fail_remove_attr;
}
if ((urd->class != DEV_CLASS_UR_I) && (urd->class != DEV_CLASS_UR_O)) {
rc = -EOPNOTSUPP;
rc = -ENOTSUPP;
goto fail_remove_attr;
}
spin_lock_irq(get_ccwdev_lock(cdev));
Expand Down Expand Up @@ -892,7 +892,7 @@ static int ur_set_online(struct ccw_device *cdev)
} else if (urd->cdev->id.cu_type == PRINTER_DEVTYPE) {
sprintf(node_id, "vmprt-%s", cdev->dev.bus_id);
} else {
rc = -EOPNOTSUPP;
rc = -ENOTSUPP;
goto fail_free_cdev;
}

Expand Down
101 changes: 7 additions & 94 deletions trunk/drivers/s390/char/zcore.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@

#define TO_USER 0
#define TO_KERNEL 1
#define CHUNK_INFO_SIZE 34 /* 2 16-byte char, each followed by blank */

enum arch_id {
ARCH_S390 = 0,
Expand All @@ -52,7 +51,6 @@ static struct debug_info *zcore_dbf;
static int hsa_available;
static struct dentry *zcore_dir;
static struct dentry *zcore_file;
static struct dentry *zcore_memmap_file;

/*
* Copy memory from HSA to kernel or user memory (not reentrant):
Expand Down Expand Up @@ -478,54 +476,6 @@ static const struct file_operations zcore_fops = {
.release = zcore_release,
};

static ssize_t zcore_memmap_read(struct file *filp, char __user *buf,
size_t count, loff_t *ppos)
{
return simple_read_from_buffer(buf, count, ppos, filp->private_data,
MEMORY_CHUNKS * CHUNK_INFO_SIZE);
}

static int zcore_memmap_open(struct inode *inode, struct file *filp)
{
int i;
char *buf;
struct mem_chunk *chunk_array;

chunk_array = kzalloc(MEMORY_CHUNKS * sizeof(struct mem_chunk),
GFP_KERNEL);
if (!chunk_array)
return -ENOMEM;
detect_memory_layout(chunk_array);
buf = kzalloc(MEMORY_CHUNKS * CHUNK_INFO_SIZE, GFP_KERNEL);
if (!buf) {
kfree(chunk_array);
return -ENOMEM;
}
for (i = 0; i < MEMORY_CHUNKS; i++) {
sprintf(buf + (i * CHUNK_INFO_SIZE), "%016llx %016llx ",
(unsigned long long) chunk_array[i].addr,
(unsigned long long) chunk_array[i].size);
if (chunk_array[i].size == 0)
break;
}
kfree(chunk_array);
filp->private_data = buf;
return 0;
}

static int zcore_memmap_release(struct inode *inode, struct file *filp)
{
kfree(filp->private_data);
return 0;
}

static const struct file_operations zcore_memmap_fops = {
.owner = THIS_MODULE,
.read = zcore_memmap_read,
.open = zcore_memmap_open,
.release = zcore_memmap_release,
};


static void __init set_s390_lc_mask(union save_area *map)
{
Expand Down Expand Up @@ -604,44 +554,18 @@ static int __init check_sdias(void)
return 0;
}

static int __init get_mem_size(unsigned long *mem)
{
int i;
struct mem_chunk *chunk_array;

chunk_array = kzalloc(MEMORY_CHUNKS * sizeof(struct mem_chunk),
GFP_KERNEL);
if (!chunk_array)
return -ENOMEM;
detect_memory_layout(chunk_array);
for (i = 0; i < MEMORY_CHUNKS; i++) {
if (chunk_array[i].size == 0)
break;
*mem += chunk_array[i].size;
}
kfree(chunk_array);
return 0;
}

static int __init zcore_header_init(int arch, struct zcore_header *hdr)
static void __init zcore_header_init(int arch, struct zcore_header *hdr)
{
int rc;
unsigned long memory = 0;

if (arch == ARCH_S390X)
hdr->arch_id = DUMP_ARCH_S390X;
else
hdr->arch_id = DUMP_ARCH_S390;
rc = get_mem_size(&memory);
if (rc)
return rc;
hdr->mem_size = memory;
hdr->rmem_size = memory;
hdr->mem_size = sys_info.mem_size;
hdr->rmem_size = sys_info.mem_size;
hdr->mem_end = sys_info.mem_size;
hdr->num_pages = memory / PAGE_SIZE;
hdr->num_pages = sys_info.mem_size / PAGE_SIZE;
hdr->tod = get_clock();
get_cpu_id(&hdr->cpu_id);
return 0;
}

static int __init zcore_init(void)
Expand Down Expand Up @@ -684,9 +608,7 @@ static int __init zcore_init(void)
if (rc)
goto fail;

rc = zcore_header_init(arch, &zcore_header);
if (rc)
goto fail;
zcore_header_init(arch, &zcore_header);

zcore_dir = debugfs_create_dir("zcore" , NULL);
if (!zcore_dir) {
Expand All @@ -696,22 +618,13 @@ static int __init zcore_init(void)
zcore_file = debugfs_create_file("mem", S_IRUSR, zcore_dir, NULL,
&zcore_fops);
if (!zcore_file) {
debugfs_remove(zcore_dir);
rc = -ENOMEM;
goto fail_dir;
}
zcore_memmap_file = debugfs_create_file("memmap", S_IRUSR, zcore_dir,
NULL, &zcore_memmap_fops);
if (!zcore_memmap_file) {
rc = -ENOMEM;
goto fail_file;
goto fail;
}
hsa_available = 1;
return 0;

fail_file:
debugfs_remove(zcore_file);
fail_dir:
debugfs_remove(zcore_dir);
fail:
diag308(DIAG308_REL_HSA, NULL);
return rc;
Expand Down
2 changes: 0 additions & 2 deletions trunk/drivers/s390/cio/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,4 @@ ccw_device-objs += device_id.o device_pgid.o device_status.o
obj-y += ccw_device.o cmf.o
obj-$(CONFIG_CHSC_SCH) += chsc_sch.o
obj-$(CONFIG_CCWGROUP) += ccwgroup.o

qdio-objs := qdio_main.o qdio_thinint.o qdio_debug.o qdio_perf.o qdio_setup.o
obj-$(CONFIG_QDIO) += qdio.o
9 changes: 1 addition & 8 deletions trunk/drivers/s390/cio/chsc.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,7 @@

static void *sei_page;

/**
* chsc_error_from_response() - convert a chsc response to an error
* @response: chsc response code
*
* Returns an appropriate Linux error code for @response.
*/
int chsc_error_from_response(int response)
static int chsc_error_from_response(int response)
{
switch (response) {
case 0x0001:
Expand All @@ -51,7 +45,6 @@ int chsc_error_from_response(int response)
return -EIO;
}
}
EXPORT_SYMBOL_GPL(chsc_error_from_response);

struct chsc_ssd_area {
struct chsc_header request;
Expand Down
2 changes: 0 additions & 2 deletions trunk/drivers/s390/cio/chsc.h
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,4 @@ void chsc_chp_online(struct chp_id chpid);
void chsc_chp_offline(struct chp_id chpid);
int chsc_get_channel_measurement_chars(struct channel_path *chp);

int chsc_error_from_response(int response);

#endif
Loading

0 comments on commit aa3172a

Please sign in to comment.