From owner-freebsd-hackers@FreeBSD.ORG Wed Apr 16 14:01:42 2014 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id A0C99B1C for ; Wed, 16 Apr 2014 14:01:42 +0000 (UTC) Received: from bigwig.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 7A312135F for ; Wed, 16 Apr 2014 14:01:42 +0000 (UTC) Received: from jhbbsd.localnet (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 68164B94F; Wed, 16 Apr 2014 10:01:41 -0400 (EDT) From: John Baldwin To: freebsd-hackers@freebsd.org Subject: Re: inode modification notification in kernel Date: Wed, 16 Apr 2014 09:44:15 -0400 User-Agent: KMail/1.13.5 (FreeBSD/8.4-CBSD-20130906; KDE/4.5.5; amd64; ; ) References: <20140411220747.GA7305@pwnie.vrt.sourcefire.com> In-Reply-To: <20140411220747.GA7305@pwnie.vrt.sourcefire.com> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Message-Id: <201404160944.15107.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Wed, 16 Apr 2014 10:01:41 -0400 (EDT) Cc: Shawn Webb X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Apr 2014 14:01:42 -0000 On Friday, April 11, 2014 6:07:48 pm Shawn Webb wrote: > Hey All, > > I'm a newb at the kernel API. What's the best way to receive > notification of a deletion event of a given inode in the kernel? In > userland, I'd use kqueue/kevent. Is that same API available in the > kernel? Or is there something different? There really isn't an in-kernel API for that. However, you might be able to do something in your filesystem's VOP_RECLAIM (depends on what you are trying to use this for) -- John Baldwin