Commit 658bf027 authored by Patrick Mochel's avatar Patrick Mochel

sysfs: fixup some remaining s390 files.

From Arnd Bergmann.
parent 3750eee7
......@@ -616,13 +616,13 @@ chp_status_show(struct device *dev, char *buf)
switch(chp->state) {
case CHP_OFFLINE:
return snprintf(buf, count, "n/a\n");
return sprintf(buf, "n/a\n");
case CHP_LOGICALLY_OFFLINE:
return snprintf(buf, count, "logically offline\n");
return sprintf(buf, "logically offline\n");
case CHP_STANDBY:
return snprintf(buf, count, "n/a\n");
return sprintf(buf, "n/a\n");
case CHP_ONLINE:
return snprintf(buf, count, "online\n");
return sprintf(buf, "online\n");
default:
return 0;
}
......
......@@ -2762,27 +2762,23 @@ ctc_init_netdevice(struct net_device * dev, int alloc_device,
}
static ssize_t
ctc_proto_show(struct device *dev, char *buf, size_t count, loff_t off)
ctc_proto_show(struct device *dev, char *buf)
{
struct ctc_priv *priv;
if (off)
return 0;
priv = dev->driver_data;
if (!priv)
return -ENODEV;
return snprintf(buf, count, "%d\n", priv->protocol);
return sprintf(buf, "%d\n", priv->protocol);
}
static ssize_t
ctc_proto_store(struct device *dev, const char *buf, size_t count, loff_t off)
ctc_proto_store(struct device *dev, const char *buf, size_t count)
{
struct ctc_priv *priv;
int value;
if (off)
return 0;
priv = dev->driver_data;
if (!priv)
return -ENODEV;
......
......@@ -63,8 +63,7 @@ struct device cu3088_root_dev = {
};
static ssize_t
group_write(struct device_driver *drv, const char *buf, size_t count,
loff_t off)
group_write(struct device_driver *drv, const char *buf, size_t count)
{
const char *start, *end;
char bus_ids[2][BUS_ID_SIZE], *argv[2];
......@@ -72,9 +71,6 @@ group_write(struct device_driver *drv, const char *buf, size_t count,
int ret;
struct ccwgroup_driver *cdrv;
if (off)
return 0;
cdrv = to_ccwgroupdrv(drv);
if (!cdrv)
return -EINVAL;
......
......@@ -1473,11 +1473,11 @@ txtime_show (struct device *dev, char *buf)
{
netiucv_priv *priv = dev->driver_data;
return snprintf(buf, count, "%ld\n", priv->conn->prof.tx_time);
return sprintf(buf, "%ld\n", priv->conn->prof.tx_time);
}
static ssize_t
txtime_write (struct device *dev, const char *buf)
txtime_write (struct device *dev, const char *buf, size_t count)
{
netiucv_priv *priv = dev->driver_data;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment