From patchwork Wed Mar 30 12:35:13 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dimitris Papastamos X-Patchwork-Id: 674012 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 p2UCZMOf032455 for ; Wed, 30 Mar 2011 12:35:23 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754910Ab1C3MfR (ORCPT ); Wed, 30 Mar 2011 08:35:17 -0400 Received: from opensource.wolfsonmicro.com ([80.75.67.52]:55722 "EHLO opensource2.wolfsonmicro.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751681Ab1C3MfR (ORCPT ); Wed, 30 Mar 2011 08:35:17 -0400 Received: from localhost (unknown [87.246.78.26]) by opensource2.wolfsonmicro.com (Postfix) with ESMTPSA id 9015511011F; Wed, 30 Mar 2011 13:35:15 +0100 (BST) From: Dimitris Papastamos To: Chris Ball Cc: linux-mmc@vger.kernel.org, Ben Dooks , Mark Brown Subject: [PATCH 1/2] MMC: SDHCI: Check mrq->cmd in sdhci_tasklet_finish Date: Wed, 30 Mar 2011 13:35:13 +0100 Message-Id: <1301488514-20963-1-git-send-email-dp@opensource.wolfsonmicro.com> X-Mailer: git-send-email 1.7.4.2 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]); Wed, 30 Mar 2011 12:35:23 +0000 (UTC) diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c index 79ebc39..e75d070 100644 --- a/drivers/mmc/host/sdhci.c +++ b/drivers/mmc/host/sdhci.c @@ -1341,7 +1341,7 @@ static void sdhci_tasklet_finish(unsigned long param) * upon error conditions. */ if (!(host->flags & SDHCI_DEVICE_DEAD) && - (mrq->cmd->error || + ((mrq->cmd && mrq->cmd->error) || (mrq->data && (mrq->data->error || (mrq->data->stop && mrq->data->stop->error))) || (host->quirks & SDHCI_QUIRK_RESET_AFTER_REQUEST))) {