Not knowing the details, I'd suggest to implement a generic function to
create an attributed inode and let the fs override it to create an
unlinked-file-dentry instead.
Benefit: All fs supporting extended attributes will be able to support
whiteout. If the fs has other means of supporting whiteout, they may fake
the attribute.
Possible problems:
- Having two ways of reporting a whiteout? Or can it be reported using a
(static) fake inode?
- How do you un-whiteout while (not) having an overlaying fs?
Do a hardlink if you can create a hard link, otherwise use a fresh inode
and use that for the next hardlink(s).
--