You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
xfs: pass xfs_dquot to xfs_qm_adjust_dqlimits() instead of xfs_disk_dquot_t
Modify xfs_qm_adjust_dqlimits() to take the xfs_dquot as a parameter instead of just the xfs_disk_dquot_t so we can update in-memory fields if necessary. Signed-off-by: Brian Foster <bfoster@redhat.com> Reviewed-by: Mark Tinguely <tinguely@sgi.com> Signed-off-by: Ben Myers <bpm@sgi.com>
This commit is contained in:
+4
-3
@@ -85,10 +85,11 @@ xfs_qm_dqdestroy(
|
|||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
xfs_qm_adjust_dqlimits(
|
xfs_qm_adjust_dqlimits(
|
||||||
xfs_mount_t *mp,
|
struct xfs_mount *mp,
|
||||||
xfs_disk_dquot_t *d)
|
struct xfs_dquot *dq)
|
||||||
{
|
{
|
||||||
xfs_quotainfo_t *q = mp->m_quotainfo;
|
struct xfs_quotainfo *q = mp->m_quotainfo;
|
||||||
|
struct xfs_disk_dquot *d = &dq->q_core;
|
||||||
|
|
||||||
ASSERT(d->d_id);
|
ASSERT(d->d_id);
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -145,8 +145,8 @@ extern int xfs_qm_dqflush(struct xfs_dquot *, struct xfs_buf **);
|
|||||||
extern void xfs_qm_dqunpin_wait(xfs_dquot_t *);
|
extern void xfs_qm_dqunpin_wait(xfs_dquot_t *);
|
||||||
extern void xfs_qm_adjust_dqtimers(xfs_mount_t *,
|
extern void xfs_qm_adjust_dqtimers(xfs_mount_t *,
|
||||||
xfs_disk_dquot_t *);
|
xfs_disk_dquot_t *);
|
||||||
extern void xfs_qm_adjust_dqlimits(xfs_mount_t *,
|
extern void xfs_qm_adjust_dqlimits(struct xfs_mount *,
|
||||||
xfs_disk_dquot_t *);
|
struct xfs_dquot *);
|
||||||
extern int xfs_qm_dqget(xfs_mount_t *, xfs_inode_t *,
|
extern int xfs_qm_dqget(xfs_mount_t *, xfs_inode_t *,
|
||||||
xfs_dqid_t, uint, uint, xfs_dquot_t **);
|
xfs_dqid_t, uint, uint, xfs_dquot_t **);
|
||||||
extern void xfs_qm_dqput(xfs_dquot_t *);
|
extern void xfs_qm_dqput(xfs_dquot_t *);
|
||||||
|
|||||||
+1
-1
@@ -1057,7 +1057,7 @@ xfs_qm_quotacheck_dqadjust(
|
|||||||
* There are no timers for the default values set in the root dquot.
|
* There are no timers for the default values set in the root dquot.
|
||||||
*/
|
*/
|
||||||
if (dqp->q_core.d_id) {
|
if (dqp->q_core.d_id) {
|
||||||
xfs_qm_adjust_dqlimits(mp, &dqp->q_core);
|
xfs_qm_adjust_dqlimits(mp, dqp);
|
||||||
xfs_qm_adjust_dqtimers(mp, &dqp->q_core);
|
xfs_qm_adjust_dqtimers(mp, &dqp->q_core);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -326,12 +326,12 @@ xfs_trans_dqlockedjoin(
|
|||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
xfs_trans_apply_dquot_deltas(
|
xfs_trans_apply_dquot_deltas(
|
||||||
xfs_trans_t *tp)
|
struct xfs_trans *tp)
|
||||||
{
|
{
|
||||||
int i, j;
|
int i, j;
|
||||||
xfs_dquot_t *dqp;
|
struct xfs_dquot *dqp;
|
||||||
xfs_dqtrx_t *qtrx, *qa;
|
struct xfs_dqtrx *qtrx, *qa;
|
||||||
xfs_disk_dquot_t *d;
|
struct xfs_disk_dquot *d;
|
||||||
long totalbdelta;
|
long totalbdelta;
|
||||||
long totalrtbdelta;
|
long totalrtbdelta;
|
||||||
|
|
||||||
@@ -412,7 +412,7 @@ xfs_trans_apply_dquot_deltas(
|
|||||||
* Start/reset the timer(s) if needed.
|
* Start/reset the timer(s) if needed.
|
||||||
*/
|
*/
|
||||||
if (d->d_id) {
|
if (d->d_id) {
|
||||||
xfs_qm_adjust_dqlimits(tp->t_mountp, d);
|
xfs_qm_adjust_dqlimits(tp->t_mountp, dqp);
|
||||||
xfs_qm_adjust_dqtimers(tp->t_mountp, d);
|
xfs_qm_adjust_dqtimers(tp->t_mountp, d);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user