Dthain varargs cleanup

Added __attribute__ backup definition.
Added casts to pfs_*.