mirror of https://gitee.com/openkylin/linux.git
iio: buffer: cleanup messages in iio_update_buffers()
1. make messages grepable (in one line) 2. include returned errno in them Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
This commit is contained in:
parent
f5ce4a7a92
commit
bec1889d24
|
@ -542,8 +542,7 @@ int iio_update_buffers(struct iio_dev *indio_dev,
|
||||||
ret = indio_dev->setup_ops->preenable(indio_dev);
|
ret = indio_dev->setup_ops->preenable(indio_dev);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
printk(KERN_ERR
|
printk(KERN_ERR
|
||||||
"Buffer not started:"
|
"Buffer not started: buffer preenable failed (%d)\n", ret);
|
||||||
"buffer preenable failed\n");
|
|
||||||
goto error_remove_inserted;
|
goto error_remove_inserted;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -556,8 +555,7 @@ int iio_update_buffers(struct iio_dev *indio_dev,
|
||||||
ret = buffer->access->request_update(buffer);
|
ret = buffer->access->request_update(buffer);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
printk(KERN_INFO
|
printk(KERN_INFO
|
||||||
"Buffer not started:"
|
"Buffer not started: buffer parameter update failed (%d)\n", ret);
|
||||||
"buffer parameter update failed\n");
|
|
||||||
goto error_run_postdisable;
|
goto error_run_postdisable;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -566,7 +564,7 @@ int iio_update_buffers(struct iio_dev *indio_dev,
|
||||||
->update_scan_mode(indio_dev,
|
->update_scan_mode(indio_dev,
|
||||||
indio_dev->active_scan_mask);
|
indio_dev->active_scan_mask);
|
||||||
if (ret < 0) {
|
if (ret < 0) {
|
||||||
printk(KERN_INFO "update scan mode failed\n");
|
printk(KERN_INFO "Buffer not started: update scan mode failed (%d)\n", ret);
|
||||||
goto error_run_postdisable;
|
goto error_run_postdisable;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -590,7 +588,7 @@ int iio_update_buffers(struct iio_dev *indio_dev,
|
||||||
ret = indio_dev->setup_ops->postenable(indio_dev);
|
ret = indio_dev->setup_ops->postenable(indio_dev);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
printk(KERN_INFO
|
printk(KERN_INFO
|
||||||
"Buffer not started: postenable failed\n");
|
"Buffer not started: postenable failed (%d)\n", ret);
|
||||||
indio_dev->currentmode = INDIO_DIRECT_MODE;
|
indio_dev->currentmode = INDIO_DIRECT_MODE;
|
||||||
if (indio_dev->setup_ops->postdisable)
|
if (indio_dev->setup_ops->postdisable)
|
||||||
indio_dev->setup_ops->postdisable(indio_dev);
|
indio_dev->setup_ops->postdisable(indio_dev);
|
||||||
|
|
Loading…
Reference in New Issue