HID: hiddev: Fix slab-out-of-bounds write in hiddev_ioctl_usage()
[linux/fpc-iii.git] / fs / xfs / libxfs / xfs_inode_buf.h
blob9308c47f2a527dc08b75b66de5d064e0b13e0cfe
1 /*
2 * Copyright (c) 2000-2003,2005 Silicon Graphics, Inc.
3 * All Rights Reserved.
5 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU General Public License as
7 * published by the Free Software Foundation.
9 * This program is distributed in the hope that it would be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write the Free Software Foundation,
16 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18 #ifndef __XFS_INODE_BUF_H__
19 #define __XFS_INODE_BUF_H__
21 struct xfs_inode;
22 struct xfs_dinode;
23 struct xfs_icdinode;
26 * Inode location information. Stored in the inode and passed to
27 * xfs_imap_to_bp() to get a buffer and dinode for a given inode.
29 struct xfs_imap {
30 xfs_daddr_t im_blkno; /* starting BB of inode chunk */
31 ushort im_len; /* length in BBs of inode chunk */
32 ushort im_boffset; /* inode offset in block in bytes */
35 int xfs_imap_to_bp(struct xfs_mount *, struct xfs_trans *,
36 struct xfs_imap *, struct xfs_dinode **,
37 struct xfs_buf **, uint, uint);
38 int xfs_iread(struct xfs_mount *, struct xfs_trans *,
39 struct xfs_inode *, uint);
40 void xfs_dinode_calc_crc(struct xfs_mount *, struct xfs_dinode *);
41 void xfs_dinode_to_disk(struct xfs_dinode *to, struct xfs_icdinode *from);
42 void xfs_dinode_from_disk(struct xfs_icdinode *to, struct xfs_dinode *from);
44 #if defined(DEBUG)
45 void xfs_inobp_check(struct xfs_mount *, struct xfs_buf *);
46 #else
47 #define xfs_inobp_check(mp, bp)
48 #endif /* DEBUG */
50 #endif /* __XFS_INODE_BUF_H__ */