From: Venu Byravarasu <vbyravarasu@nvidia.com>
To: "dedekind1@gmail.com" <dedekind1@gmail.com>,
"Nicolas Ferre" <nicolas.ferre@atmel.com>,
"Voss, Nikolaus" <N.Voss@weinmann.de>,
"Eric Bénard" <eric@eukrea.com>
Cc: "'linux-mtd@lists.infradead.org'" <linux-mtd@lists.infradead.org>,
"'linux-kernel@vger.kernel.org'" <linux-kernel@vger.kernel.org>
Subject: RE: [PATCH] mtd: atmel_nand: fix access to 16 bit NAND devices
Date: Fri, 3 Feb 2012 09:05:29 +0530 [thread overview]
Message-ID: <D958900912E20642BCBC71664EFECE3E6DD0B99114@BGMAIL02.nvidia.com> (raw)
In-Reply-To: <1328184370.28171.175.camel@sauron.fi.intel.com>
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 691 bytes --]
I see a problem with atmel_read_buf16 & atmel_write_buf16 functions.
As they are calling __raw_readsw & __raw_writesw respectively, which
would cause panic in cases of 16 bit unaligned buffers.
However, the buf passed to these functions is of type u8* from
atmel_read_buf & atmel_write_buf functions.
[Venu]
> - /* if no DMA operation possible, use PIO */
> - memcpy_fromio(buf, chip->IO_ADDR_R, len);
> + if (host->board->bus_width_16)
> + atmel_read_buf16(mtd, buf, len);
> + else
> + atmel_read_buf8(mtd, buf, len);
> }
ÿôèº{.nÇ+·®+%Ëÿ±éݶ\x17¥wÿº{.nÇ+·¥{±þG«éÿ{ayº\x1dÊÚë,j\a¢f£¢·hïêÿêçz_è®\x03(éÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?¨èÚ&£ø§~á¶iOæ¬z·vØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?I¥
next prev parent reply other threads:[~2012-02-03 3:35 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-18 9:16 [PATCH] mtd: atmel_nand: fix access to 16 bit NAND devices Nikolaus Voss
2012-01-27 13:29 ` Artem Bityutskiy
2012-01-30 7:57 ` Voss, Nikolaus
2012-01-30 8:57 ` Nicolas Ferre
2012-02-01 10:43 ` Eric Bénard
2012-02-02 12:06 ` Artem Bityutskiy
2012-02-03 3:35 ` Venu Byravarasu [this message]
2012-02-03 5:32 ` Artem Bityutskiy
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=D958900912E20642BCBC71664EFECE3E6DD0B99114@BGMAIL02.nvidia.com \
--to=vbyravarasu@nvidia.com \
--cc=N.Voss@weinmann.de \
--cc=dedekind1@gmail.com \
--cc=eric@eukrea.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=nicolas.ferre@atmel.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).