From owner-freebsd-current@FreeBSD.ORG Sat Mar 6 08:45:40 2010 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8D3CD106566C for ; Sat, 6 Mar 2010 08:45:40 +0000 (UTC) (envelope-from yanefbsd@gmail.com) Received: from mail-pw0-f54.google.com (mail-pw0-f54.google.com [209.85.160.54]) by mx1.freebsd.org (Postfix) with ESMTP id 1449E8FC1D for ; Sat, 6 Mar 2010 08:45:39 +0000 (UTC) Received: by pwj1 with SMTP id 1so3186451pwj.13 for ; Sat, 06 Mar 2010 00:45:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=jRZtqJ6+4A2mX4ZWus1tM4RDxXs9EslNHr/McwG4ChM=; b=nla1/xUEm94uzIII3x/+qDmZaz2GepvWUO6sk3daiCO0xanpYExWZNomTXp3lpcVkU 7utlrcNK+hO+V0lvSzauen+qGRAYN7+VnCTIj1C0y075ppQBiO5HCPBQinDLCFN8kukK bGO0KQpD/cUgasDgzl7ihYNy3XWKdecV3diQE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=YNa+Lfy21IcLQ5s3Mn8GPn/f5qHg6m6pJsahj1OKX3wIdCQy2297oNCv+/usn9e0Yz MqW9hlsu043Aj5izIFYforn7CbICUAvK45zyYsYCr6aqY4/iAWwtWe82thm1G5IBu4O7 E/f+5cL2v67/XgHjVktDi54Qd+FsEkunFia0w= MIME-Version: 1.0 Received: by 10.142.196.19 with SMTP id t19mr1390288wff.151.1267865136455; Sat, 06 Mar 2010 00:45:36 -0800 (PST) In-Reply-To: <4e6cba831003050516r3cf2ee88p65486248e861dbed@mail.gmail.com> References: <201003011731.20790.hselasky@c2i.net> <4e6cba831003050516r3cf2ee88p65486248e861dbed@mail.gmail.com> Date: Sat, 6 Mar 2010 00:45:36 -0800 Message-ID: <7d6fde3d1003060045p330292d2w2b66bbb815067cc7@mail.gmail.com> From: Garrett Cooper To: Giovanni Trematerra Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: freebsd-current@freebsd.org, Hans Petter Selasky Subject: Re: [FAQ] FBSD on a USB stick X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 06 Mar 2010 08:45:40 -0000 On Fri, Mar 5, 2010 at 5:16 AM, Giovanni Trematerra wrote: > Instead of this patch people can use kern.cam.boot_delay > Just set a delay in ms. > That works on 8-STABLE too. > > On Mon, Mar 1, 2010 at 5:31 PM, Hans Petter Selasky wr= ote: >> Hi, >> >> Sometimes the USB sticks won't get detected in time. You can fix this by= using >> the following simple quick and dirty patch. >> >> --HPS >> >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >> --- sys/kern/vfs_mount.c =A0 =A0 =A0 =A0(revision 204512) >> +++ sys/kern/vfs_mount.c =A0 =A0 =A0 =A0(local) >> @@ -1656,6 +1656,8 @@ >> =A0 =A0 =A0 =A0 =A0 =A0UMA_ALIGN_PTR, UMA_ZONE_NOFREE); >> =A0 =A0 =A0 =A0devfs_first(); >> >> +repeat: >> + >> =A0 =A0 =A0 =A0/* >> =A0 =A0 =A0 =A0 * We are booted with instructions to prompt for the root= filesystem. >> =A0 =A0 =A0 =A0 */ >> @@ -1725,9 +1727,10 @@ >> =A0 =A0 =A0 =A0 * Everything so far has failed, prompt on the console if= we haven't >> =A0 =A0 =A0 =A0 * already tried that. >> =A0 =A0 =A0 =A0 */ >> - =A0 =A0 =A0 if (!asked) >> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 if (!vfs_mountroot_ask()) >> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 goto mounted; >> + =A0 =A0 =A0 if (!asked) { >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 pause("WDISK", 1*hz); >> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 goto repeat; >> + =A0 =A0 =A0 } >> >> =A0 =A0 =A0 =A0panic("Root mount failed, startup aborted."); I agree with Giovanni as it's easier to customize than the proposed patch above; it'll be nice when the work has been done where hacks like these won't be required (waits in anticipation for scottl's cam work). Thanks! -Garrett