Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: [netbsd-6] src/lib



Module Name:    src
Committed By:   riz
Date:           Thu Sep 13 20:20:17 UTC 2012

Modified Files:
        src/lib/libp2k [netbsd-6]: p2k.c
        src/lib/libpuffs [netbsd-6]: dispatcher.c pnode.c puffs.3 puffs.h
            puffs_ops.3

Log Message:
Pull up following revision(s) (requested by manu in ticket #525):
        lib/libpuffs/dispatcher.c: revision 1.44
        lib/libp2k/p2k.c: revision 1.57
        lib/libpuffs/puffs_ops.3: revision 1.35
        lib/libpuffs/pnode.c: revision 1.13
        lib/libpuffs/puffs.3: revision 1.56
        lib/libpuffs/puffs.h: revision 1.124
Fix regression that has been introduced when the lookup/reclaim race
condition was addressed in libpuffs by counting lookups.
The fix assumes that cookies map to struct puffs_cookie, which has not
been documented as a requirement for filesystems using libpuffs. As an
example, we got burnt by this assumption in libp2k (kern/46734), and
we fixed bit by actually mapping libp2k cookies to struct puffs_node.
It is unlikely, but there may be third party filesystems that use cookies
unmapped to struct puffs_node, and they were left broken for now.
- we introduce a puffs_init() flag PUFFS_FLAG_PNCOOKIE that let filesystems
inform libpuffs that they map cookies to struct puffs_node. Is that flag
is used, the lookup/reclaim race condition fix is enabled. We enable the
flag for libp2k.
- filesystems that use puffs_pn_new() obviouslty use struct puffs_node
and gain PUFFS_FLAG_PNCOOKIE automatically even if they did not specify
it in puffs_init(). This include all our PUFFS filesystem in-tree except
libp2k.
- for filesystems not willing to use struct puffs_node, we introduce a
reclaim2 vnop, which is reclaim with an additionnal lookup count argument.
This vnop let the filesystem implement the lookup/reclaim race fix on
its own.


To generate a diff of this commit:
cvs rdiff -u -r1.55.4.1 -r1.55.4.2 src/lib/libp2k/p2k.c
cvs rdiff -u -r1.38.2.3 -r1.38.2.4 src/lib/libpuffs/dispatcher.c
cvs rdiff -u -r1.10.20.1 -r1.10.20.2 src/lib/libpuffs/pnode.c
cvs rdiff -u -r1.49.2.2 -r1.49.2.3 src/lib/libpuffs/puffs.3
cvs rdiff -u -r1.119.4.3 -r1.119.4.4 src/lib/libpuffs/puffs.h
cvs rdiff -u -r1.29.4.3 -r1.29.4.4 src/lib/libpuffs/puffs_ops.3

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




Home | Main Index | Thread Index | Old Index