mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-13 14:24:11 +08:00
d0ce643911
Add a new helper to handle a single attr multi ioctl operation that can be shared between the native and compat ioctl implementation. There is a slight change in behaviour in that we don't break out of the loop when copying in the attribute name fails. The previous behaviour was rather inconsistent here as it continued for any other kind of error, and that we don't clear the flags in the structure returned to userspace, a behavior only introduced as a bug fix in the last merge window. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Dave Chinner <dchinner@redhat.com> Reviewed-by: Chandan Rajendra <chandanrlinux@gmail.com> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
64 lines
1.2 KiB
C
64 lines
1.2 KiB
C
// SPDX-License-Identifier: GPL-2.0
|
|
/*
|
|
* Copyright (c) 2008 Silicon Graphics, Inc.
|
|
* All Rights Reserved.
|
|
*/
|
|
#ifndef __XFS_IOCTL_H__
|
|
#define __XFS_IOCTL_H__
|
|
|
|
extern int
|
|
xfs_ioc_space(
|
|
struct file *filp,
|
|
xfs_flock64_t *bf);
|
|
|
|
int
|
|
xfs_ioc_swapext(
|
|
xfs_swapext_t *sxp);
|
|
|
|
extern int
|
|
xfs_find_handle(
|
|
unsigned int cmd,
|
|
xfs_fsop_handlereq_t *hreq);
|
|
|
|
extern int
|
|
xfs_open_by_handle(
|
|
struct file *parfilp,
|
|
xfs_fsop_handlereq_t *hreq);
|
|
|
|
extern int
|
|
xfs_readlink_by_handle(
|
|
struct file *parfilp,
|
|
xfs_fsop_handlereq_t *hreq);
|
|
|
|
int xfs_ioc_attrmulti_one(struct file *parfilp, struct inode *inode,
|
|
uint32_t opcode, void __user *uname, void __user *value,
|
|
uint32_t *len, uint32_t flags);
|
|
|
|
extern struct dentry *
|
|
xfs_handle_to_dentry(
|
|
struct file *parfilp,
|
|
void __user *uhandle,
|
|
u32 hlen);
|
|
|
|
extern long
|
|
xfs_file_ioctl(
|
|
struct file *filp,
|
|
unsigned int cmd,
|
|
unsigned long p);
|
|
|
|
extern long
|
|
xfs_file_compat_ioctl(
|
|
struct file *file,
|
|
unsigned int cmd,
|
|
unsigned long arg);
|
|
|
|
struct xfs_ibulk;
|
|
struct xfs_bstat;
|
|
struct xfs_inogrp;
|
|
|
|
int xfs_fsbulkstat_one_fmt(struct xfs_ibulk *breq,
|
|
const struct xfs_bulkstat *bstat);
|
|
int xfs_fsinumbers_fmt(struct xfs_ibulk *breq, const struct xfs_inumbers *igrp);
|
|
|
|
#endif
|