Dave Chinner | 0b61f8a | 2018-06-05 19:42:14 -0700 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0 |
sandeen@sandeen.net | d5547f9 | 2008-11-25 21:20:08 -0600 | [diff] [blame] | 2 | /* |
| 3 | * Copyright (c) 2008 Silicon Graphics, Inc. |
| 4 | * All Rights Reserved. |
sandeen@sandeen.net | d5547f9 | 2008-11-25 21:20:08 -0600 | [diff] [blame] | 5 | */ |
| 6 | #ifndef __XFS_IOCTL_H__ |
| 7 | #define __XFS_IOCTL_H__ |
| 8 | |
Christoph Hellwig | 3e7a779 | 2020-02-26 17:30:38 -0800 | [diff] [blame] | 9 | struct xfs_bstat; |
| 10 | struct xfs_ibulk; |
| 11 | struct xfs_inogrp; |
| 12 | |
Dave Chinner | a133d95 | 2013-08-12 20:49:48 +1000 | [diff] [blame] | 13 | int |
| 14 | xfs_ioc_swapext( |
| 15 | xfs_swapext_t *sxp); |
| 16 | |
sandeen@sandeen.net | d5547f9 | 2008-11-25 21:20:08 -0600 | [diff] [blame] | 17 | extern int |
| 18 | xfs_find_handle( |
| 19 | unsigned int cmd, |
| 20 | xfs_fsop_handlereq_t *hreq); |
| 21 | |
| 22 | extern int |
| 23 | xfs_open_by_handle( |
sandeen@sandeen.net | d5547f9 | 2008-11-25 21:20:08 -0600 | [diff] [blame] | 24 | struct file *parfilp, |
Christoph Hellwig | ab596ad | 2009-01-19 02:02:57 +0100 | [diff] [blame] | 25 | xfs_fsop_handlereq_t *hreq); |
sandeen@sandeen.net | d5547f9 | 2008-11-25 21:20:08 -0600 | [diff] [blame] | 26 | |
| 27 | extern int |
| 28 | xfs_readlink_by_handle( |
Christoph Hellwig | ab596ad | 2009-01-19 02:02:57 +0100 | [diff] [blame] | 29 | struct file *parfilp, |
| 30 | xfs_fsop_handlereq_t *hreq); |
sandeen@sandeen.net | 2875097 | 2008-11-25 21:20:15 -0600 | [diff] [blame] | 31 | |
Christoph Hellwig | d0ce6439 | 2020-02-26 17:30:31 -0800 | [diff] [blame] | 32 | int xfs_ioc_attrmulti_one(struct file *parfilp, struct inode *inode, |
| 33 | uint32_t opcode, void __user *uname, void __user *value, |
| 34 | uint32_t *len, uint32_t flags); |
Dan Carpenter | 6ed6356 | 2021-12-21 09:38:19 -0800 | [diff] [blame] | 35 | int xfs_ioc_attr_list(struct xfs_inode *dp, void __user *ubuf, |
| 36 | size_t bufsize, int flags, |
| 37 | struct xfs_attrlist_cursor __user *ucursor); |
sandeen@sandeen.net | 2875097 | 2008-11-25 21:20:15 -0600 | [diff] [blame] | 38 | |
Christoph Hellwig | ab596ad | 2009-01-19 02:02:57 +0100 | [diff] [blame] | 39 | extern struct dentry * |
| 40 | xfs_handle_to_dentry( |
| 41 | struct file *parfilp, |
| 42 | void __user *uhandle, |
| 43 | u32 hlen); |
| 44 | |
Miklos Szeredi | 9fefd5d | 2021-04-07 14:36:43 +0200 | [diff] [blame] | 45 | extern int |
| 46 | xfs_fileattr_get( |
| 47 | struct dentry *dentry, |
| 48 | struct fileattr *fa); |
| 49 | |
| 50 | extern int |
| 51 | xfs_fileattr_set( |
| 52 | struct user_namespace *mnt_userns, |
| 53 | struct dentry *dentry, |
| 54 | struct fileattr *fa); |
| 55 | |
Christoph Hellwig | ddcd856 | 2008-12-03 07:55:34 -0500 | [diff] [blame] | 56 | extern long |
Christoph Hellwig | 4d4be48 | 2008-12-09 04:47:33 -0500 | [diff] [blame] | 57 | xfs_file_ioctl( |
| 58 | struct file *filp, |
Christoph Hellwig | ddcd856 | 2008-12-03 07:55:34 -0500 | [diff] [blame] | 59 | unsigned int cmd, |
Christoph Hellwig | 4d4be48 | 2008-12-09 04:47:33 -0500 | [diff] [blame] | 60 | unsigned long p); |
Christoph Hellwig | ddcd856 | 2008-12-03 07:55:34 -0500 | [diff] [blame] | 61 | |
| 62 | extern long |
Christoph Hellwig | 4d4be48 | 2008-12-09 04:47:33 -0500 | [diff] [blame] | 63 | xfs_file_compat_ioctl( |
Christoph Hellwig | ddcd856 | 2008-12-03 07:55:34 -0500 | [diff] [blame] | 64 | struct file *file, |
| 65 | unsigned int cmd, |
| 66 | unsigned long arg); |
| 67 | |
Darrick J. Wong | 8bfe9d1 | 2019-07-03 20:36:26 -0700 | [diff] [blame] | 68 | int xfs_fsbulkstat_one_fmt(struct xfs_ibulk *breq, |
Darrick J. Wong | 7035f97 | 2019-07-03 20:36:26 -0700 | [diff] [blame] | 69 | const struct xfs_bulkstat *bstat); |
Darrick J. Wong | 5f19c7f | 2019-07-03 20:36:27 -0700 | [diff] [blame] | 70 | int xfs_fsinumbers_fmt(struct xfs_ibulk *breq, const struct xfs_inumbers *igrp); |
Darrick J. Wong | 2810bd6 | 2019-07-02 09:39:40 -0700 | [diff] [blame] | 71 | |
sandeen@sandeen.net | d5547f9 | 2008-11-25 21:20:08 -0600 | [diff] [blame] | 72 | #endif |