From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46757) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VXAlz-0001kf-Fs for qemu-devel@nongnu.org; Fri, 18 Oct 2013 10:11:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VXAlu-0008L5-Fa for qemu-devel@nongnu.org; Fri, 18 Oct 2013 10:11:27 -0400 Received: from mail-lb0-f172.google.com ([209.85.217.172]:62454) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VXAlu-0008L0-8J for qemu-devel@nongnu.org; Fri, 18 Oct 2013 10:11:22 -0400 Received: by mail-lb0-f172.google.com with SMTP id c11so2712408lbj.3 for ; Fri, 18 Oct 2013 07:11:21 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: References: <1382063402-30359-1-git-send-email-roy.franz@linaro.org> <20131018113847.GA17031@stefanha-thinkpad.redhat.com> From: Peter Maydell Date: Fri, 18 Oct 2013 15:11:00 +0100 Message-ID: Content-Type: text/plain; charset=UTF-8 Subject: Re: [Qemu-devel] [PATCH] block: mask NOR flash buffered write length List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Roy Franz Cc: Kevin Wolf , Stefan Hajnoczi , QEMU Developers , Stefan Hajnoczi , Patch Tracking On 18 October 2013 15:05, Roy Franz wrote: > On Fri, Oct 18, 2013 at 7:01 AM, Peter Maydell wrote: >> Yes, you should make the default for the device-width property >> be to be the same as the bank-width, since that's what we >> currently implement; then we can just change the platforms >> where we know that's wrong. >> >> NB: probably best to leave the existing 'width' property with >> the name it has, rather than renaming it to 'bank-width'. > Thanks Peter. I'm not familiar with the "properties" and how they are > used. I think that > the device width is likely only of interest internally, so I won't add > a device-width property. No, you need to add a property. Properties are how all configurable device parameters are set: if you look at the implementation of the pflash_cfi01_register() function you'll see that it's just a convenience wrapper that creates the device and sets a lot of properties on it. device-width should be one of those, in the same way as the existing width property. In fact I would suggest that you don't change the utility pflash_cfi01_register() function to add a new parameter to it (that would involve editing every caller). Instead just opencode the "create / set properties / init / map" sequence in vexpress.c. I think that will actually be easier to read since you don't have to match up each unnamed argument in a long function call with what it actually does. -- PMM