From: Peter Maydell <peter.maydell@linaro.org>
To: Roy Franz <roy.franz@linaro.org>
Cc: Kevin Wolf <kwolf@redhat.com>,
QEMU Developers <qemu-devel@nongnu.org>,
Stefan Hajnoczi <stefanha@redhat.com>,
Patch Tracking <patches@linaro.org>
Subject: Re: [Qemu-devel] [PATCH V5 5/7] Add max device width parameter for NOR devices
Date: Thu, 12 Dec 2013 17:37:31 +0000 [thread overview]
Message-ID: <CAFEAcA-4VgQb4tW4H1YDqPe-unsGynf-h=ww8R+0FP_pFrFcEA@mail.gmail.com> (raw)
In-Reply-To: <CAFEAcA91c_YtNZmJm6+8-2pakZuYs5QnqtL3rp1ERJk5uNaq4w@mail.gmail.com>
On 12 December 2013 17:26, Peter Maydell <peter.maydell@linaro.org> wrote:
> On 5 December 2013 21:35, Roy Franz <roy.franz@linaro.org> wrote:
>> For handling CFI and device ID reads, we need to not only know the
>> width that a NOR flash device is configured for, but also its maximum
>> width. The maximum width addressing mode is used for multi-width
>> parts no matter which width they are configured for. The most common
>> case is x16 parts that also support x8 mode. When configured for x8
>> operation these devices respond to CFI and device ID requests differently
>> than native x8 NOR parts.
>
>> DEFINE_PROP_UINT64("sector-length", struct pflash_t, sector_len, 0),
>> DEFINE_PROP_UINT8("width", struct pflash_t, bank_width, 0),
>> DEFINE_PROP_UINT8("device-width", struct pflash_t, device_width, 0),
>> + DEFINE_PROP_UINT8("max-device-width", struct pflash_t, max_device_width, 0),
>
> So I think that given we now have three width related properties
> we could use a comment here about what they mean. Do I have
> this right?
>
> /* width here is the overall width of this QEMU device in bytes.
> * The QEMU device may be emulating a number of flash devices
> * wired up in parallel; the width of each individual flash
> * device should be specified via device-width. If the individual
> * devices have a maximum width which is greater than the width
> * they are being used for, this maximum width should be set via
> * max-device-width (which otherwise defaults to device-width).
> * So for instance a 32-bit wide QEMU flash device made from four
> * 16-bit flash devices used in 8-bit wide mode would be configured
> * with width = 4, device-width = 1, max-device-width = 2.
> *
> * If device-width is not specified we default to backwards
> * compatible behaviour which is a bad emulation of two
> * 16 bit devices making up a 32 bit wide QEMU device. This
> * is deprecated for new uses of this device.
> */
PS: if you're happy that the comment above is correct, I
can just add it locally (and fix up the format nits in
the other patch), to save you having to respin the series,
and stick it in the target-arm.next queue.
thanks
-- PMM
next prev parent reply other threads:[~2013-12-12 17:38 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-12-05 21:35 [Qemu-devel] [PATCH V5 0/7] block, arm: Fix buffered flash writes on VExpress Roy Franz
2013-12-05 21:35 ` [Qemu-devel] [PATCH V5 1/7] rename pflash_t member width to bank_width Roy Franz
2013-12-05 21:35 ` [Qemu-devel] [PATCH V5 2/7] Add device-width property to pflash_cfi01 Roy Franz
2013-12-12 17:31 ` Peter Maydell
2013-12-05 21:35 ` [Qemu-devel] [PATCH V5 3/7] return status for each NOR flash device Roy Franz
2013-12-12 17:31 ` Peter Maydell
2013-12-05 21:35 ` [Qemu-devel] [PATCH V5 4/7] Set proper device-width for vexpress flash Roy Franz
2013-12-12 17:32 ` Peter Maydell
2013-12-05 21:35 ` [Qemu-devel] [PATCH V5 5/7] Add max device width parameter for NOR devices Roy Franz
2013-12-12 17:26 ` Peter Maydell
2013-12-12 17:37 ` Peter Maydell [this message]
2013-12-12 20:08 ` Roy Franz
2013-12-05 21:35 ` [Qemu-devel] [PATCH V5 6/7] Fix CFI query responses for NOR flash Roy Franz
2013-12-12 17:33 ` Peter Maydell
2013-12-05 21:35 ` [Qemu-devel] [PATCH V5 7/7] Fix NOR flash device ID reading Roy Franz
2013-12-12 17:35 ` Peter Maydell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAFEAcA-4VgQb4tW4H1YDqPe-unsGynf-h=ww8R+0FP_pFrFcEA@mail.gmail.com' \
--to=peter.maydell@linaro.org \
--cc=kwolf@redhat.com \
--cc=patches@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=roy.franz@linaro.org \
--cc=stefanha@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).