From mboxrd@z Thu Jan 1 00:00:00 1970 From: Arjan van de Ven Date: Thu, 01 Jun 2006 14:00:26 +0000 Subject: Re: Asynchronous scsi scanning, version 9 Message-Id: <1149170426.3115.57.camel@laptopd505.fenrus.org> List-Id: References: <20060511143352.GI12272@parisc-linux.org> <20060518172258.GL1604@parisc-linux.org> <20060529031915.GB23405@parisc-linux.org> <447AB2F5.2000700@s5r6.in-berlin.de> <20060529130515.GE23405@parisc-linux.org> <20060531232139.GA3202@us.ibm.com> <447EE81D.2050906@ums.usu.ru> <20060601132315.GD32143@parisc-linux.org> In-Reply-To: <20060601132315.GD32143@parisc-linux.org> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Matthew Wilcox Cc: linux-scsi@vger.kernel.org, Stefan Richter , linux-hotplug-devel@lists.sourceforge.net, Patrick Mansfield , "Alexander E. Patrakov" On Thu, 2006-06-01 at 07:23 -0600, Matthew Wilcox wrote: > On Thu, Jun 01, 2006 at 07:14:05PM +0600, Alexander E. Patrakov wrote: > > Patrick Mansfield wrote: > > >>That's what scsi_complete_async_scans() is for. If you have a built-in > > >>module, it will wait for the async scans to finish before we get as far > > >>as trying to mount root. It does change observable behaviour in that > > >>sys_module_init() will return before scans are complete. > > > > What are the expected interactions of this code with early userspace aka > > "kinit" that comes with (soon to be merged) klibc? Does this > > scsi_complete_async_scans() function get called at all if such "default" > > initramfs with kinit is used? > > It gets called as a late_initcall -- before initramfs gets started. The > problem comes when you load your scsi driver as a module. > > There's a potential solution to this. If we add a hook to sys_module_init > such that it'll call a specified function before returning, we can make > it wait until all scans are done. This way, userspace never sees the > asynchronous scanning behaviour. But if you have devices of different > types, you won't get the overlapping scans. alternative is a syscall/ioctl/sysfs thing that userland can trigger to cause this wait to happen... would be nice I suppose as a general option..... ------------------------------------------------------- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnk&kid7521&bid$8729&dat1642 _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel