From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Ahern Subject: Re: [PATCH iproute2 0/6] utils: Get rid of inet_get_addr() Date: Sun, 21 Jan 2018 11:13:11 -0700 Message-ID: <0e789c67-f4d9-e416-33c1-3e3230b4580c@gmail.com> References: <1516299227-26724-1-git-send-email-serhe.popovych@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit To: Serhey Popovych , netdev@vger.kernel.org Return-path: Received: from mail-pg0-f41.google.com ([74.125.83.41]:36983 "EHLO mail-pg0-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750853AbeAUSNS (ORCPT ); Sun, 21 Jan 2018 13:13:18 -0500 Received: by mail-pg0-f41.google.com with SMTP id z17so5298848pgc.4 for ; Sun, 21 Jan 2018 10:13:17 -0800 (PST) In-Reply-To: <1516299227-26724-1-git-send-email-serhe.popovych@gmail.com> Content-Language: en-US Sender: netdev-owner@vger.kernel.org List-ID: On 1/18/18 11:13 AM, Serhey Popovych wrote: > It looks confusing to have multiple independent > routines to get internet address from it's string > representation: get_addr() and inet_get_addr(). > > Most complicated users of inet_get_addr() is > iplink_geneve.c and iplink_vxlan.c because they > required to handle both AF_INET and AF_INET6 > for their local/remote endpoints. > > On the other hand get_addr() does not provide > additional information like address type: need > to address this. to get rid of current and > possible future code duplications. Note that > this functionality is first step to make proto > independent handling of local/remote endpoints > in ip/tunnel code (there will be additional > series based on this one). > > Also fix get_addr_1() and get_prefix() to make > sure it always provide correct ->family and > ->bitlen. > > As always comments, suggestions and criticism > are welcome. Series applied to iproute2-next. Thanks,