mmc: refactor bus operations

Move bus operations to its own file for the sake of clarity. Also
delegate sysfs attributes to bus handlers in preparation for other
more exotic types.

Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
This commit is contained in:
Pierre Ossman
2007-05-19 13:39:01 +02:00
parent 7de064ebc6
commit 4101c16a91
9 changed files with 418 additions and 244 deletions

View File

@@ -368,22 +368,6 @@ void mmc_set_timing(struct mmc_host *host, unsigned int timing)
mmc_set_ios(host);
}
/*
* Allocate a new MMC card
*/
struct mmc_card *mmc_alloc_card(struct mmc_host *host)
{
struct mmc_card *card;
card = kmalloc(sizeof(struct mmc_card), GFP_KERNEL);
if (!card)
return ERR_PTR(-ENOMEM);
mmc_init_card(card, host);
return card;
}
/*
* Apply power to the MMC stack. This is a two-stage process.
* First, we enable power to the card without the clock running.