From: Markus Elfring <elfring@xxxxxxxxxxxxxxxxxxxxx> Date: Fri, 2 Feb 2018 20:02:17 +0100 Omit an extra message for a memory allocation failure in this function. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@xxxxxxxxxxxxxxxxxxxxx> --- drivers/hsi/clients/ssi_protocol.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/hsi/clients/ssi_protocol.c b/drivers/hsi/clients/ssi_protocol.c index 9b167bc6eee4..0bccea2fa119 100644 --- a/drivers/hsi/clients/ssi_protocol.c +++ b/drivers/hsi/clients/ssi_protocol.c @@ -1088,10 +1088,8 @@ static int ssi_protocol_probe(struct device *dev) int err; ssi = kzalloc(sizeof(*ssi), GFP_KERNEL); - if (!ssi) { - dev_err(dev, "No memory for ssi protocol\n"); + if (!ssi) return -ENOMEM; - } spin_lock_init(&ssi->lock); timer_setup(&ssi->rx_wd, ssip_rx_wd, TIMER_DEFERRABLE); -- 2.16.1 -- To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html