[prev in list] [next in list] [prev in thread] [next in thread] 

List:       dragonfly-submit
Subject:    [DragonFlyBSD - Submit #2905] (New) Add EVFILT_FS
From:       bugtracker-admin () leaf ! dragonflybsd ! org
Date:       2016-04-29 14:20:29
Message-ID: redmine.issue-2905.20160429142029.54da7c982552ea7e () leaf ! dragonflybsd ! org
[Download RAW message or body]

Issue #2905 has been reported by tkusumi.

----------------------------------------
Submit #2905: Add EVFILT_FS
http://bugs.dragonflybsd.org/issues/2905

* Author: tkusumi
* Status: New
* Priority: Normal
* Assignee: 
* Category: 
* Target version: 
----------------------------------------
Matt (or Sephe),

I'd like to add EVFILT_FS type to kqueue events.
autoumountd which is a userspace daemon of autofs needs this.

EVFILT_FS has existed in FreeBSD since 2004.
EVFILT_FS is triggered only when mounting or unmounting a filesystem.
(FreeBSD later added some NFS events in addition to mount/unmount, but this commit \
doesn't apply those)

The patch needs to be reviewed as I've only read kern/kern_event.c today to briefly \
understand the mechanism.


https://leaf.dragonflybsd.org/~tkusumi/diff/0001-sys-kern-Add-EVFILT_FS.patch

sample userspace code
https://leaf.dragonflybsd.org/~tkusumi/diff/kqueue1.c

--
[root@]~# gcc -Wall -g ./kqueue1.c -o ./kqueue1
[root@]~# ./kqueue1
timeout
timeout
timeout
timeout
timeout
timeout
filesystem event filter=-10 mount
timeout
timeout
filesystem event filter=-10 unmount
timeout
timeout
filesystem event filter=-10 mount
filesystem event filter=-10 unmount
timeout
timeout
timeout
^C




-- 
You have received this notification because you have either subscribed to it, or are \
involved in it. To change your notification preferences, please click here: \
http://bugs.dragonflybsd.org/my/account


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic