Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp387472rwb; Thu, 27 Jul 2023 14:30:51 -0700 (PDT) X-Google-Smtp-Source: APBJJlGI1lN2oOnhBZYekhXrv+s1JFsrInRErooAEb2+gGO4z48SulKry7rqnLh0QAWm8Ifp8hRL X-Received: by 2002:a05:6300:8095:b0:134:409f:41f4 with SMTP id ap21-20020a056300809500b00134409f41f4mr254789pzc.24.1690493450963; Thu, 27 Jul 2023 14:30:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690493450; cv=none; d=google.com; s=arc-20160816; b=sij6ttEElbIa6Qbw/KZeVzpBi+gxlV0s04FkVs5Sxv1H2Pty3qV1CCacIZqI/V3iNJ h6mF2RFjyz9gm0wzUNt63tPQbaBSlU48+6gOgRGboiFlYdOJwQ+WzcQBPS+YmlJ6Otfr gCV+F9PDIMJg5g7ERe+Ms9VAzd1Tz57wa4lCzgLxDv9b5u/dXq+jan4AfGQKfZOPGODv +rFyGwNvZoy64QHe863n/ZFucpI+UynGnVJOmHUSqvpX15lFvdujaV0mlS1rlkz0YMvW K7QRJUiGBw/X6C/g3PrzleUG9DJqXlNfDiGHDC4Xavi4gGc2GdKsaApyNMu97ZFg+qKz HVuw== 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:date:from; bh=Xby0Ui1Ztp53rY6xlzfdmWZpq8FdNKkIeENXVtbQJXM=; fh=bDIjc7DSBcbO40eIvSLdXTjg/t7A1DSQ6wwJ74rw5vg=; b=giG3A0uGQp+G713YLyqPcVO2q6+ME5CekweAlCMeXOHQcycEadQpFEpLGib+NimAP8 nLvzK+TJ4343drSstxkZWn6xnawFa7p7nZ6KxOAfqIG2KubbNvwugIYKEm8h4SGv5ukt pD1nx+QCgnwOr3a5reATwIdtd8Dg9JvVF/APBCj7e4z/xLcnvDgoEtNgQ0+E5Co/sgLf ZszmgrPmgdKpVpVMeaDuSP1EjHKPXMISc6hn/Cm9Y2lEWa83DUQpmpG72+FpPbs88e0/ fsB/sOfv0/Qew0Nfp2KAv9/dgpJXJ7RaH06/0wd5g4OckpgHr/Pjva1IuGwgvHNfpMhz Kglw== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s34-20020a632162000000b00563dc234457si1666800pgm.377.2023.07.27.14.30.38; Thu, 27 Jul 2023 14:30:50 -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; 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=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229514AbjG0VHL (ORCPT + 99 others); Thu, 27 Jul 2023 17:07:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40428 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229645AbjG0VHJ (ORCPT ); Thu, 27 Jul 2023 17:07:09 -0400 Received: from fgw21-7.mail.saunalahti.fi (fgw21-7.mail.saunalahti.fi [62.142.5.82]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 724D3273E for ; Thu, 27 Jul 2023 14:07:08 -0700 (PDT) Received: from localhost (88-113-24-87.elisa-laajakaista.fi [88.113.24.87]) by fgw21.mail.saunalahti.fi (Halon) with ESMTP id 8a0d0197-2cc1-11ee-abf4-005056bdd08f; Fri, 28 Jul 2023 00:07:05 +0300 (EEST) From: andy.shevchenko@gmail.com Date: Fri, 28 Jul 2023 00:07:05 +0300 To: Minjie Du Cc: Vladimir Oltean , Mark Brown , Richard Cochran , "open list:FREESCALE DSPI DRIVER" , open list , "open list:PTP HARDWARE CLOCK SUPPORT" , opensource.kernel@vivo.com Subject: Re: [PATCH v2] spi: fsl-dspi: Use dev_err_probe() in dspi_request_dma() Message-ID: References: <20230725035038.1702-1-duminjie@vivo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230725035038.1702-1-duminjie@vivo.com> X-Spam-Status: No, score=0.7 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, FORGED_GMAIL_RCVD,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED,SPF_HELO_NONE, SPF_SOFTFAIL,T_SCC_BODY_TEXT_LINE autolearn=no 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 Tue, Jul 25, 2023 at 11:50:37AM +0800, Minjie Du kirjoitti: > It is possible for dma_request_chan() to return EPROBE_DEFER, which means > dev is not ready yet. > At this point dev_err() will have no output. ... > if (IS_ERR(dma->chan_tx)) { > - dev_err(dev, "tx dma channel not available\n"); > ret = PTR_ERR(dma->chan_tx); > + dev_err_probe(dev, ret, "tx dma channel not available\n"); It can be even simpler ret = dev_err_probe(dev, PTR_ERR(dma->chan_tx), "tx dma channel not available\n"); > goto err_tx_channel; > } -- With Best Regards, Andy Shevchenko