Received: by 2002:a05:6358:7058:b0:131:369:b2a3 with SMTP id 24csp2241706rwp; Fri, 14 Jul 2023 03:11:18 -0700 (PDT) X-Google-Smtp-Source: APBJJlF+awsR+I0dJg0yLgkx8MApGzU58/mL5tyrTHI8rN3QsaTfamlvi5bp9dbMU3MGJk5/e4/t X-Received: by 2002:a05:6512:3189:b0:4fb:9469:d65f with SMTP id i9-20020a056512318900b004fb9469d65fmr3209804lfe.37.1689329478435; Fri, 14 Jul 2023 03:11:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689329478; cv=none; d=google.com; s=arc-20160816; b=CxeCqpcVpNVKUK5y88rPDIm7KF2qt9WxzvJOIxlm1tChncLh7PXtnxpEI5QwqKuiMy Zofj1ryoVtV4wFuKj9TwtU7DBNel3aZMhHhTjMd45g+yx13dcJlkatzlqgQk9OC65iT6 JyKNBtL9jhn+GV35mQvJs5ZOp/VEw91LvIkttl9C4HnN6dNLtpvnt0tbNqdByI+4s2CN 79Fa3omC+WIRHl3F9VY0/MM5/4V/Cfg7XLjZz5gaUeZ3m+QRZ04Ugrr8lgE4gRaEPDTA Cvi16BYnuo66mHFFENxb1cCeOD9P/XyeahzYWj6ZciVCRNQHyvhqmzn63k5gjpIGfoUo T2GQ== 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=nW17uulaRP+RzVbFI1UVw6jezngQMBzbw6+rTsBgQ78=; fh=o5NQ9++Adq/7BHUmvfyo0im0Nw2NKpApzPwAK0xZuwU=; b=INWI8A/1/fvK9i5SFWuHygT+zFsw8kh8cClYLJ2Ry2lRn5RGWqkbyflvqwASsK6SI5 OezvL9ZYKMd08zm1h7fCQouh3Kye9b/A5InInZ8ASWvhYCqgP2srAe9n3DmTlmIto99Q JAKmu4hqZjkDPE8iSyc15YjqQgyL8fYWTqlzoMUZ/MJMXJCl0GnKWWEcn9i+DkzFM8u9 NlsvmCsDwf+OWZjjPZLh2BAOeVe5zSMNhW3l63Dju7egzLpzUOfweLkcbxq8jbwlMsD8 4hQWm25N1Px3E2o23NErTcK/MYapXvcz2IPTa9Il37FKhlLmUZTVnIIyBgp1ZqxzmuYW 63pg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=FEaWOpZL; 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=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 bm17-20020a0564020b1100b0051dd401bf24si8542972edb.447.2023.07.14.03.10.52; Fri, 14 Jul 2023 03:11:18 -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=@gmail.com header.s=20221208 header.b=FEaWOpZL; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234861AbjGNKAq (ORCPT + 99 others); Fri, 14 Jul 2023 06:00:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48140 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235636AbjGNKAo (ORCPT ); Fri, 14 Jul 2023 06:00:44 -0400 Received: from mail-lf1-x133.google.com (mail-lf1-x133.google.com [IPv6:2a00:1450:4864:20::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9214DA7 for ; Fri, 14 Jul 2023 03:00:43 -0700 (PDT) Received: by mail-lf1-x133.google.com with SMTP id 2adb3069b0e04-4fbf1f6c771so2940724e87.1 for ; Fri, 14 Jul 2023 03:00:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1689328842; x=1691920842; 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=nW17uulaRP+RzVbFI1UVw6jezngQMBzbw6+rTsBgQ78=; b=FEaWOpZLavjysJsvR3BbULO6j53U+vn5Phun4cT01xIYLHlJSLFdtHG46xtHuNtDTJ 1KKts5LWVtDJF2LCN79TLbCStPSYp889j5QIrQqEfcGSYx8ISkfdLNhNQObgIfuIezM6 Fv1R5G4wNPYfGHCjGsjfkYXp+Ftv3AyE7Z+4gDHbyrTlT7z9I9JzRgSfhQk8TiyDx5Mv mnAOX4Ys1SBcp7EJeoaXqYu3xtVrv+OLMfTSRbtN2gM0QVndnaq0ABIQU+CEPXnxWNRs kITpjxPO4N625IAjMV7GZP5ngMi+eiUyW0oFqxkecMeeF14M0+Ij396odW0iAddSx8Kc JCdg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689328842; x=1691920842; 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=nW17uulaRP+RzVbFI1UVw6jezngQMBzbw6+rTsBgQ78=; b=VwBxGjchsBGfXrady7R7OnIGjG9bbXdHJ4pGpnbQ4YEq8205XUTdeSNX8BGIwBw1NM BZJJkopmII0xCRCQ4wZD3I9jLvOuZjhG+M3flQS4k7Iog8NTSXSpj+fnOX9xR+TBlfLq maY53JrLo6yiudKpGSRARZmZwpKxj35hA8fHBKiVItqgDcu7xQtBusdNZGchYTRwrYWQ 7o3wo533vObYELawifbG7yXOZBS6bXFdMjVxfhKRj7zlAB7KZV1aTt8YDk6SxNxwnMQm AHmV6I9lLjLTc04UxqqvgMrZYQL3z+wK+JdOhfSS6Q8CzRFCwPTtreo7juUdcXgRvY6p s0pA== X-Gm-Message-State: ABy/qLYhYzro0RqxIuWc2c/6rVihtaP+K2NBAbRhH0PiwFo3S0PrBO+r D5hMst8pg3LL3V6WWtU14ak= X-Received: by 2002:a19:2d05:0:b0:4f8:7697:5207 with SMTP id k5-20020a192d05000000b004f876975207mr2979938lfj.23.1689328841558; Fri, 14 Jul 2023 03:00:41 -0700 (PDT) Received: from mobilestation ([85.249.20.77]) by smtp.gmail.com with ESMTPSA id g15-20020ac2538f000000b004fb881e5c23sm1424489lfh.47.2023.07.14.03.00.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 14 Jul 2023 03:00:41 -0700 (PDT) Date: Fri, 14 Jul 2023 13:00:38 +0300 From: Serge Semin To: Wang Ming Cc: Jon Mason , Dave Jiang , Allen Hubbe , Dan Carpenter , Jiasheng Jiang , ntb@lists.linux.dev, linux-kernel@vger.kernel.org, opensource.kernel@vivo.com, dan.carpenter@linaro.org Subject: Re: [PATCH v3] ntb: Remove error checking for debugfs_create_dir() Message-ID: References: <20230713085621.3380-1-machel@vivo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230713085621.3380-1-machel@vivo.com> X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,RCVD_IN_SBL,SPF_HELO_NONE,SPF_PASS, 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 On Thu, Jul 13, 2023 at 04:56:06PM +0800, Wang Ming wrote: > It is expected that most callers should _ignore_ the errors > return by debugfs_create_dir() in tool_setup_dbgfs() > > Signed-off-by: Wang Ming The patch itself is correct for sure: Reviewed-by: Serge Semin As a side note IMO I would have converted the driver to successfully probe an NTB device only if DebugFS is enabled and all the DebugFS-nodes are successfully created. That's because the driver fully relies on the DebugFS nodes to activate its functionality. Without them being available it's absolutely useless. The way the test-driver is utilized is demonstrated for instance in the NTB-test script: tools/testing/selftests/ntb/ntb_test.sh . * It concerns all the NTB test drivers... -Serge(y) > --- > drivers/ntb/test/ntb_tool.c | 2 -- > 1 file changed, 2 deletions(-) > > diff --git a/drivers/ntb/test/ntb_tool.c b/drivers/ntb/test/ntb_tool.c > index eeeb4b1c97d2..e0acc11d29ba 100644 > --- a/drivers/ntb/test/ntb_tool.c > +++ b/drivers/ntb/test/ntb_tool.c > @@ -1495,8 +1495,6 @@ static void tool_setup_dbgfs(struct tool_ctx *tc) > > tc->dbgfs_dir = debugfs_create_dir(dev_name(&tc->ntb->dev), > tool_dbgfs_topdir); > - if (!tc->dbgfs_dir) > - return; > > debugfs_create_file("port", 0600, tc->dbgfs_dir, > tc, &tool_port_fops); > -- > 2.25.1 >