Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754816AbdGSSuR (ORCPT ); Wed, 19 Jul 2017 14:50:17 -0400 Received: from mx2.suse.de ([195.135.220.15]:35815 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753945AbdGSSuQ (ORCPT ); Wed, 19 Jul 2017 14:50:16 -0400 Date: Wed, 19 Jul 2017 20:50:14 +0200 (CEST) From: Miroslav Benes To: Petr Mladek cc: Joe Lawrence , Josh Poimboeuf , live-patching@vger.kernel.org, linux-kernel@vger.kernel.org, Jessica Yu , Jiri Kosina Subject: Re: [PATCH v2 1/2] livepatch: introduce shadow variable API In-Reply-To: <20170719151951.GL32632@pathway.suse.cz> Message-ID: References: <1498664247-12296-1-git-send-email-joe.lawrence@redhat.com> <1498664247-12296-2-git-send-email-joe.lawrence@redhat.com> <20170714004149.6jgg4vxmjsotlkus@treble> <20170718130047.GG3393@pathway.suse.cz> <20170718193627.bzfgprzjjenvcgmc@redhat.com> <20170719151951.GL32632@pathway.suse.cz> User-Agent: Alpine 2.20 (LSU 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1895 Lines: 56 On Wed, 19 Jul 2017, Petr Mladek wrote: > On Tue 2017-07-18 15:36:27, Joe Lawrence wrote: > > Who knew naming things was so difficult :) > > > > There's been a bunch of feedback on terminology, so I'll just issue a > > collective reply to Petr's last msg on the topic. These were my > > thoughts on naming clarification: > > > > v1,v2 v3 > > -------------------------------------------------------------- > > obj, original data obj, parent object > > num, numerical description of new data id, data identifier > > new_data data > > new_size data_size > > IMHO, "size" might be enough in the context when it is used. I agree. > > > > Miroslav also suggested additional text explaining the id / data > > identifier field. How about something like this: > > > > --- > > > > ================ > > Shadow Variables > > ================ > > > > ... > > > > A global, in-kernel hashtable associates parent pointers and a numeric > > identifier with shadow variable data. > > I would slightly reformulate the above sentece: > > A global, in-kernel hashtable associates pointers to parent objects > and a numeric identifier of the shadow data. > > > Specifically, the parent pointer > > serves as the hashtable key, while the numeric id further filters > > hashtable queries. The numeric identifier is a simple enumeration that > > may be used to describe shadow variable versions (for stacking > > livepatches), class or type (for multiple shadow variables per parent), > > etc. Multiple shadow variables may attach to the same parent object, > > but their numeric identifier distinguises between them. s/distinguises/distinguishes/ > Sounds good to me. Yes, thanks for the paragraph. It sounds good combined with Petr's proposal. Miroslav