From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Mon, 27 Jun 2016 05:55:45 +0200 From: Linus =?utf-8?Q?L=C3=BCssing?= Message-ID: <20160627035545.GO4407@otheros> References: <1466982121-3504-1-git-send-email-sven@narfation.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <1466982121-3504-1-git-send-email-sven@narfation.org> Subject: Re: [B.A.T.M.A.N.] [PATCH v2] batman-adv: Remove orig_node reference handling from send_skb_unicast List-Id: The list for a Better Approach To Mobile Ad-hoc Networking List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: The list for a Better Approach To Mobile Ad-hoc Networking On Mon, Jun 27, 2016 at 01:02:01AM +0200, Sven Eckelmann wrote: > The function batadv_send_skb_unicast is not acquiring a reference for an > orig_node nor removing it from any datastructure. It still reduces the > reference counter for an object which is still in the hands of the caller. > > This is confusing and can lead to problems in the reference handling in the > caller function. > > Signed-off-by: Sven Eckelmann > --- I like it, indeed easier to read, especially for the multicast part. Maybe make it a "This is confusing and could lead to ... in the future." to avoid people misreading it as a fix? > diff --git a/net/batman-adv/send.c b/net/batman-adv/send.c > index 729deec..44be408 100644 > --- a/net/batman-adv/send.c > +++ b/net/batman-adv/send.c > @@ -362,8 +362,6 @@ int batadv_send_skb_unicast(struct batadv_priv *bat_priv, The kernel doc of batadv_send_skb_unicast seems to need an update, too ("s/ and release a reference to this orig_node//").