From owner-freebsd-mips@FreeBSD.ORG Fri Feb 5 05:09:23 2010 Return-Path: Delivered-To: freebsd-mips@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9618C106566C for ; Fri, 5 Feb 2010 05:09:23 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-iw0-f188.google.com (mail-iw0-f188.google.com [209.85.223.188]) by mx1.freebsd.org (Postfix) with ESMTP id 65C268FC08 for ; Fri, 5 Feb 2010 05:09:23 +0000 (UTC) Received: by iwn26 with SMTP id 26so1284902iwn.14 for ; Thu, 04 Feb 2010 21:09:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:content-type; bh=ER1JXv3cmgse44f8hGRn4wTTiOeASWw0Ll+vvc4pW54=; b=IrYp2dPckf3MuX88g8zVLK6SHTyjEl1EkoW+1aX3xlqmchJqYXf/az6FHDa/n6BbRO /i6upYmD9nBdvq+WN3d6UkBxz0M81yebHy0cdDE4MReqEc2iCe6HJRGcK0ew96UaMrXC RAI2ctcCAeJUOnGL343PVnNAuOsJlUf7MGloc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=c4OLgoug5TARhYYz4OcbFSW9UORYdOIsJTihU7WD4kA+UrZ3D0HPUdElJtCOWW7OMS 0r2SfSH0t5RlX43DjKP+RYGwsh8Ag8ngyFyCUgFDy+wISgv8Pj3F2sP5pYP2AFYUCwR7 cBhyCcn32jH7YAEJHB7y/K8oPT7PnB7Lradh4= MIME-Version: 1.0 Received: by 10.231.160.205 with SMTP id o13mr1426773ibx.13.1265346562621; Thu, 04 Feb 2010 21:09:22 -0800 (PST) Date: Fri, 5 Feb 2010 13:09:22 +0800 Message-ID: From: Adrian Chadd To: freebsd-mips@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Subject: rspro board and mounting root from SD X-BeenThere: freebsd-mips@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to MIPS List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Feb 2010 05:09:23 -0000 Howdy, I've been looking at using an SD card as a test root device but it unfortunately appears that device probing doesn't quite happen fast enough for the umass device to be enumerated. description: * system boots * usbus0 is created - root_mount_hold("usbus0") called * usbus0 is probed, and umass0 is found/createdcreated * umass0 probe begins * root_mount_rel() on usbus0 is called * nothing else is waiting, so VFS tries mounting the root device The SD probe/attach doesn't occur until -after- the root is mounted and the system begins. If I stick a root_mount_hold() call in umass_attach(), the umass device is given the opportunity to complete probe/attach but obviously then a lack of root_mount_rel() results in nothing completing. Any ideas? My knowledge of USB/CAM internals is currently non-existant. I couldn't find any particular function/callback which is called when the umass bus probe completes - as far as I can tell, attach kicks off some CAM messages which may eventually end up finding a device or not. I'm not sure of the "right" place to put the release; or whether I'm on the right track at all. Adrian