From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752470AbdLGT4g (ORCPT ); Thu, 7 Dec 2017 14:56:36 -0500 Received: from mail-lf0-f68.google.com ([209.85.215.68]:39738 "EHLO mail-lf0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751038AbdLGT4e (ORCPT ); Thu, 7 Dec 2017 14:56:34 -0500 X-Google-Smtp-Source: AGs4zMZmC5pxZ2rN0/CrBq9o8AwGoqsscoEOuH05lIWPdId4BUmRmkjcaEgIxIo6Smo0d7hWrk8PiQ== Date: Thu, 7 Dec 2017 21:56:30 +0200 From: Ivan Khoronzhuk To: David Miller Cc: grygorii.strashko@ti.com, netdev@vger.kernel.org, linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH net-next] net: ethernet: ti: cpdma: correct error handling for chan create Message-ID: <20171207195629.GB3022@khorivan> Mail-Followup-To: David Miller , grygorii.strashko@ti.com, netdev@vger.kernel.org, linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org References: <1512572050-13442-1-git-send-email-ivan.khoronzhuk@linaro.org> <20171206.163814.2298864765495270615.davem@davemloft.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20171206.163814.2298864765495270615.davem@davemloft.net> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Dec 06, 2017 at 04:38:14PM -0500, David Miller wrote: > From: Ivan Khoronzhuk > Date: Wed, 6 Dec 2017 16:54:09 +0200 > > > @@ -3065,10 +3065,16 @@ static int cpsw_probe(struct platform_device *pdev) > > } > > > > cpsw->txv[0].ch = cpdma_chan_create(cpsw->dma, 0, cpsw_tx_handler, 0); > > + if (WARN_ON(IS_ERR(cpsw->txv[0].ch))) { > > + dev_err(priv->dev, "error initializing tx dma channel\n"); > > + ret = PTR_ERR(cpsw->txv[0].ch); > > + goto clean_dma_ret; > > + } > > + > > You're already emitting a proper dev_err() message, therefore WARN_ON() > is a duplicate notification to the logs and therefore not appropriate. Yes, will remove unneeded WARNs -- Regards, Ivan Khoronzhuk