Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1243126

Re: [PATCH v2] mmc: core: Fix init_card in 52Mhz

From Ulf Hansson <ulf.hansson@linaro.org>
Newsgroups linux.kernel
Subject Re: [PATCH v2] mmc: core: Fix init_card in 52Mhz
Date 2015-10-09 10:40 +0200
Message-ID <qhBnz-5g1-3@gated-at.bofh.it> (permalink)
References <qhduX-4Hx-29@gated-at.bofh.it> <qhh5v-1dD-3@gated-at.bofh.it> <qhj7k-4pv-3@gated-at.bofh.it> <qhjAm-4X0-13@gated-at.bofh.it> <qhAUy-4Iv-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


[...]

>>> Then you need to remove the hw_reset test from mmc_test.  Refer:
>>>
>>>         http://marc.info/?l=linux-mmc&m=144360165906544&w=2
>>>
>>
>> I realize that the test becomes a bit different, but I don't think it's useless.
>>
>> If we add a check for MMC_CAP_HW_RESET and verify that the
>> host->ops->hw_reset exists, then we can assume that the "hw_reset"
>> sequence has executed. And if mmc_init_card() fails, that would
>> probably mean that the reset also failed, right?
>
> In the test case, the card is in a working state.  Generally I would then
> expect reinitialization to work irrespective of whether or not the hardware
> is actually reset.

That's not always the case. I have seen many strange things happening
while trying to re-initialize/reset the card. :-)

>
> Here are some other options:
>         1. have mmc_test hook the host->ops->hw_reset() fn and do the send_status
> itself.
>         2. have mmc_test set a flag on the card that it is being tested
> and only do the send_status if the flag is set

I assume that both 1) and 2) still means we need to manage the
scenario with re-tuning, which I rather would like us to prevent.

Unless we find a way to call mmc_set_initial_state() before doing the
reset, as that would disable re-tuning...

>         3. remove the send_status call and rename the mmc_test from "eMMC hardware
> reset" to just "Reset test (doesn't check hw reset did reset)"

That's would work and perhaps this is the best way to go as we would
then also be able to use the test for SD-cards. Let's do this then!

Kind regards
Uffe
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

[PATCH v2] mmc: core: Fix init_card in 52Mhz Chaotian Jing <chaotian.jing@mediatek.com> - 2015-10-08 09:10 +0200
  Re: [PATCH v2] mmc: core: Fix init_card in 52Mhz Ulf Hansson <ulf.hansson@linaro.org> - 2015-10-08 13:00 +0200
    Re: [PATCH v2] mmc: core: Fix init_card in 52Mhz Adrian Hunter <adrian.hunter@intel.com> - 2015-10-08 15:10 +0200
      Re: [PATCH v2] mmc: core: Fix init_card in 52Mhz Ulf Hansson <ulf.hansson@linaro.org> - 2015-10-08 15:40 +0200
        Re: [PATCH v2] mmc: core: Fix init_card in 52Mhz Adrian Hunter <adrian.hunter@intel.com> - 2015-10-09 10:10 +0200
          Re: [PATCH v2] mmc: core: Fix init_card in 52Mhz Ulf Hansson <ulf.hansson@linaro.org> - 2015-10-09 10:40 +0200

csiph-web