From: Jiri Slaby <jslaby@suse.cz>
To: Haibo Chen <haibo.chen@freescale.com>, ulf.hansson@linaro.org
Cc: adrian.hunter@intel.com, aisheng.dong@freescale.com,
shawn.guo@linaro.org, stable@vger.kernel.org,
linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] mmc: sdhci: fix dma memory leak in sdhci_pre_req()
Date: Fri, 7 Aug 2015 11:34:31 +0200 [thread overview]
Message-ID: <55C47BA7.1050500@suse.cz> (raw)
In-Reply-To: <1438939790-28310-1-git-send-email-haibo.chen@freescale.com>
On 08/07/2015, 11:29 AM, Haibo Chen wrote:
> Currently one mrq->data maybe execute dma_map_sg() twice
> when mmc subsystem prepare over one new request, and the
> following log show up:
> sdhci[sdhci_pre_dma_transfer] invalid cookie: 24, next-cookie 25
Thanks, I will test it shortly.
> @@ -2157,16 +2147,10 @@ static void sdhci_pre_req(struct mmc_host *mmc, struct mmc_request *mrq,
> {
> struct sdhci_host *host = mmc_priv(mmc);
>
> - if (mrq->data->host_cookie) {
> - mrq->data->host_cookie = 0;
> - return;
> - }
> + mrq->data->host_cookie = COOKIE_UNMAPPED;
Just one question. Should we warn if host_cookie != COOKIE_UNMAPPED
instead of the assignment? In other words, if the assignment is
mandatory, it deserves a comment why.
thanks,
--
js
suse labs
next prev parent reply other threads:[~2015-08-07 9:34 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-07 9:29 [PATCH] mmc: sdhci: fix dma memory leak in sdhci_pre_req() Haibo Chen
2015-08-07 9:34 ` Jiri Slaby [this message]
2015-08-07 11:05 ` Jiri Slaby
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=55C47BA7.1050500@suse.cz \
--to=jslaby@suse.cz \
--cc=adrian.hunter@intel.com \
--cc=aisheng.dong@freescale.com \
--cc=haibo.chen@freescale.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mmc@vger.kernel.org \
--cc=shawn.guo@linaro.org \
--cc=stable@vger.kernel.org \
--cc=ulf.hansson@linaro.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 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).