From 76b04e7df74a07749425697e799a4b7a969b1d90 Mon Sep 17 00:00:00 2001 From: Federico Vaga <federico.vaga@gmail.com> Date: Thu, 10 Nov 2011 12:45:04 +0100 Subject: [PATCH] trivial: review comment strings Signed-off-by: Federico Vaga <federico.vaga@gmail.com> Acked-by: Alessandro Rubini <rubini@gnudd.com> --- zio-dev.c | 4 ++-- zio-sys.c | 16 +++++++++------- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/zio-dev.c b/zio-dev.c index 5f20813..5b81d67 100644 --- a/zio-dev.c +++ b/zio-dev.c @@ -207,8 +207,8 @@ int __zio_register_cdev() err = alloc_chrdev_region(&zstat.basedev, 0, ZIO_CSET_MAXNUM * ZIO_NMAX_CSET_MINORS, "zio"); if (err) { - pr_err("%s: unable to alloc region for %i minors\n", __func__, - ZIO_CSET_MAXNUM * ZIO_NMAX_CSET_MINORS); + pr_err("%s: unable to allocate region for %i minors\n", + __func__, ZIO_CSET_MAXNUM * ZIO_NMAX_CSET_MINORS); goto out; } /* all ZIO's devices, buffers and triggers has zfops as f_op */ diff --git a/zio-sys.c b/zio-sys.c index 7f55905..4533438 100644 --- a/zio-sys.c +++ b/zio-sys.c @@ -227,11 +227,11 @@ static int zobj_unique_name(struct zio_object_list *zobj_list, char *name) /* if not auto-assigned, then error */ if (!auto_index) { - pr_err("ZIO: name %s is already in use\n", + pr_err("ZIO: name \"%s\" is already taken\n", name); return -EBUSY; } - + /* build sequential name */ if (__next_strlen(name_to_check) > ZIO_NAME_LEN) { pr_err("ZIO: invalid name \"%s\"\n", name); return -EINVAL; @@ -478,7 +478,7 @@ static int zattr_create_group(struct kobject *kobj, to_zio_zattr(grp->attrs[i])->d_op = d_op; if (!grp->attrs[i]->name) { if (is_ext) { - pr_err("%s: can't create extended attribute. " + pr_warning("%s: can't create ext attributes. " "%ith attribute has not a name", __func__, i); return 0; } @@ -620,7 +620,7 @@ static int __trigger_create_instance(struct zio_cset *cset) ti = cset->trig->t_op->create(cset->trig, cset, ctrl, 0/*FIXME*/); if (IS_ERR(ti)) { err = PTR_ERR(ti); - pr_err("%s: can't create trigger (%i)\n", __func__, err); + pr_err("%s: can't create trigger error %i\n", __func__, err); goto out; } /* Now fill the trigger instance, ops, head, then the rest */ @@ -829,7 +829,8 @@ static int cset_register(struct zio_cset *cset) if (!cset->zbuf) { cset->zbuf = zbuf_find_by_name(ZIO_DEFAULT_BUFFER); if (!cset->zbuf) { - pr_err("ZIO: can't set buffer to cset\n"); + pr_err("ZIO: can't find buffer \"%s\"\n", + ZIO_DEFAULT_BUFFER); err = -EBUSY; goto out_buf; } @@ -863,7 +864,8 @@ static int cset_register(struct zio_cset *cset) if (!cset->trig) { cset->trig = trig_find_by_name(ZIO_DEFAULT_TRIGGER); if (!cset->trig) { - pr_err("ZIO: can't set trigger to cset\n"); + pr_err("ZIO: can't find trigger \"%s\"\n", + ZIO_DEFAULT_TRIGGER); err = -EBUSY; goto out_reg; } @@ -999,7 +1001,7 @@ int zio_register_dev(struct zio_device *zdev, const char *name) return -EINVAL; if (!zdev->d_op->input_block && !zdev->d_op->output_block) { - pr_err("%s: no nput_block nor output_block methods\n", + pr_err("%s: no input_block nor output_block methods\n", __func__); return -EINVAL; } -- GitLab