blob: 5a632531f843d23ab436aaae20c9df3197f9facf [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/*
Nathan Scott4ce31212005-11-02 14:59:41 +11002 * Copyright (c) 2000-2003 Silicon Graphics, Inc.
3 * All Rights Reserved.
Linus Torvalds1da177e2005-04-16 15:20:36 -07004 *
Nathan Scott4ce31212005-11-02 14:59:41 +11005 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU General Public License as
Linus Torvalds1da177e2005-04-16 15:20:36 -07007 * published by the Free Software Foundation.
8 *
Nathan Scott4ce31212005-11-02 14:59:41 +11009 * 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.
Linus Torvalds1da177e2005-04-16 15:20:36 -070013 *
Nathan Scott4ce31212005-11-02 14:59:41 +110014 * 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
Linus Torvalds1da177e2005-04-16 15:20:36 -070017 */
18#ifndef __XFS_DQUOT_ITEM_H__
19#define __XFS_DQUOT_ITEM_H__
20
21struct xfs_dquot;
22struct xfs_trans;
23struct xfs_mount;
24struct xfs_qoff_logitem;
25
26typedef struct xfs_dq_logitem {
27 xfs_log_item_t qli_item; /* common portion */
28 struct xfs_dquot *qli_dquot; /* dquot ptr */
29 xfs_lsn_t qli_flush_lsn; /* lsn at last flush */
30 unsigned short qli_pushbuf_flag; /* 1 bit used in push_ail */
31#ifdef DEBUG
32 uint64_t qli_push_owner;
33#endif
34 xfs_dq_logformat_t qli_format; /* logged structure */
35} xfs_dq_logitem_t;
36
37typedef struct xfs_qoff_logitem {
38 xfs_log_item_t qql_item; /* common portion */
39 struct xfs_qoff_logitem *qql_start_lip; /* qoff-start logitem, if any */
40 xfs_qoff_logformat_t qql_format; /* logged structure */
41} xfs_qoff_logitem_t;
42
43
44extern void xfs_qm_dquot_logitem_init(struct xfs_dquot *);
45extern xfs_qoff_logitem_t *xfs_qm_qoff_logitem_init(struct xfs_mount *,
46 struct xfs_qoff_logitem *, uint);
47extern xfs_qoff_logitem_t *xfs_trans_get_qoff_item(struct xfs_trans *,
48 struct xfs_qoff_logitem *, uint);
49extern void xfs_trans_log_quotaoff_item(struct xfs_trans *,
50 struct xfs_qoff_logitem *);
51
52#endif /* __XFS_DQUOT_ITEM_H__ */