Received: by 2002:a05:6358:701b:b0:131:369:b2a3 with SMTP id 27csp4028425rwo; Mon, 24 Jul 2023 22:36:04 -0700 (PDT) X-Google-Smtp-Source: APBJJlE45m/DtsD+RWzSA0No3pFQf60u/wn9w9/UjjUyh0MNXulfCaO0qKEF4NGG4CsjnLLL52kK X-Received: by 2002:a05:620a:4589:b0:767:e27d:99fe with SMTP id bp9-20020a05620a458900b00767e27d99femr2135879qkb.29.1690263363721; Mon, 24 Jul 2023 22:36:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690263363; cv=none; d=google.com; s=arc-20160816; b=h9GRK4GZISkdi1PyxlEM1/KS2i+cBPqFB7EVNYfAyN9+ALpzKq+NKIZamwiR0AOABY OWGxx+D7nXS5o/X5d5ihD6y2TT93tHm6ZlSCnpuqi+E5Jo0G9xh0KvzeI5lnuByR1AM1 hzyc03EEKbTcQSbwccPg9FHtJEFxJH33x9rkEJXcyrVU8aTDu9lL0Lmawnk6XAjqjqey O0HQQYHYyd2u8KPNdlCXwSvU9H0b1PLu4+Ztgm7dQXjTRzGDaozjnPGO+oNzq71y31hH 0F0SfHs8ZEQFXUdNRr021oNLKa0zp8JMd4lW6ICcr40mCDkhSRQRVFYdWnVctCi08RdP RTAA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=D0gON7eF0xqfPsqAMih07sB8zK68zYIMS/9LvW8C5ZA=; fh=xnrh65xi6rWSL3+2qIYpG9SxXkT+hvN/7tww8YPm5Vk=; b=vBZ2BFs1mCtMVM6cIjae21w0RpP/2hGBY2cie+BT16JH0h+79ahkXAh5+cR9y4SJOI 5UajWWuSP2Scqod8odM3FfHSfwp9lXT3vShs4NUNowJAis68T97cpdC7CODwmQnV56vN AG7NuZ3Bbo8YRhSnelX+keej9iA1VBkqvFDSKJeTzGwFn+IheusJZ89BO9EeIEwknLbW VTMmMfaw6gENBl+DngUQ43h3liKZNlK0IZJZOqa6qWAL3eSW2OfdnMa3SS/kZ0lsa3JC dHwxj7Rd5ViabSMAQse8G4JSpuXatyKwmLB/KJiKlL1feMsD9FmuOohBlwkD6b7Zf5Z5 RLWA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=XIbOBiYf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s12-20020a17090a760c00b00267fbd6ee69si6161236pjk.38.2023.07.24.22.35.49; Mon, 24 Jul 2023 22:36:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=XIbOBiYf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231848AbjGYEWn (ORCPT + 99 others); Tue, 25 Jul 2023 00:22:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52828 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231793AbjGYEWD (ORCPT ); Tue, 25 Jul 2023 00:22:03 -0400 Received: from mail-yb1-xb30.google.com (mail-yb1-xb30.google.com [IPv6:2607:f8b0:4864:20::b30]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 355E91BEC for ; Mon, 24 Jul 2023 21:21:26 -0700 (PDT) Received: by mail-yb1-xb30.google.com with SMTP id 3f1490d57ef6-d0fc1d97716so2005827276.1 for ; Mon, 24 Jul 2023 21:21:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1690258885; x=1690863685; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=D0gON7eF0xqfPsqAMih07sB8zK68zYIMS/9LvW8C5ZA=; b=XIbOBiYfpwIJCFF7IO7WckeirwYH7QGoJxQ/J6fQhytGuKTfutKgXHmHkXIYOhPytI 6ZjgVSqgbiiNDh0QkKFets1tQSCT1LVZI/FZ5BG3hQYuwIMqKxpyfM0MRrksmam7nod+ POnpOYnAnurgOCvduRKL9QJGB67+ZJLFMLN6FgTsLvoqAoGLVa2CUUCM/tbfyOKOPdEL hTQWir+5R0XIm4z/gXZCWB90BwSvopLHRnk013rq7s+9XWsF6o/BQJvvOv/vWF1LBG4a Yptp3aSIWE9bLhki4Il80NzE+5oqt1CIbNZryYrAWlJRGtgfJSZxHcwQ1fQ3PsLH2qe2 47MA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690258885; x=1690863685; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=D0gON7eF0xqfPsqAMih07sB8zK68zYIMS/9LvW8C5ZA=; b=HHa2+lz1T7GwuEMltM4M/lBGqNx9t1Bi0fy70e594uE8XrYOcJg4faUQFUwSdbhjis RRsRFc9swdtkXXzEa5MC9q6ZP4nDwlm0c4IVioeISJnrenYy1ZTU4jnVSEzPtg2+4plB dMtSBm3Bhoj4aBrtqjKjaKpziEYte28fvz5zMgObW5QMTtWZkbaB6SxS053w5fLUBnmj TWYuKoINu62HrnMk9VHs/xQZaI0jnP2JQIQsHY7G1UFW/J3hoDFd701YSvGmR0eEoqO9 JsTFb/co97/F3vZJk9V1pfnsQ+3O2jKwtu468rZYXqgwaAYf4pgpP7belLqH5Ib/QGTT VSRQ== X-Gm-Message-State: ABy/qLbhQnAuq9xLjlh0Xud13C4hfLL/fZv1d5mNs4ZBRqQrAsCS8ANm hjGLyPLAuzFkj6ogbyC8j+rF4fmgSRJqs6+nm80= X-Received: by 2002:a25:643:0:b0:d04:c3ee:feb5 with SMTP id 64-20020a250643000000b00d04c3eefeb5mr8257250ybg.52.1690258884686; Mon, 24 Jul 2023 21:21:24 -0700 (PDT) Received: from localhost ([122.172.87.195]) by smtp.gmail.com with ESMTPSA id u3-20020a170902b28300b001b8a897cd26sm9787129plr.195.2023.07.24.21.21.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 24 Jul 2023 21:21:24 -0700 (PDT) Date: Tue, 25 Jul 2023 09:51:21 +0530 From: Viresh Kumar To: Minjie Du Cc: Viresh Kumar , Sergey Shtylyov , Damien Le Moal , "open list:LIBATA PATA ARASAN COMPACT FLASH CONTROLLER" , open list , opensource.kernel@vivo.com Subject: Re: [PATCH v5] ata: pata_arasan_cf: Use dev_err_probe() instead dev_err() in data_xfer() Message-ID: <20230725042121.qo2kug5ypcfllqbt@vireshk-i7> References: <20230725030627.1103-1-duminjie@vivo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230725030627.1103-1-duminjie@vivo.com> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 25-07-23, 11:06, Minjie Du wrote: > It is possible for dma_request_chan() to return EPROBE_DEFER, which means > acdev->host->dev is not ready yet. > At this point dev_err() will have no output. > > Signed-off-by: Minjie Du > --- > V2 -> V5: Fixed code formatting errors. > --- > drivers/ata/pata_arasan_cf.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/drivers/ata/pata_arasan_cf.c b/drivers/ata/pata_arasan_cf.c > index 6ab294322e79..b32d47112c0a 100644 > --- a/drivers/ata/pata_arasan_cf.c > +++ b/drivers/ata/pata_arasan_cf.c > @@ -529,7 +529,8 @@ static void data_xfer(struct work_struct *work) > /* dma_request_channel may sleep, so calling from process context */ > acdev->dma_chan = dma_request_chan(acdev->host->dev, "data"); > if (IS_ERR(acdev->dma_chan)) { > - dev_err(acdev->host->dev, "Unable to get dma_chan\n"); > + dev_err_probe(acdev->host->dev, PTR_ERR(acdev->dma_chan), > + "Unable to get dma_chan\n"); > acdev->dma_chan = NULL; > goto chan_request_fail; > } Missed it last time, but the formatting looks okay now I guess. Acked-by: Viresh Kumar -- viresh