mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Andrey Smirnov <andrew.smirnov@gmail.com>
To: Sascha Hauer <s.hauer@pengutronix.de>
Cc: Barebox List <barebox@lists.infradead.org>
Subject: Re: [PATCH] ARM: lib64: Properly handle unaligned addresses in string functions
Date: Mon, 13 Aug 2018 07:16:38 -0700	[thread overview]
Message-ID: <CAHQ1cqGxbA5jpdSDznAFBeUpcdESnkxMabY9XQKMkXDGc+F5=g@mail.gmail.com> (raw)
In-Reply-To: <20180813064144.7ocirutuvzltrrmn@pengutronix.de>

On Sun, Aug 12, 2018 at 11:41 PM Sascha Hauer <s.hauer@pengutronix.de> wrote:
>
> On Fri, Aug 10, 2018 at 11:52:01AM -0700, Andrey Smirnov wrote:
> > Together FEC driver and parts of IP stack might end up trying to
> > memcpy() small chunks of memory from uncached (that is Device memory)
> > addresses that are not properly aligned, leading to data abort.
> >
> > To prevent such cases, add code to guard unaligned accesses and
> > redirect them to byte-wise implementations which do not have the above
> > problem.
>
> Please no. IMO this problem only shows that the FEC driver shouldn't use
> dma_alloc_coherent() to allocate its receive buffers, but instead should
> use dma_alloc + dma_sync_*.

OK, will work on that approach in v2.

Thanks,
Andrey Smirnov

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

      reply	other threads:[~2018-08-13 14:17 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-10 18:52 Andrey Smirnov
2018-08-13  6:41 ` Sascha Hauer
2018-08-13 14:16   ` Andrey Smirnov [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='CAHQ1cqGxbA5jpdSDznAFBeUpcdESnkxMabY9XQKMkXDGc+F5=g@mail.gmail.com' \
    --to=andrew.smirnov@gmail.com \
    --cc=barebox@lists.infradead.org \
    --cc=s.hauer@pengutronix.de \
    /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