diff mbox

mmc: sdhci-pci: fix 'Invalid iomem size' error message condition

Message ID 507FA7A7.4070100@intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Adrian Hunter Oct. 18, 2012, 6:54 a.m. UTC
The SDHCI standard defines a 256 byte register set but a device
that specifies a larger iomem region is not an error.  Alter the
message condition accordingly.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
---
 drivers/mmc/host/sdhci-pci.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Chris Ball Oct. 29, 2012, 9:13 p.m. UTC | #1
Hi,

On Thu, Oct 18 2012, Adrian Hunter wrote:
> The SDHCI standard defines a 256 byte register set but a device
> that specifies a larger iomem region is not an error.  Alter the
> message condition accordingly.
>
> Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
> ---
>  drivers/mmc/host/sdhci-pci.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mmc/host/sdhci-pci.c b/drivers/mmc/host/sdhci-pci.c
> index 4bb74b0..04936f3 100644
> --- a/drivers/mmc/host/sdhci-pci.c
> +++ b/drivers/mmc/host/sdhci-pci.c
> @@ -1196,7 +1196,7 @@ static struct sdhci_pci_slot * __devinit sdhci_pci_probe_slot(
>  		return ERR_PTR(-ENODEV);
>  	}
>  
> -	if (pci_resource_len(pdev, bar) != 0x100) {
> +	if (pci_resource_len(pdev, bar) < 0x100) {
>  		dev_err(&pdev->dev, "Invalid iomem size. You may "
>  			"experience problems.\n");
>  	}

Thanks, pushed to mmc-next for 3.8.

- Chris.
diff mbox

Patch

diff --git a/drivers/mmc/host/sdhci-pci.c b/drivers/mmc/host/sdhci-pci.c
index 4bb74b0..04936f3 100644
--- a/drivers/mmc/host/sdhci-pci.c
+++ b/drivers/mmc/host/sdhci-pci.c
@@ -1196,7 +1196,7 @@  static struct sdhci_pci_slot * __devinit sdhci_pci_probe_slot(
 		return ERR_PTR(-ENODEV);
 	}
 
-	if (pci_resource_len(pdev, bar) != 0x100) {
+	if (pci_resource_len(pdev, bar) < 0x100) {
 		dev_err(&pdev->dev, "Invalid iomem size. You may "
 			"experience problems.\n");
 	}