From patchwork Mon Mar 31 20:51:34 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nitin A Kamble X-Patchwork-Id: 3926081 Return-Path: X-Original-To: patchwork-ltsi-dev@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 6219FBF549 for ; Wed, 2 Apr 2014 00:29:46 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9FD72200ED for ; Wed, 2 Apr 2014 00:29:45 +0000 (UTC) Received: from mail.linuxfoundation.org (mail.linuxfoundation.org [140.211.169.12]) by mail.kernel.org (Postfix) with ESMTP id D411B200D5 for ; Wed, 2 Apr 2014 00:29:44 +0000 (UTC) Received: from mail.linux-foundation.org (localhost [IPv6:::1]) by mail.linuxfoundation.org (Postfix) with ESMTP id 06D43AF3; Wed, 2 Apr 2014 00:28:53 +0000 (UTC) X-Original-To: ltsi-dev@lists.linuxfoundation.org Delivered-To: ltsi-dev@mail.linuxfoundation.org Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTP id 5881595A for ; Mon, 31 Mar 2014 20:57:59 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by smtp1.linuxfoundation.org (Postfix) with ESMTP id 69A65202AE for ; Mon, 31 Mar 2014 20:57:58 +0000 (UTC) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga102.jf.intel.com with ESMTP; 31 Mar 2014 13:53:18 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.97,767,1389772800"; d="scan'208";a="503854411" Received: from yocto-hm1.jf.intel.com ([10.23.232.34]) by fmsmga001.fm.intel.com with ESMTP; 31 Mar 2014 13:57:56 -0700 From: nitin.a.kamble@intel.com To: bruce.ashfield@windriver.com, darren.hart@intel.com, adrian.hunter@intel.com, ltsi-dev@lists.linuxfoundation.org, gregkh@linuxfoundation.org Date: Mon, 31 Mar 2014 13:51:34 -0700 Message-Id: <4f05d51210800874cc706a6f657e297491891b41.1396297182.git.nitin.a.kamble@intel.com> X-Mailer: git-send-email 1.8.1.4 In-Reply-To: References: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Mailman-Approved-At: Wed, 02 Apr 2014 00:28:48 +0000 Cc: Nitin A Kamble Subject: [LTSI-dev] [PATCH 1/1] sdhci-pci.c: a fix for invalid memory access X-BeenThere: ltsi-dev@lists.linuxfoundation.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: "A list to discuss patches, development, and other things related to the LTSI project" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: ltsi-dev-bounces@lists.linuxfoundation.org Errors-To: ltsi-dev-bounces@lists.linuxfoundation.org X-Virus-Scanned: ClamAV using ClamSMTP From: Nitin A Kamble The chip->fixes pointer is assumed to be a valid data pointer, which is not always the case. Fox eaxample, this code was giving a kernel panic for emenlow BSP, because the chip->fixes pointer is NULL. The bug was introduced in the LTSI code by this patch: patches.baytrail/1193-PENDING-mmc-sdhci-pci-Fix-BYT-sd-card-getting-stuck-.patch From 8ba911fd25c8f41979533f6911f8221181fcefae Mon Sep 17 00:00:00 2001 From: Adrian Hunter Date: Fri, 13 Dec 2013 13:57:34 -0800 Subject: PENDING: mmc: sdhci-pci: Fix BYT sd card getting stuck in runtime suspend Signed-off-by: Nitin A Kamble --- 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 33593e7..b7c8e20 100644 --- a/drivers/mmc/host/sdhci-pci.c +++ b/drivers/mmc/host/sdhci-pci.c @@ -1389,7 +1389,7 @@ static struct sdhci_pci_slot *sdhci_pci_probe_slot( * from runtime suspend. If it is not there, don't allow runtime PM. * Note sdhci_pci_add_own_cd() sets slot->cd_gpio to -EINVAL on failure. */ - if (chip->fixes->own_cd_for_runtime_pm && !gpio_is_valid(slot->cd_gpio)) + if (chip->fixes && chip->fixes->own_cd_for_runtime_pm && !gpio_is_valid(slot->cd_gpio)) chip->allow_runtime_pm = false; return slot;