/* * Copyright (C) 2005-2010 Junjiro R. Okajima * * This program, aufs is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ /* * sub-routines for dentry cache */ #ifndef __AUFS_DCSUB_H__ #define __AUFS_DCSUB_H__ #ifdef __KERNEL__ #include struct dentry; struct au_dpage { int ndentry; struct dentry **dentries; }; struct au_dcsub_pages { int ndpage; struct au_dpage *dpages; }; /* ---------------------------------------------------------------------- */ int au_dpages_init(struct au_dcsub_pages *dpages, gfp_t gfp); void au_dpages_free(struct au_dcsub_pages *dpages); typedef int (*au_dpages_test)(struct dentry *dentry, void *arg); int au_dcsub_pages(struct au_dcsub_pages *dpages, struct dentry *root, au_dpages_test test, void *arg); int au_dcsub_pages_rev(struct au_dcsub_pages *dpages, struct dentry *dentry, int do_include, au_dpages_test test, void *arg); int au_test_subdir(struct dentry *d1, struct dentry *d2); #endif /* __KERNEL__ */ #endif /* __AUFS_DCSUB_H__ */