public inbox for linux-mmc@vger.kernel.org
 help / color / mirror / Atom feed
From: Chris Ball <cjb@laptop.org>
To: Markos Chandras <markos.chandras@imgtec.com>
Cc: linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org,
	Seungwon Jeon <tgih.jun@samsung.com>,
	Jaehoon Chung <jh80.chung@samsung.com>
Subject: Re: [PATCH 3/3] dw_mmc: Handle unaligned data submission correctly
Date: Fri, 22 Mar 2013 12:52:12 -0400	[thread overview]
Message-ID: <87vc8jml6r.fsf@octavius.laptop.org> (raw)
In-Reply-To: <1363085593-22214-3-git-send-email-markos.chandras@imgtec.com> (Markos Chandras's message of "Tue, 12 Mar 2013 10:53:13 +0000")

Hi,

On Tue, Mar 12 2013, Markos Chandras wrote:
> Commit f9c2a0dc42a6938ff2a80e55ca2bbd1d5581c72e
> "mmc: dw_mmc: Fix PIO mode with support of highmem" introduced
> a regression since v3.2 making the mmc_test hang on test #13
> with a "Data starvation by host timeout" interrupt.
>
> This is because, sg_mapping_iter is used to iterate through the
> data which spans on multiple pages. The problem is detected on
> unaligned data submission where the code previously checked for
> !(sg_next(host->sg)) which is true because we only have a single
> scatter/gather list which then expands to multiple pages.
> Therefore, the driver incorrectly assumed that this was the last
> list item and submitted unaligned data to the mmc device. This
> overflowed the FIFO on the device before all the data were written
> to it. The code was fixed to only submit unaligned data when we are
> handling the last sg_miter item by checking whether we reached
> the desired data length or not.
>
> The patch was tested against mmc_test and all the tests passed.
>
> Signed-off-by: Markos Chandras <markos.chandras@imgtec.com>
> Cc: Seungwon Jeon <tgih.jun@samsung.com>
> Cc: Jaehoon Chung <jh80.chung@samsung.com>
> Cc: Chris Ball <cjb@laptop.org>

Thanks, pushed to mmc-next for 3.10.

- Chris.
-- 
Chris Ball   <cjb@laptop.org>   <http://printf.net/>
One Laptop Per Child

  reply	other threads:[~2013-03-22 16:52 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-12 10:53 [PATCH 1/3] dw_mmc: Don't loop when handling an interrupt Markos Chandras
2013-03-12 10:53 ` [PATCH 2/3] dw_mmc: Avoid adding the number of transmitted bytes twice Markos Chandras
2013-03-22 16:50   ` Chris Ball
2013-03-12 10:53 ` [PATCH 3/3] dw_mmc: Handle unaligned data submission correctly Markos Chandras
2013-03-22 16:52   ` Chris Ball [this message]
2013-03-13  8:31 ` [PATCH 1/3] dw_mmc: Don't loop when handling an interrupt Jaehoon Chung
2013-03-13 14:22 ` Seungwon Jeon
2013-03-13 14:26   ` Chris Ball
2013-03-13 14:27     ` Markos Chandras
2013-03-13 14:26   ` Markos Chandras

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=87vc8jml6r.fsf@octavius.laptop.org \
    --to=cjb@laptop.org \
    --cc=jh80.chung@samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=markos.chandras@imgtec.com \
    --cc=tgih.jun@samsung.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