Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1761595AbZD3ANR (ORCPT ); Wed, 29 Apr 2009 20:13:17 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1761393AbZD3AM5 (ORCPT ); Wed, 29 Apr 2009 20:12:57 -0400 Received: from sj-iport-3.cisco.com ([171.71.176.72]:14836 "EHLO sj-iport-3.cisco.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759370AbZD3AMz (ORCPT ); Wed, 29 Apr 2009 20:12:55 -0400 X-IronPort-AV: E=Sophos;i="4.40,269,1238976000"; d="scan'208";a="157827847" Date: Wed, 29 Apr 2009 17:12:55 -0700 From: David VomLehn To: linux-usb@vger.kernel.org Cc: gregkh@suse.de, linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 5/5] USB: Wait for USB and SCSI block boot devices Message-ID: <20090430001255.GA3897@cuplxvomd02.corp.sa.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) Authentication-Results: sj-dkim-1; header.From=dvomlehn@cisco.com; dkim=pass ( sig from cisco.com/sjdkim1004 verified; ); Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1836 Lines: 56 From: Alan Stern --- drivers/scsi/scsi_scan.c | 2 ++ drivers/usb/storage/usb.c | 2 ++ 2 files changed, 4 insertions(+), 0 deletions(-) diff --git a/drivers/scsi/scsi_scan.c b/drivers/scsi/scsi_scan.c index 6f51ca4..735b061 100644 --- a/drivers/scsi/scsi_scan.c +++ b/drivers/scsi/scsi_scan.c @@ -1834,6 +1834,7 @@ static int do_scan_async(void *_data) struct async_scan_data *data = _data; do_scsi_scan_host(data->shost); scsi_finish_async_scan(data); + bootdev_probe_done(BOOTDEV_BLOCK_MASK); return 0; } @@ -1855,6 +1856,7 @@ void scsi_scan_host(struct Scsi_Host *shost) return; } + bootdev_found(BOOTDEV_BLOCK_MASK); p = kthread_run(do_scan_async, data, "scsi_scan_%d", shost->host_no); if (IS_ERR(p)) do_scan_async(data); diff --git a/drivers/usb/storage/usb.c b/drivers/usb/storage/usb.c index 8060b85..c128c44 100644 --- a/drivers/usb/storage/usb.c +++ b/drivers/usb/storage/usb.c @@ -810,6 +810,7 @@ static int usb_stor_scan_thread(void * __us) printk(KERN_DEBUG "usb-storage: device found at %d\n", us->pusb_dev->devnum); + bootdev_found(BOOTDEV_BLOCK_MASK); set_freezable(); /* Wait for the timeout to expire or for a disconnect */ @@ -837,6 +838,7 @@ static int usb_stor_scan_thread(void * __us) /* Should we unbind if no devices were detected? */ } + bootdev_probe_done(BOOTDEV_BLOCK_MASK); complete_and_exit(&us->scanning_done, 0); } -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/