Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp5225488pxv; Tue, 20 Jul 2021 23:48:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwJ3Ut101WYKJ9/jxyQzjzDXTGDrxxbIUTSxgweRnOlnksGWkavTc2Rr6FyRNmpm8H+QzfC X-Received: by 2002:a05:6638:c4a:: with SMTP id g10mr29701957jal.21.1626850092401; Tue, 20 Jul 2021 23:48:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626850092; cv=none; d=google.com; s=arc-20160816; b=hN2uiIbogOUiJEAXBiaPztXEicy+Sa0UwrBe+ZUYF8cnKjVUMTSgVr/7rNSuWbVQ7+ LO7Pl/+K3yaxbiyXb0EI1CtNf738i8542FDlQ3mU8tvWYKGF146kYNWMg68WR0xd7jeI HmwlDRSimz4k6uNvaieocISg2+Zzl/ay+cwhNCNOK4dYf4K6mCG7pVWD64J3LNXtzEh2 SK+2zTJ9QobxF6BbtxAFu9bBw5ygfkO9k122d/WEZsJg0dvPNcH6mid/j7mGd+/eXHA7 xprhAxRw10binaVBpPE7k8LD8jQjbYSkb8l1Y3UIEhMByFpKBHeUChBjl6ZFZP86xH2X c8Vg== 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=AuOSEbimPYOX6gL06T3EQj240irYWI0lc+R5KYfyRnM=; b=QzsOdcXPN9SfbZ1FCIkoW7y6xezJQiQDSnajSWeWaSzXtkbqhVgNtHyw5GTYNvxM2Y op3JrOZdUyv7qxLUxZwodmT4xWeU1tfRO/gtgFEGCjs/l51x3h/VTaYcVCXYVWsV5TJq blRdhWczcqVb1l2mN3z45FBDXwwOyCkY6uoE1wG3m9l3rHyw4jFsYpoejkrGTj+CfR5o Z453MwRZgRuyyXnHW2tNXLY+jNF7pxn62h9eYoimisMHw5fJu2bAkbKcZ46ryV+FCdXM kQvXUPGz832iZqvjNC4SlGmvNPtcYMv28wBl+lt1JC0O4ADvSb1H8x8o2dL9sCrPvoNS SEjA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=csREhhaW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t11si27491268jan.92.2021.07.20.23.48.01; Tue, 20 Jul 2021 23:48:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=csREhhaW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234999AbhGUGEO (ORCPT + 99 others); Wed, 21 Jul 2021 02:04:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34566 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234392AbhGUGBA (ORCPT ); Wed, 21 Jul 2021 02:01:00 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5CC24C061574; Tue, 20 Jul 2021 23:41:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=AuOSEbimPYOX6gL06T3EQj240irYWI0lc+R5KYfyRnM=; b=csREhhaW+x+G/vEokg4j8THUcJ VoiZOryV7Ws6XVE4LUqE3maX6Oz36QShzzEhyCAySz2aYxFfq/mKUWLZPesGKKVTX8K865i6vxyg/ YpkKaqe4jAkek4xteOtzIhPTgoRZ0JdVq27GxOLSYOX4jQkxBoKadB1A5eQHfxUVllWTZF6FpUSoi atohL5+D0e6ulKvRlhK26bsxX/GlVvSbXR3ZsvCduD0N8Axd5AQhCAdqGO585PDWMNZyeLmYA9M5G 1WrMW71QnzGHR/ia4rtPS56+xD7KK4knzEeb70+npXJCJm25VGzYOqs5YXXsTe/Y/9acSWy2QADh5 qi53PnXA==; Received: from hch by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1m65uq-008t6q-Ff; Wed, 21 Jul 2021 06:41:17 +0000 Date: Wed, 21 Jul 2021 07:41:12 +0100 From: Christoph Hellwig To: Leon Romanovsky Cc: Doug Ledford , Jason Gunthorpe , Leon Romanovsky , linux-kernel@vger.kernel.org, linux-rdma@vger.kernel.org, Mark Zhang Subject: Re: [PATCH rdma-next 3/7] RDMA/core: Remove protection from wrong in-kernel API usage Message-ID: References: <8084238e374fe487c3f9728c2ee5ec8736c204d5.1626846795.git.leonro@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <8084238e374fe487c3f9728c2ee5ec8736c204d5.1626846795.git.leonro@nvidia.com> X-SRS-Rewrite: SMTP reverse-path rewritten from by casper.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jul 21, 2021 at 09:13:02AM +0300, Leon Romanovsky wrote: > From: Leon Romanovsky > > The ib_create_named_qp() is kernel verb that is not used for user > supplied attributes. In such case, it is ULP responsibility to provide > valid QP attributes. > > In-kernel API shouldn't check it, exactly like other functions that > don't check device capabilities. Hmm. These still looks like useful debugging checks.