• sandeen@sandeen.net's avatar
    [XFS] Clean up some existing compat ioctl calls · d5547f9f
    sandeen@sandeen.net authored
    Create a new xfs_ioctl.h file which has prototypes for
    ioctl helpers that may be called in compat mode.
    
    Change several compat ioctl cases which are IOW to simply copy
    in the userspace argument, then call the common ioctl helper.
    
    This also fixes xfs_compat_ioc_fsgeometry_v1(), which had
    it backwards before; it copied in an (empty) arg, then copied
    out the native result, which probably corrupted userspace.  It
    should be translating on the copyout.
    
    Also, a bit of formatting cleanup for consistency, and conversion
    of all error returns to use XFS_ERROR().
    Signed-off-by: default avatarEric Sandeen <sandeen@sandeen.net>
    Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
    Signed-off-by: default avatarLachlan McIlroy <lachlan@sgi.com>
    d5547f9f
xfs_ioctl.h 1.22 KB