On 18 October 2013 15:05, Roy Franz <roy.fr...@linaro.org> wrote: > On Fri, Oct 18, 2013 at 7:01 AM, Peter Maydell <peter.mayd...@linaro.org> > 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