All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Maydell <peter.maydell@linaro.org>
To: P J P <ppandit@redhat.com>
Cc: Qemu Developers <qemu-devel@nongnu.org>,
	Jiang Xin <jiangxin1@huawei.com>,
	Prasad J Pandit <pjp@fedoraproject.org>
Subject: Re: [Qemu-devel] [PATCH] dma: omap: check dma channel data_type
Date: Fri, 27 Jan 2017 15:08:02 +0000	[thread overview]
Message-ID: <CAFEAcA-2eZdd6jwQtAOYx0rmLzSzgcLBu8p7YUawtJg4hH-U3g@mail.gmail.com> (raw)
In-Reply-To: <20170127120528.30959-1-ppandit@redhat.com>

On 27 January 2017 at 12:05, P J P <ppandit@redhat.com> wrote:
> From: Prasad J Pandit <pjp@fedoraproject.org>
>
> When setting dma channel 'data_type', if (value & 3) == 3,
> the set 'data_type' is said to be bad. This also leads to an
> OOB access in 'omap_dma_transfer_generic', while doing
> cpu_physical_memory_r/w operations. Add check to avoid it.
>
> Reported-by: Jiang Xin <jiangxin1@huawei.com>
> Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>

The data sheet just says the behaviour with value == 3
is "undefined", so I guess this is as good a way as
any other to handle it.

Applied to target-arm.next, thanks.

-- PMM

      reply	other threads:[~2017-01-27 15:08 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-27 12:05 [Qemu-devel] [PATCH] dma: omap: check dma channel data_type P J P
2017-01-27 15:08 ` Peter Maydell [this message]

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-2eZdd6jwQtAOYx0rmLzSzgcLBu8p7YUawtJg4hH-U3g@mail.gmail.com \
    --to=peter.maydell@linaro.org \
    --cc=jiangxin1@huawei.com \
    --cc=pjp@fedoraproject.org \
    --cc=ppandit@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.