From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Sat, 5 Jan 2019 16:03:38 +0100 From: Linus =?utf-8?Q?L=C3=BCssing?= Message-ID: <20190105150338.GP21623@otheros> References: <20181207135846.6152-1-sven@narfation.org> <20181207135846.6152-20-sven@narfation.org> <20190104022916.GI21623@otheros> <5023487.B7GbudR6Oe@sven-edge> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <5023487.B7GbudR6Oe@sven-edge> Subject: Re: [B.A.T.M.A.N.] [RFC v3 19/19] batman-adv: Trigger genl notification on sysfs config change List-Id: The list for a Better Approach To Mobile Ad-hoc Networking List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Sven Eckelmann Cc: b.a.t.m.a.n@lists.open-mesh.org, jiri@mellanox.com On Fri, Jan 04, 2019 at 08:58:32AM +0100, Sven Eckelmann wrote: > On Friday, 4 January 2019 03.29.16 CET Linus Lüssing wrote: > [...] > > I'm wondering, before it was quite easy to add new sysfs > > attributes with just a few lines thanks to macros. Now we > > need to add code in four more places in netlink.c whenever we introduce a > > new configuration option. > > > > Would it be possible (and maybe even reduce code size?) if the > > sysfs and netlink parts were wrapped into some (macro) functions and/or > > structs, to still be able to add options from a central place and with > > only a few lines? > > > > Or would that become too ugly? Or not worth the effort for the few > > options we have right now? > > You only need a couple of lines to add netlink things. And we don't want sysfs > anymore. So no need to add ugly hacks to add both netlink+sysfs with a "couple > of lines". > > Kind regards, > Sven Ok