From owner-freebsd-fs@FreeBSD.ORG Sun May 27 02:36:06 2007 Return-Path: X-Original-To: fs@freebsd.org Delivered-To: freebsd-fs@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 4DD9316A46D for ; Sun, 27 May 2007 02:36:06 +0000 (UTC) (envelope-from howard0su@gmail.com) Received: from py-out-1112.google.com (py-out-1112.google.com [64.233.166.182]) by mx1.freebsd.org (Postfix) with ESMTP id 0CED013C44B for ; Sun, 27 May 2007 02:36:05 +0000 (UTC) (envelope-from howard0su@gmail.com) Received: by py-out-1112.google.com with SMTP id a29so2208306pyi for ; Sat, 26 May 2007 19:36:05 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=RVnledAObzU+HH7yBkMdRLKuBWC/OfBAEF8ri1WbsAtmsY6WGn2IS8PIAxjxPOJfc4HUR4WF9wCjhX3QaY/M45PKufiaXQVGpHuQ6ARzpBZPIld1meusfICcVa4wrVRuXENn1YUapgaMA94kqrWd/is050Z5w17D+A4TfOgAe5E= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=d0LQETERiGGu1jf9TapnTzggayBjqI8oQbQhniPcpX581/Wf43m7LwbjkWYjVM/1wpnPhV00XN3QEqpknFiEMrtFMtzGhXSwI0b1VGpoHhaI9sm9/Xc1KmINXf80ilCWg6XRTWxB9vKVRkmFo42AHI2quIbShxGPK0P75+I8lPs= Received: by 10.35.67.18 with SMTP id u18mr3340032pyk.1180233365431; Sat, 26 May 2007 19:36:05 -0700 (PDT) Received: by 10.35.79.18 with HTTP; Sat, 26 May 2007 19:36:05 -0700 (PDT) Message-ID: Date: Sun, 27 May 2007 10:36:05 +0800 From: "Howard Su" To: "Pawel Jakub Dawidek" In-Reply-To: <20070526194000.GC27289@garage.freebsd.pl> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20070526194000.GC27289@garage.freebsd.pl> Cc: fs@freebsd.org Subject: Re: call for help on TMPFS X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 27 May 2007 02:36:06 -0000 On 5/27/07, Pawel Jakub Dawidek wrote: > On Sat, May 26, 2007 at 12:06:14AM +0800, Howard Su wrote: > I think you are missing some cases in lookup where you should add > SAVENAME flag. I'd start from adding this (or similar) assertions: > > KASSERT((ap->a_cnp->cn_flags & SAVENAME), ("No SAVENAME")); > > to the following functions: > > tmpfs_create() > tmpfs_remove() > tmpfs_mkdir() > tmpfs_rmdir() > tmpfs_rename() (assert both: fcnp and tcnp) > tmpfs_symlink() > tmpfs_link() Thank you very much. You are right. I just fixed this long standing panic. PS: I noticed that kernel option DIAGNOSTIC will clean ap->a_cnp with NULL if you don't give SAVENAME. So I enable DIAGNOSTIC instead of adding asserts. -- -Howard