nnpfs/linux: replacing call to shrink_dcache_sb

Alexander Boström abo at kth.se
Tue Jun 5 10:50:44 CEST 2007


Hi,

In RHEL5 there's a subset of the kernel ABI which RH guarantees to be
stable, so if you stick to that, you can (hopefully) compile your out-
of-tree module once and use it for all kernel revisions. Also, if you
build an RPM of your kernel module, the find-requires magic will output
deps that are satisifed by any kernel instead of just the one you
compiled against. The output of this command gives the list of symbols:
/usr/lib/rpm/redhat/symset-table

But the problem is, I can't do this for the kmod-nnpfs RPM, because
nnpfs uses three symbols outside of this ABI, namely register_security,
unregister_security and shrink_dcache_sb. The first two I can just
comment out, but the third is a problem. It's used here in nnpfs_dev.c:

static void
nnpfs_invalidate_all(struct nnpfs *nnpfsp)
{
    NNPFSDEB(XDEBNODE, ("free_all_nnpfs_nodes starting\n"));

    shrink_dcache_sb(nnpfs->sb);
    invalidate_inodes(nnpfs->sb);
    
    NNPFSDEB(XDEBNODE, ("free_all_nnpfs_nodes done\n"));
}

Any hope of getting around that somehow?

The kernel has a function generic_shutdown_super which is in the ABI and
looks like it's doing something similar to nnpfs_invalidate_all, but
more complex. But it probably does too much, I guess... Any other ideas?

/abo




More information about the Arla-drinkers mailing list