public inbox for linux-mmc@vger.kernel.org
 help / color / mirror / Atom feed
From: Yasushi SHOJI <yashi@atmark-techno.com>
To: wsa-dev@sang-engineering.com
Cc: ulf.hansson@linaro.org, linux-mmc@vger.kernel.org,
	wsa+renesas@sang-engineering.com, horms@verge.net.au,
	linux-renesas-soc@vger.kernel.org
Subject: Re: mmc: tmio: why enable/disable SDIO irq on every transaction with IOMOD?
Date: Thu, 01 Dec 2016 21:46:50 +0900	[thread overview]
Message-ID: <87y3zzvmth.wl@dns1.atmark-techno.com> (raw)
In-Reply-To: <20161201104622.GA1541@katana>

Hi Wolfram,

On Thu, 01 Dec 2016 19:46:22 +0900,
Wolfram Sang wrote:
> 
> > > So my question is that "What is the reason behind to disable IRQ with
> > > SDIO_MODE?  Is there any situation which masking with SDIO_INFO1_MASK
> > > is not enough?
> 
> The code was introduced with 845ecd20239c28 ("mmc: tmio_mmc: implement
> SDIO IRQ support") which was in 2010. I don't have that old datasheets
> to check if the SCLKDIVEN restriction was already present in the SDHI
> cores which were available back then.

Is Arnd Hannemann, the author, around these days by any chance?

Or does anyone on the list have a shareable old datasheet?  The one we
have is the one for R-Mobile A1 and has CONFIDENTIAL on it.

> My assumption is that it was not, or it was overlooked. So, it might be
> just for completeness that not only the individual IRQs have been
> disabled but also the big master switch (IOMOD) was turned off.
> 
> My further assumption is that it is very likely good enough to disable
> the individual IRQs. If we can't guarantee the conditions to set IOMOD,
> it seems okay to me to just leave it.

Yes that's what we think and what we see with our test code, which is
just the original without IOMOD removed.

> Do you have a patch which works for you?

We don't have it yet.  A question we have is that where should we
enable / disable the IOMOD?

Do we have to keep it disabled while the controller is in non-SDIO?
The spec says that we don't get SDIO irq while in non-SDIO mode.  But
should we trust?

Or, should we disable it when we switch back to non-SDIO mode and
enable when we detect SDIO?

Please enlighten us this area.  We'll submit the proper fix once we
know how we should do it.

Thanks,
-- 
            yashi

  reply	other threads:[~2016-12-01 12:46 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-29  6:23 mmc: tmio: why enable/disable SDIO irq on every transaction with IOMOD? Yasushi SHOJI
2016-11-29  8:52 ` Ulf Hansson
2016-12-01 10:46   ` Wolfram Sang
2016-12-01 12:46     ` Yasushi SHOJI [this message]
2016-12-01 14:49       ` Wolfram Sang

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=87y3zzvmth.wl@dns1.atmark-techno.com \
    --to=yashi@atmark-techno.com \
    --cc=horms@verge.net.au \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=ulf.hansson@linaro.org \
    --cc=wsa+renesas@sang-engineering.com \
    --cc=wsa-dev@sang-engineering.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