From patchwork Thu Mar 17 18:08:45 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergei Shtylyov X-Patchwork-Id: 641811 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p2HIANsT021097 for ; Thu, 17 Mar 2011 18:10:25 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755057Ab1CQSKX (ORCPT ); Thu, 17 Mar 2011 14:10:23 -0400 Received: from mail.dev.rtsoft.ru ([213.79.90.226]:56752 "HELO mail.dev.rtsoft.ru" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1754935Ab1CQSKW (ORCPT ); Thu, 17 Mar 2011 14:10:22 -0400 Received: (qmail 10777 invoked from network); 17 Mar 2011 18:10:18 -0000 Received: from unknown (HELO wasted.dev.rtsoft.ru) (192.168.1.70) by 0 with SMTP; 17 Mar 2011 18:10:18 -0000 To: linux-mmc@vger.kernel.org, cjb@laptop.org Subject: [PATCH] MMC: use pci_dev->revision Content-Disposition: inline From: Sergei Shtylyov Organization: MontaVista Software Inc. Cc: brucechang@via.com.tw, HaraldWelte@viatech.com Date: Thu, 17 Mar 2011 21:08:45 +0300 MIME-Version: 1.0 Message-Id: <201103172108.45989.sshtylyov@ru.mvista.com> Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Thu, 17 Mar 2011 18:10:25 +0000 (UTC) Index: linux-2.6/drivers/mmc/host/sdhci-pci.c =================================================================== --- linux-2.6.orig/drivers/mmc/host/sdhci-pci.c +++ linux-2.6/drivers/mmc/host/sdhci-pci.c @@ -1012,16 +1012,14 @@ static int __devinit sdhci_pci_probe(str struct sdhci_pci_chip *chip; struct sdhci_pci_slot *slot; - u8 slots, rev, first_bar; + u8 slots, first_bar; int ret, i; BUG_ON(pdev == NULL); BUG_ON(ent == NULL); - pci_read_config_byte(pdev, PCI_CLASS_REVISION, &rev); - dev_info(&pdev->dev, "SDHCI controller found [%04x:%04x] (rev %x)\n", - (int)pdev->vendor, (int)pdev->device, (int)rev); + (int)pdev->vendor, (int)pdev->device, (int)pdev->revision); ret = pci_read_config_byte(pdev, PCI_SLOT_INFO, &slots); if (ret) Index: linux-2.6/drivers/mmc/host/via-sdmmc.c =================================================================== --- linux-2.6.orig/drivers/mmc/host/via-sdmmc.c +++ linux-2.6/drivers/mmc/host/via-sdmmc.c @@ -1090,14 +1090,13 @@ static int __devinit via_sd_probe(struct struct mmc_host *mmc; struct via_crdr_mmc_host *sdhost; u32 base, len; - u8 rev, gatt; + u8 gatt; int ret; - pci_read_config_byte(pcidev, PCI_CLASS_REVISION, &rev); pr_info(DRV_NAME ": VIA SDMMC controller found at %s [%04x:%04x] (rev %x)\n", pci_name(pcidev), (int)pcidev->vendor, (int)pcidev->device, - (int)rev); + (int)pcidev->revision); ret = pci_enable_device(pcidev); if (ret)