From patchwork Fri Feb 4 11:17:54 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Will Newton X-Patchwork-Id: 531451 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 p14BH5FK030917 for ; Fri, 4 Feb 2011 11:17:56 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751512Ab1BDLR4 (ORCPT ); Fri, 4 Feb 2011 06:17:56 -0500 Received: from mail-bw0-f46.google.com ([209.85.214.46]:60945 "EHLO mail-bw0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751450Ab1BDLRz (ORCPT ); Fri, 4 Feb 2011 06:17:55 -0500 Received: by bwz15 with SMTP id 15so2595721bwz.19 for ; Fri, 04 Feb 2011 03:17:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=yQvu1i+OZsU2hrYgFjefNmRfbkrQ6kuE7SDJ4r6gilE=; b=UBoCbvm4h/CSVgzPVwXvsUXNLT+//r9f/6suw1E824YZWFBEzFV+ov15ZKxFiMe+Wh +lXdFO1KzPlTSmEnFFlaaRDSMZVfJ6MH5V5t6PQjb/RLFB4IT5BRGpVCMYXfK0ZF7iZg 1xjhrLbFNqOwAWzbrtP4QHLPLBAMJKK+U1GIs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=ti9ctLVtowaUJ5BuG3Vqabj9kDT8PXaqp5+tvXDwaN0OwHICC3dk9FTudNmk+vPODR ru1WKX4qqTrDMu9VzaW2opGquxazJ7FT1xetU0ELqUfBUUtwLkwnNTkJrm3nu3ssVFEu ZpJhKilBjvJ+867iKZN4TUt7BXwdFqARoxLyk= MIME-Version: 1.0 Received: by 10.204.114.148 with SMTP id e20mr11270476bkq.168.1296818274453; Fri, 04 Feb 2011 03:17:54 -0800 (PST) Received: by 10.204.75.70 with HTTP; Fri, 4 Feb 2011 03:17:54 -0800 (PST) Date: Fri, 4 Feb 2011 11:17:54 +0000 Message-ID: Subject: [PATCH 1/2] dw_mmc: Run card detect tasklet during slot initialisation. From: Will Newton To: linux-mmc@vger.kernel.org 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]); Fri, 04 Feb 2011 11:17:57 +0000 (UTC) From 53094aaa4cd8b5da78acfbf7da6c4848fb720413 Mon Sep 17 00:00:00 2001 From: Will Newton Date: Fri, 4 Feb 2011 11:07:46 +0000 Subject: [PATCH 1/2] dw_mmc: Run card detect tasklet during slot initialisation. We need to run the card detect tasklet at the end of slot initialisation as it is possible that a card has been inserted prior to boot, so we miss the insertion interrupt and now the card is sitting there inserted but with no power to it. Signed-off-by: Neil Jones Signed-off-by: Will Newton --- drivers/mmc/host/dw_mmc.c | 7 +++++++ 1 files changed, 7 insertions(+), 0 deletions(-) diff --git a/drivers/mmc/host/dw_mmc.c b/drivers/mmc/host/dw_mmc.c index 2fcc825..0b0bedd 100644 --- a/drivers/mmc/host/dw_mmc.c +++ b/drivers/mmc/host/dw_mmc.c @@ -1441,6 +1441,13 @@ static int __init dw_mci_init_slot(struct dw_mci *host, unsigned int id) /* Card initially undetected */ slot->last_detect_state = 0; + + /* + * Card may have been plugged in prior to boot so we + * need to run the detect tasklet + */ + tasklet_schedule(&host->card_tasklet); + return 0; } -- 1.7.3.4