From patchwork Mon Oct 15 16:05:07 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Venkatraman S X-Patchwork-Id: 1594561 Return-Path: X-Original-To: patchwork-linux-mmc@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id DAAA2DFB34 for ; Mon, 15 Oct 2012 16:05:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753113Ab2JOQFZ (ORCPT ); Mon, 15 Oct 2012 12:05:25 -0400 Received: from devils.ext.ti.com ([198.47.26.153]:54152 "EHLO devils.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752994Ab2JOQFX (ORCPT ); Mon, 15 Oct 2012 12:05:23 -0400 Received: from dlelxv30.itg.ti.com ([172.17.2.17]) by devils.ext.ti.com (8.13.7/8.13.7) with ESMTP id q9FG5LHj023033; Mon, 15 Oct 2012 11:05:21 -0500 Received: from DFLE73.ent.ti.com (dfle73.ent.ti.com [128.247.5.110]) by dlelxv30.itg.ti.com (8.13.8/8.13.8) with ESMTP id q9FG5LVt015136; Mon, 15 Oct 2012 11:05:21 -0500 Received: from dlelxv23.itg.ti.com (172.17.1.198) by dfle73.ent.ti.com (128.247.5.110) with Microsoft SMTP Server id 14.1.323.3; Mon, 15 Oct 2012 11:05:21 -0500 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dlelxv23.itg.ti.com (8.13.8/8.13.8) with ESMTP id q9FG5L1S001643; Mon, 15 Oct 2012 11:05:21 -0500 Received: from localhost (ltuba0393540.apr.dhcp.ti.com [172.24.136.231]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id q9FG5Jw03008; Mon, 15 Oct 2012 11:05:19 -0500 (CDT) From: Venkatraman S To: , CC: , Balaji T K , Venkatraman S Subject: [PATCH 3/4] mmc: omap_hsmmc: fix host reference after mmc_free_host Date: Mon, 15 Oct 2012 21:35:07 +0530 Message-ID: <1350317108-10657-3-git-send-email-svenkatr@ti.com> X-Mailer: git-send-email 1.7.11.1.25.g0e18bef In-Reply-To: <1350317108-10657-1-git-send-email-svenkatr@ti.com> References: <1350317108-10657-1-git-send-email-svenkatr@ti.com> MIME-Version: 1.0 Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org From: Balaji T K struct omap_hsmmc_host *host should not be accessed after mmc_free_host(). Reorder mmc_free_host() after iounmap(host->base). Signed-off-by: Balaji T K Signed-off-by: Venkatraman S --- drivers/mmc/host/omap_hsmmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c index a33ab74..a3929b7 100644 --- a/drivers/mmc/host/omap_hsmmc.c +++ b/drivers/mmc/host/omap_hsmmc.c @@ -2019,8 +2019,8 @@ static int __devexit omap_hsmmc_remove(struct platform_device *pdev) clk_put(host->dbclk); } - mmc_free_host(host->mmc); iounmap(host->base); + mmc_free_host(host->mmc); omap_hsmmc_gpio_free(pdev->dev.platform_data); res = platform_get_resource(pdev, IORESOURCE_MEM, 0);