From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=3.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_PASS, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 440FAC43381 for ; Fri, 8 Mar 2019 02:52:17 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id EE10E20840 for ; Fri, 8 Mar 2019 02:52:16 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=netronome-com.20150623.gappssmtp.com header.i=@netronome-com.20150623.gappssmtp.com header.b="rVqNjlWi" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726336AbfCHCwP (ORCPT ); Thu, 7 Mar 2019 21:52:15 -0500 Received: from mail-qt1-f194.google.com ([209.85.160.194]:41819 "EHLO mail-qt1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726275AbfCHCwP (ORCPT ); Thu, 7 Mar 2019 21:52:15 -0500 Received: by mail-qt1-f194.google.com with SMTP id v10so19724080qtp.8 for ; Thu, 07 Mar 2019 18:52:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=netronome-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :organization:mime-version:content-transfer-encoding; bh=LzXAbXwoqGLLvFiUBLtR/V+8eNGxLHB+ekoJuM2+4T4=; b=rVqNjlWiHK+7KlAi6p8QLKl4tu8NZOSb0T9VSKy6QH/EUUYrcqcfANYNt+XXG+xQ+6 KP+w5AI99KZU4ijajPwNJnu9KfOKmhn58Ib1jNpclzS74u42DjuspnNBSKPFbKXkzw9/ vLjV0USKrcGOQb+du9YIcMVgmBtXi7aHbVBg4bRUfN6OUTmWYIj0D+Z3Se2Z6UMU2QIk oS7drtodafqxfcwyqiYt+Hw/Q/4uwTA+cHkOL/jS5Pb4cKeZ/z+FNIExaxGr9s/8rbQV hjqqC9bXqqFd7Wc5lvyOPJh53G5Xwwoj3uO3HeA5O3lMx/ynq3GF5Wjw93j718RbEd/0 LojA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:organization:mime-version:content-transfer-encoding; bh=LzXAbXwoqGLLvFiUBLtR/V+8eNGxLHB+ekoJuM2+4T4=; b=mhwUOe6v0DX44MdrZQ6BOn7hUvuYBd4QCDCJ+ctrl9mZeAn0oPiDRqWP6wbVYkcUur NqIrB/gs/8wAKXzBOX5D0zsZFpmho7rmk1kOcXQpPJrIduWZGMqpGHp6D/Cj9qjPHjvY lva1UevpO7Y6Gp0ebItq+bqGwCVm9dRwwJ6OxTx4Q5OmtmaC+C22CKfXxh1DE1BzLUHJ 3kH8QiCM2s623e8cBJlOawrw8UCk7r/Y1e0sAFqmyFT1sQxztK6edUmYJNRK6ysuCeav nYR6ioJ+qVH7f3nMWStHqzMCs2fNVlpLX5OfDddTNFeozrHnAyyS4C72SWuH+xTtow0Z /1kQ== X-Gm-Message-State: APjAAAUJ7CA0Cb+FHH/OjX7Dqcq5Hcq3phHAGE3uLJpLvsEZhqtZyUDn FxWA9Nqr8ltdB2C/xB8T47fDhE1xnRc= X-Google-Smtp-Source: APXvYqxGI04QRKNhFV/ZZAJzzmw/uwF3iP9J817zmh8tTO3/IZcLVCmd8cjetJWglyEO5vFDbTHTTw== X-Received: by 2002:aed:3f5d:: with SMTP id q29mr12498011qtf.193.1552013534063; Thu, 07 Mar 2019 18:52:14 -0800 (PST) Received: from cakuba.hsd1.ca.comcast.net ([66.60.152.14]) by smtp.gmail.com with ESMTPSA id t5sm4093283qta.77.2019.03.07.18.52.12 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 07 Mar 2019 18:52:13 -0800 (PST) Date: Thu, 7 Mar 2019 18:52:02 -0800 From: Jakub Kicinski To: Jiri Pirko Cc: davem@davemloft.net, netdev@vger.kernel.org, oss-drivers@netronome.com Subject: Re: [PATCH net-next v2 4/7] devlink: allow subports on devlink PCI ports Message-ID: <20190307185202.2db37490@cakuba.hsd1.ca.comcast.net> In-Reply-To: <20190307094816.GA2190@nanopsycho> References: <20190301180453.17778-1-jakub.kicinski@netronome.com> <20190301180453.17778-5-jakub.kicinski@netronome.com> <20190302094116.GQ2314@nanopsycho> <20190302114847.733759a1@cakuba.netronome.com> <20190304075609.GV2314@nanopsycho> <20190304163302.7e40219e@cakuba.netronome.com> <20190305110601.GC2314@nanopsycho> <20190305091534.36200de6@cakuba.hsd1.ca.comcast.net> <20190306122037.GB2819@nanopsycho> <20190306095638.7c028bdd@cakuba.hsd1.ca.comcast.net> <20190307094816.GA2190@nanopsycho> Organization: Netronome Systems, Ltd. MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Thu, 7 Mar 2019 10:48:16 +0100, Jiri Pirko wrote: > Wed, Mar 06, 2019 at 06:56:38PM CET, jakub.kicinski@netronome.com wrote: > >On Wed, 6 Mar 2019 13:20:37 +0100, Jiri Pirko wrote: > >For creating subdevices, I don't think the handle should ever be port. > >We create new ports on a devlink instance, and configure its forwarding > > Okay I agree. Something like: > $ devlink port add pci/0000:00:10.0 ..... > > It's a bit confusing because "set" accepts port handle (like > pci/0000:00:10.0/1). Probably better would be: > $ devlink dev port add pci/0000:00:10.0 ..... > > >with offloads of well established Linux SW constructs. New devices are > >not logically associated with other ports (see how in my patches there > >are 2 "subports" but no main port on that PF - a split not a hierarchy). > > Right, basically you have 2 equal objects. Makes sense. > > >How we want to model forwarding inside a VM (who configures the > >underlying switching) remains unclear. > > I don't understand. Could you elaborate a bit? If VF in a VM gets a partitioning request does the new port pop up on the hypervisor? With a port netdev? Does the VF also create a port object as well as host port object? That question is probably independent of host port discussion.