Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757293AbcCaRwN (ORCPT ); Thu, 31 Mar 2016 13:52:13 -0400 Received: from mail-vk0-f50.google.com ([209.85.213.50]:35571 "EHLO mail-vk0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754767AbcCaRwL (ORCPT ); Thu, 31 Mar 2016 13:52:11 -0400 MIME-Version: 1.0 In-Reply-To: <1459393901-18758-1-git-send-email-shawn.lin@rock-chips.com> References: <1459393901-18758-1-git-send-email-shawn.lin@rock-chips.com> Date: Thu, 31 Mar 2016 10:52:09 -0700 X-Google-Sender-Auth: HXdrW40Fz5qI1GVAZo-02TM-cE8 Message-ID: Subject: Re: [PATCH v2] spi: rockchip: fix warning of static check From: Doug Anderson To: Shawn Lin Cc: Mark Brown , "linux-kernel@vger.kernel.org" , Dan Carpenter , linux-spi@vger.kernel.org Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1022 Lines: 30 Shawn, On Wed, Mar 30, 2016 at 8:11 PM, Shawn Lin wrote: > Use dma_request_chan instead of dma_request_slave_channel, > in this case we can check EPROBE_DEFER without static > warning. Technically this is more than just a warning fix. The previous commit 61cadcf46cfd ("spi: rockchip: check requesting dma channel with EPROBE_DEFER") could never have done what it was supposed to do because dma_request_slave_channel() could never return EPROBE_DEFER. ...so really this makes the previous commit work properly. > Reported-by: Dan Carpenter > Cc: Doug Anderson > Cc: Dan Carpenter > Signed-off-by: Shawn Lin > > --- > > Changes in v2: > - use dma_request_chan and replace IS_ERR_OR_NULL() > with IS_ERR > - do the same for rx > > drivers/spi/spi-rockchip.c | 14 +++++++++----- > 1 file changed, 9 insertions(+), 5 deletions(-) Reviewed-by: Douglas Anderson