Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 270283
b: refs/heads/master
c: f7c56ef
h: refs/heads/master
i:
  270281: dcac87e
  270279: 4e87080
v: v3
  • Loading branch information
Adrian Hunter authored and Chris Ball committed Oct 26, 2011
1 parent e633cde commit 7ee6fac
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0d7d85ca6e5dc7bd426d1d5989a44e93e8c7a0d3
refs/heads/master: f7c56ef2af5ae7e4c24c3c79427b38d18ba1d294
2 changes: 1 addition & 1 deletion trunk/drivers/mmc/card/block.c
Original file line number Diff line number Diff line change
Expand Up @@ -1480,7 +1480,7 @@ static int mmc_blk_alloc_parts(struct mmc_card *card, struct mmc_blk_data *md)
if (!mmc_card_mmc(card))
return 0;

if (card->ext_csd.boot_size) {
if (card->ext_csd.boot_size && mmc_boot_partition_access(card->host)) {
ret = mmc_blk_alloc_part(card, md, EXT_CSD_PART_CONFIG_ACC_BOOT0,
card->ext_csd.boot_size >> 9,
true,
Expand Down
2 changes: 2 additions & 0 deletions trunk/drivers/mmc/host/sdhci-pci.c
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,8 @@ static int mfd_emmc_probe_slot(struct sdhci_pci_slot *slot)

slot->host->mmc->caps |= MMC_CAP_8_BIT_DATA;

slot->host->mmc->caps2 = MMC_CAP2_BOOTPART_NOACC;

return 0;
}

Expand Down
10 changes: 10 additions & 0 deletions trunk/include/linux/mmc/host.h
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,10 @@ struct mmc_host {
#define MMC_CAP_CMD23 (1 << 30) /* CMD23 supported. */
#define MMC_CAP_HW_RESET (1 << 31) /* Hardware reset */

unsigned int caps2; /* More host capabilities */

#define MMC_CAP2_BOOTPART_NOACC (1 << 0) /* Boot partition no access */

mmc_pm_flag_t pm_caps; /* supported pm features */

#ifdef CONFIG_MMC_CLKGATE
Expand Down Expand Up @@ -404,4 +408,10 @@ static inline int mmc_host_cmd23(struct mmc_host *host)
{
return host->caps & MMC_CAP_CMD23;
}

static inline int mmc_boot_partition_access(struct mmc_host *host)
{
return !(host->caps2 & MMC_CAP2_BOOTPART_NOACC);
}

#endif /* LINUX_MMC_HOST_H */

0 comments on commit 7ee6fac

Please sign in to comment.