Re: [PATCH] mmc: sdio: reset card during power_restore

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jun 29, 2011 at 11:43 AM, zhangfei gao <zhangfei.gao@xxxxxxxxx> wrote:
> However still not fully understand how to call ->remove to power off
> wlan, using suspend system looks to me is only test method, which
> counting on bus_ops->suspend returns -ENOSYS.

Please take a look at mac80211 and wl12xx.

We're not using ->remove, ->probe or -ENOSYS at all.

When the user brings up the interface, we then power up the chip and
download the firmware.
Likewise, when the interface is brought down, we just power off the chip.

> 2. Explicitly call mmc_detect_change,
> when power off, mmc_rescan -> bus_ops->detect(host) -> mmc_select_card
> fail -> mmc_sdio_remove;
> when power on, mmc_rescan ->  mmc_attach_sdio->wlan probe.

This is awkward. Basically what you're saying is that your driver can
only power on the chip when it is probed.

IMHO you need to refactor your driver, so it will power on/off the
device according to interface status changes, without requiring the
system to remove and re-detect the device.
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux