From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S938872AbdAIPr6 (ORCPT ); Mon, 9 Jan 2017 10:47:58 -0500 Received: from mail.savoirfairelinux.com ([208.88.110.44]:42698 "EHLO mail.savoirfairelinux.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753551AbdAIPqY (ORCPT ); Mon, 9 Jan 2017 10:46:24 -0500 From: Vivien Didelot To: Jiri Pirko Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, kernel@savoirfairelinux.com, "David S. Miller" , Florian Fainelli , Andrew Lunn , Uwe =?utf-8?Q?Kleine-K=C3=B6nig?= , Andrey Smirnov Subject: Re: [PATCH net-next v2] net: dsa: make "label" property optional for dsa2 In-Reply-To: <20170109151131.GC1862@nanopsycho> References: <20170108231552.26995-1-vivien.didelot@savoirfairelinux.com> <20170109073236.GA1862@nanopsycho> <877f6446lp.fsf@weeman.i-did-not-set--mail-host-address--so-tickle-me> <20170109151131.GC1862@nanopsycho> Date: Mon, 09 Jan 2017 10:45:33 -0500 Message-ID: <87y3yk2q5e.fsf@weeman.i-did-not-set--mail-host-address--so-tickle-me> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Jiri, Jiri Pirko writes: >>Extra question: shouldn't phys_port_{id,name} be switchdev attributes in > > Again, phys_port_id has nothing to do with switches. Should be removed > from dsa because its use there is incorrect. Florian, since 3a543ef just got in, can it be reverted? >>> I guess that it should be enough for you to implement >>> ndo_get_phys_port_name. >> >>Well, if this name must be unique on a system, it's not likely to happen >>until we agree that we use an ugly tXsYpZ template where X is a tree ID, >>or we assign system-wide unique IDs to switches, which requires a bit of >>changes. > > No. That should be unique within one switch. In mlxsw we name it "p1", > "p2", ... > > The final netdev names are: > enp3s0np1, enp3s0np2, ... OK perfect then, "p%d" sounds good. You seems to avoid "p0" in mlxsw, is there a reason for that? >>But again, this is not related to this patch ;-) > > It is! You are using phys_port_id, which is completely wrong. You should > not use it. I can resend this patch without the udev examples in the commit message if that can be less confusing. Thanks, Vivien