summaryrefslogtreecommitdiffstats
path: root/drivers/hwtracing
diff options
context:
space:
mode:
authorMarkus Elfring <elfring@users.sourceforge.net>2017-06-05 14:15:07 -0600
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-06-09 11:45:24 +0200
commit0f9df80ef5f4be1a3abbb161e1469884110a0112 (patch)
treef777859ed50fee02c75bf9da8122bc98f31b28b9 /drivers/hwtracing
parentf42fe520e449bda213f035478ddc9cf99e9082ac (diff)
downloadlinux-0f9df80ef5f4be1a3abbb161e1469884110a0112.tar.gz
linux-0f9df80ef5f4be1a3abbb161e1469884110a0112.tar.bz2
linux-0f9df80ef5f4be1a3abbb161e1469884110a0112.zip
coresight: etb10: Delete an error message for a failed memory allocation in etb_probe()
Omit an extra message for a memory allocation failure in this function. This issue was detected by using the Coccinelle software. Link: http://events.linuxfoundation.org/sites/events/files/slides/LCJ16-Refactor_Strings-WSang_0.pdf Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/hwtracing')
-rw-r--r--drivers/hwtracing/coresight/coresight-etb10.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/hwtracing/coresight/coresight-etb10.c b/drivers/hwtracing/coresight/coresight-etb10.c
index 979ea6ec7902..837aebf22c45 100644
--- a/drivers/hwtracing/coresight/coresight-etb10.c
+++ b/drivers/hwtracing/coresight/coresight-etb10.c
@@ -675,11 +675,8 @@ static int etb_probe(struct amba_device *adev, const struct amba_id *id)
drvdata->buf = devm_kzalloc(dev,
drvdata->buffer_depth * 4, GFP_KERNEL);
- if (!drvdata->buf) {
- dev_err(dev, "Failed to allocate %u bytes for buffer data\n",
- drvdata->buffer_depth * 4);
+ if (!drvdata->buf)
return -ENOMEM;
- }
desc.type = CORESIGHT_DEV_TYPE_SINK;
desc.subtype.sink_subtype = CORESIGHT_DEV_SUBTYPE_SINK_BUFFER;