diff options
author | Dominik Brodowski <linux@dominikbrodowski.net> | 2021-10-15 10:13:23 +0300 |
---|---|---|
committer | Dominik Brodowski <linux@dominikbrodowski.net> | 2022-01-06 11:15:52 +0300 |
commit | 78e0185c25af8d1e20d3bb390c6c1e6b69ae3a52 (patch) | |
tree | 52768f5267ce5a80786895ecec0380a2f84fd2f1 /drivers/pcmcia/rsrc_nonstatic.c | |
parent | fffbcee9335ccf97adf2b5b342099b6430e8dbfd (diff) | |
download | linux-78e0185c25af8d1e20d3bb390c6c1e6b69ae3a52.tar.xz |
pcmcia: use sysfs_emit{,_at} for sysfs output
Convert the PCMCIA core and yenta_socket.c to use sysfs_emit or
sysfs_emit_at when providing output in sysfs.
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'drivers/pcmcia/rsrc_nonstatic.c')
-rw-r--r-- | drivers/pcmcia/rsrc_nonstatic.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/pcmcia/rsrc_nonstatic.c b/drivers/pcmcia/rsrc_nonstatic.c index 1cac52870711..6b6c578b5f92 100644 --- a/drivers/pcmcia/rsrc_nonstatic.c +++ b/drivers/pcmcia/rsrc_nonstatic.c @@ -1082,7 +1082,7 @@ static ssize_t show_io_db(struct device *dev, for (p = data->io_db.next; p != &data->io_db; p = p->next) { if (ret > (PAGE_SIZE - 10)) continue; - ret += scnprintf(&buf[ret], (PAGE_SIZE - ret - 1), + ret += sysfs_emit_at(buf, ret, "0x%08lx - 0x%08lx\n", ((unsigned long) p->base), ((unsigned long) p->base + p->num - 1)); @@ -1139,7 +1139,7 @@ static ssize_t show_mem_db(struct device *dev, p = p->next) { if (ret > (PAGE_SIZE - 10)) continue; - ret += scnprintf(&buf[ret], (PAGE_SIZE - ret - 1), + ret += sysfs_emit_at(buf, ret, "0x%08lx - 0x%08lx\n", ((unsigned long) p->base), ((unsigned long) p->base + p->num - 1)); @@ -1148,7 +1148,7 @@ static ssize_t show_mem_db(struct device *dev, for (p = data->mem_db.next; p != &data->mem_db; p = p->next) { if (ret > (PAGE_SIZE - 10)) continue; - ret += scnprintf(&buf[ret], (PAGE_SIZE - ret - 1), + ret += sysfs_emit_at(buf, ret, "0x%08lx - 0x%08lx\n", ((unsigned long) p->base), ((unsigned long) p->base + p->num - 1)); |