From mboxrd@z Thu Jan 1 00:00:00 1970 From: Scott Feldman Subject: Re: [PATCH/RFC net-next] rocker: forward packets to CPU when a port in promiscuous mode Date: Wed, 15 Jul 2015 00:18:20 -0700 Message-ID: References: <1436415931-16469-1-git-send-email-simon.horman@netronome.com> <20150715044521.GA7603@vergenet.net> <20150715063453.GB7603@vergenet.net> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Cc: Jiri Pirko , Netdev , john fastabend To: Simon Horman Return-path: Received: from mail-ob0-f171.google.com ([209.85.214.171]:34199 "EHLO mail-ob0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751316AbbGOHSk (ORCPT ); Wed, 15 Jul 2015 03:18:40 -0400 Received: by obre1 with SMTP id e1so21072451obr.1 for ; Wed, 15 Jul 2015 00:18:39 -0700 (PDT) In-Reply-To: <20150715063453.GB7603@vergenet.net> Sender: netdev-owner@vger.kernel.org List-ID: On Tue, Jul 14, 2015 at 11:34 PM, Simon Horman wrote: > On Tue, Jul 14, 2015 at 10:32:54PM -0700, Scott Feldman wrote: >> > @@ -5263,11 +5301,16 @@ static int rocker_port_master_changed(struct net_device *dev) >> > * 3. Other, e.g. being added to or removed from a bond or openvswitch, >> > * in which case nothing is done >> > */ >> >> Maybe comment above needs adjusting? > > Indeed, sorry for missing that. > How about this? > > > /* There are currently five cases handled here: > * 1. Joining a bridge > * 2. Joining a Open vSwitch datapath > * 3. Leaving a previously joined bridge > * 4. Leaving a previously joined Open vSwitch datapath > * 5. Other, e.g. being added to or removed from a bond, > * in which case nothing is done > */ Seems like one of those comments that needs adjusting each time the code changes, which isn't good. Maybe just kill the comment or write in a generic way saying what code is doing. Code seems obvious enough to me to not require a comment.