From owner-dev-commits-src-main@freebsd.org Fri Mar 5 18:19:27 2021 Return-Path: Delivered-To: dev-commits-src-main@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 82FED5623FF; Fri, 5 Mar 2021 18:19:27 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4Dsbbz1Qbpz3FtS; Fri, 5 Mar 2021 18:19:26 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.16.1/8.16.1) with ESMTPS id 125IJHbM037030 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Fri, 5 Mar 2021 20:19:20 +0200 (EET) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua 125IJHbM037030 Received: (from kostik@localhost) by tom.home (8.16.1/8.16.1/Submit) id 125IJHhV037029; Fri, 5 Mar 2021 20:19:17 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Fri, 5 Mar 2021 20:19:17 +0200 From: Konstantin Belousov To: Ryan Moeller Cc: src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Subject: Re: git: c4ba4aa54718 - main - libifconfig: Overhaul ifconfig_media_* interfaces Message-ID: References: <202103051123.125BNubR059014@gitrepo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <202103051123.125BNubR059014@gitrepo.freebsd.org> X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FORGED_GMAIL_RCVD,FREEMAIL_FROM, NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on tom.home X-Rspamd-Queue-Id: 4Dsbbz1Qbpz3FtS X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-BeenThere: dev-commits-src-main@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Commit messages for the main branch of the src repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Mar 2021 18:19:27 -0000 On Fri, Mar 05, 2021 at 11:23:56AM +0000, Ryan Moeller wrote: > The branch main has been updated by freqlabs: > > URL: https://cgit.FreeBSD.org/src/commit/?id=c4ba4aa547184ab401204096cdad9def4ab37964 > > commit c4ba4aa547184ab401204096cdad9def4ab37964 > Author: Ryan Moeller > AuthorDate: 2021-03-02 10:29:17 +0000 > Commit: Ryan Moeller > CommitDate: 2021-03-05 09:15:55 +0000 > > libifconfig: Overhaul ifconfig_media_* interfaces > > Define an ifmedia_t type to use for ifmedia words. > > Add ifconfig_media_lookup_* functions to lookup ifmedia words by name. > > Get media options as an array of option names rather than formatting it > as a comma-delimited list into a buffer. > > Sprinkle const on static the static description tables for peace of > mind. > > Don't need to zero memory allocated by calloc. > > Reviewed by: kp > MFC after: 2 weeks > Differential Revision: https://reviews.freebsd.org/D29029 > --- > lib/libifconfig/Makefile | 2 +- > lib/libifconfig/Symbol.map | 9 +- > lib/libifconfig/libifconfig.h | 69 +++++++- > lib/libifconfig/libifconfig_media.c | 339 ++++++++++++++++++++++++------------ > share/examples/libifconfig/status.c | 27 ++- > 5 files changed, 324 insertions(+), 122 deletions(-) > > diff --git a/lib/libifconfig/Makefile b/lib/libifconfig/Makefile > index 73dad36c1dc5..c6f006018427 100644 > --- a/lib/libifconfig/Makefile > +++ b/lib/libifconfig/Makefile > @@ -7,7 +7,7 @@ INTERNALLIB= true > LIBADD= m > > SHLIBDIR?= /lib > -SHLIB_MAJOR= 1 > +SHLIB_MAJOR= 2 > > VERSION_DEF= ${LIBCSRCDIR}/Versions.def > SYMBOL_MAPS= ${.CURDIR}/Symbol.map libifconfig is marked as internal, but we provide symbol versioning for it, and do it in the normal FreeBSD namespace. On one hand, our policy is to not bump symvered libs and to provide binary compat shims as needed, on the other, this is internal lib. What is the purpose of maintaining symbol versions for it?