Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752989AbdCKHsF (ORCPT ); Sat, 11 Mar 2017 02:48:05 -0500 Received: from Galois.linutronix.de ([146.0.238.70]:60557 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750922AbdCKHsA (ORCPT ); Sat, 11 Mar 2017 02:48:00 -0500 Date: Sat, 11 Mar 2017 08:47:37 +0100 (CET) From: Thomas Gleixner To: "Luck, Tony" cc: Shivappa Vikas , Shivappa Vikas , linux-kernel@vger.kernel.org, x86@kernel.org, hpa@zytor.com, mingo@kernel.org, peterz@infradead.org, ravi.v.shankar@intel.com, fenghua.yu@intel.com, andi.kleen@intel.com Subject: Re: [PATCH 2/5] x86/intel_rdt: Improvements to parsing schemata In-Reply-To: <20170310220550.GA22430@intel.com> Message-ID: References: <1487360328-6768-1-git-send-email-vikas.shivappa@linux.intel.com> <1487360328-6768-3-git-send-email-vikas.shivappa@linux.intel.com> <20170310220550.GA22430@intel.com> User-Agent: Alpine 2.20 (DEB 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: 1359 Lines: 49 On Fri, 10 Mar 2017, Luck, Tony wrote: > On Fri, Mar 10, 2017 at 07:58:51PM +0100, Thomas Gleixner wrote: > > Well, we have several options to tackle this: > > > > 1) Have schemata files for each resource > > > > schemata_l2, _l3 _mb > > > > 2) Request a full overwrite every time (all entries required) > > > > That still does not require ordering > > > > 3) Allow full overwrite and 'append' mode > > > > echo "...." > schemata > > > > Overwrites the whole file. It does not require all entries to be > > supplied. Non supplied entries are reset to default > > > > echo "...." >> schemata > > > > "Appends" the supplied entries by overwriting the existing ones. > > > > My favourite would be #1, but I have no strong opinions other than not > > caring about resource write ordering for #2 and #3. > > If you are going to head in the direction of partial update, then > why not go for: > > 4) Drop the code that check that the user wrote all > the fields as well as the check for all the lines. Just update > the bits they list, and leave the rest unchanged. > > I.e. the user could say: > > # echo "L3:1=0x3f" > schemata > > if they just wanted to update resource L3, instance 1. Even better > I don't think there is much benefit to the overwrite vs. append > semantics for the user. Agreed. Thanks, tglx