Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp7448427imu; Tue, 22 Jan 2019 06:16:56 -0800 (PST) X-Google-Smtp-Source: ALg8bN5mLuVntV7yMU3z1FNtSidabmjW0aGoX0nTvJ9SbX0xVulx3BTyoIYTGocqJs8ZODHUgZxM X-Received: by 2002:a17:902:9f93:: with SMTP id g19mr33926217plq.195.1548166616023; Tue, 22 Jan 2019 06:16:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548166615; cv=none; d=google.com; s=arc-20160816; b=O5TBRNROulKkn9tK/GUlC9aKmUj3dYGMGd4q6dTT3TUDYfu5X3ORK4u0iiT6oV5Dcr pCW6p80rcr9la3sAk4V8cdKh+3LpnJ+OzQQJxu9L5b0JwNDSBEblqLLHrIkvMLfjdHp6 un6JobRw4fCUpBkJOL2lYJEBDCBFgj2bc50xUKz/jhAjdrya3qAhvmOdFMVq0H9h+Y8g BYxfirVS0Wdh0ZcsVuxh76aEDkaLkuUWgKV3W+ujHbe3Z8CeaOq5anBjTKbeO40T4i/G KRIQ9QLX5ttE+vDE5ZB7J0IJU78HgQpmMT8XZgdsDBn4nOhAyPsMc0sne583L/39pZz1 s0ng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:mail-followup-to:message-id:subject:cc:to:from:date :dkim-signature; bh=Op3moRbjYhsjbDcDIGxabNze9TBnhI+Sx/SlKViaMAk=; b=JpDU2IRf19uECxfo3ab/M5WmW2zjyNUDNP7RUk20Jj+kVqDyg4MeTywrEpWZUFo4hb zsNd1HaCuhtieuqzEr58lRTIL6nIZl164eSriGYpKY8WUpIL8oQwpTKgxNYTWcPu1QSg JLfbhI5ZEmYHaA5E8AJ8ZiGyG36+P2GsLP8fMWjUiIWHdiHwBbzJdN1BGjdPsZSezwII QB1x9jqzGQjhKpYznPQnP70tu7/RtE5A1XMt2tIuRkuGJ/o75vIt77h8LHiBTTFsi284 zyKZA4pip7XSw2bbhwfmDQyw2tvsRz+tHYXXm9k4qKBHrfsNVLG+S7vj9LMKwUrV56Ig P+3Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=EVNV3Kf4; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 35si15178330pgn.278.2019.01.22.06.16.40; Tue, 22 Jan 2019 06:16:55 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=EVNV3Kf4; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728719AbfAVOP0 (ORCPT + 99 others); Tue, 22 Jan 2019 09:15:26 -0500 Received: from mail-lj1-f196.google.com ([209.85.208.196]:35526 "EHLO mail-lj1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728509AbfAVOPZ (ORCPT ); Tue, 22 Jan 2019 09:15:25 -0500 Received: by mail-lj1-f196.google.com with SMTP id x85-v6so20784993ljb.2 for ; Tue, 22 Jan 2019 06:15:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:mail-followup-to:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=Op3moRbjYhsjbDcDIGxabNze9TBnhI+Sx/SlKViaMAk=; b=EVNV3Kf4LxpYivUE3cLu0RzRwLUvS+lyWRL+YtfhvBPXd8FPGwV2Di39Hon+B5sdQ4 GvCobKfVI1lS0+IJDRZhFRntsDFBhv2aTSTSo9kZPq3x8IErD+gADgdufsIuihy+5j60 5i/YIAuiOduLyFmK3UssUqtajxgHjl3ihTkk0= 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 :mail-followup-to:references:mime-version:content-disposition :content-transfer-encoding:in-reply-to:user-agent; bh=Op3moRbjYhsjbDcDIGxabNze9TBnhI+Sx/SlKViaMAk=; b=b35e/YEUjoLXSzqaF1DSzQ6knMoJ/JDhkY6dOkEP2cKjEt65oQG3LPNpDGOqXDfzx7 GJrW3TWxU16fjh3IzAPtl4sP3sxEwGW9hvORkdQCDFdGWSbyEKZbXJ3fzhGZ7M3tMbCQ lzo7qQeGYSrwBGgyOlnlmc8dQ4q+bn0WTABrJCxJIWrt/KjxDiaCuhHJWs8RJFD21dr0 YhqZ6TnwkxcSYPCsqRcAcwHYTlgZrmBsN6K2L7mxpBM//vb4xPnbx+kiwS21or2keKZn hsXmIe5QMCw2CjC356Dz9WaU1VHf18sjKWYvBr4tGjJxGiOSdvO+faxA28wW53WDQF8I cxow== X-Gm-Message-State: AJcUukf9rn2Yu8/8UJbpT20qEaDRLe0T8RmMuM1yO+P10dLdZVih7aWL pD+77zpmQZBQ6LuFuqvyuhVQag== X-Received: by 2002:a2e:302:: with SMTP id 2-v6mr19683577ljd.137.1548166523570; Tue, 22 Jan 2019 06:15:23 -0800 (PST) Received: from khorivan (59-201-94-178.pool.ukrtel.net. [178.94.201.59]) by smtp.gmail.com with ESMTPSA id 185-v6sm24895ljj.49.2019.01.22.06.15.22 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 22 Jan 2019 06:15:22 -0800 (PST) Date: Tue, 22 Jan 2019 16:15:20 +0200 From: Ivan Khoronzhuk To: Florian Fainelli Cc: davem@davemloft.net, linux-omap@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, jiri@mellanox.com, andrew@lunn.ch, idosch@mellanox.com Subject: Re: [RFC PATCH net-next 2/5] net: 8021q: vlan_dev: add vid tag for uc and mc address lists Message-ID: <20190122141519.GA3009@khorivan> Mail-Followup-To: Florian Fainelli , davem@davemloft.net, linux-omap@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, jiri@mellanox.com, andrew@lunn.ch, idosch@mellanox.com References: <20181203184023.3430-1-ivan.khoronzhuk@linaro.org> <20181203184023.3430-3-ivan.khoronzhuk@linaro.org> <20181203235119.GF23230@khorivan> <35479973-2d2d-d673-f7ab-54d6369ce3d1@gmail.com> <20181204185720.GI23230@khorivan> <756cbb25-3062-91e8-0613-66bb887f937e@gmail.com> <20181205000450.GB3507@khorivan> <1dd05b34-e275-d67c-df30-e3694d90e9cc@gmail.com> <2d27812c-333f-7dd6-eb31-6fdc15300ae0@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <2d27812c-333f-7dd6-eb31-6fdc15300ae0@gmail.com> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 08, 2019 at 10:21:25AM -0800, Florian Fainelli wrote: >On 1/7/19 9:01 PM, Florian Fainelli wrote: >> Le 12/4/18 ? 4:04 PM, Ivan Khoronzhuk a ?crit?: >>> On Tue, Dec 04, 2018 at 11:49:27AM -0800, Florian Fainelli wrote: >>> >>> ... >>> >>>>> >>>>> I was thinking also about pinned list of vlans to the address, but in >>>>> this case this information also has to be synced by members of device >>>>> chain, >>>>> because it can be modified on any device level and it looks not very >>>>> friendly, >>>>> and at the end address space has addresses with pinned lists of vlans >>>>> with >>>>> their pointers. But keeping this stuff in sync is not simplest decision. >>>>> >>>>> >>>> >>>> I really think we are not communicating properly, it really seems to me >>>> that if you had the information about the upper device trying to add an >>>> address to the lower device filter's either through notification or call >>>> to ndo_set_rxmode, you could be solving your problems. What are we >>>> missing here? >>> >>> Sry, missed this one. The problem in getting? the owner of address. >>> Just simple case: vlan/macvlan/real_dev or vlan/.../.../real_dev >>> >>> The real dev hasn't simple way to get vid the address belong to, or it has? >> >> Humm looks like your right, by the time the address lists are >> synchronized (e.g: from = vlan_dev, to = real_dev), we lost that >> information. It looks like I just managed to find such an use case >> myself with VLAN filtering enabled on a bridge (so switch is VLAN aware) >> and a VLAN device created on the bridge (br0.42) but with IGMP snooping >> turned off (so we don't get HOST_MDB notifications with correct VLAN ID). >> >> Maybe keeping the "from" net_device within the address list that is >> processed by ndo_set_rx_mode() will do the job though? >> >> Then you can do things like: >> >> if (is_vlan_dev(ha->dev) && ha->dev != dev) >> vid = vlan_dev_vlan_id(ha->dev); >> >> and it should scale to any type of stacked device, regardless of VID or >> something else that we need? >> >> Can you remind me of your use case again? Is it because your switch has >> VLAN filtering enabled and you need to make sure that MC addresses on >> VLAN device get programmed into the switch's multicast database with >> correct VID? > >Ivan, can you see if the following would work for you: > >https://github.com/ffainelli/linux/commit/19e173ebdcdd32f5f5b5ef29049e35d33ad058f2 > >this should be more scalable approach in that we can support HOST_MDB >notifications from the bridge, the same way we would get notified about >IGMP snooping from the bridge and this does not impact any other driver >than those that elect to receive switchdev object notifications, which >cpsw should really implement by now... Sorry missed 2 last comments and seems like it's clear now. I need to be in TO or CC list my filters can parse it, probably I need to create more smart filters. >-- >Florian -- Regards, Ivan Khoronzhuk