]>
Commit | Line | Data |
---|---|---|
00e5a55c BS |
1 | From fab7b7090ac16e340e35e2bd0a64afe7a7f068ef Mon Sep 17 00:00:00 2001 |
2 | From: Jan Kara <jack@suse.cz> | |
3 | Date: Wed, 15 Jul 2009 13:21:53 +0200 | |
4 | Subject: [PATCH 6/6] ocfs2: Remove syncjiff field from quota info | |
5 | ||
6 | syncjiff is just a converted value of syncms. Some places which | |
7 | are updating syncms forgot to update syncjiff as well. Since the | |
8 | conversion is just a simple division / multiplication and it does | |
9 | not happen frequently, just remove the syncjiff field to avoid | |
10 | forgotten conversions. | |
11 | ||
12 | Signed-off-by: Jan Kara <jack@suse.cz> | |
13 | --- | |
14 | fs/ocfs2/aops.c | 4 +++- | |
15 | fs/ocfs2/quota.h | 1 - | |
16 | fs/ocfs2/quota_global.c | 5 ++--- | |
17 | 3 files changed, 5 insertions(+), 5 deletions(-) | |
18 | ||
19 | Index: linux-2.6.27-SLE11_BRANCH/fs/ocfs2/aops.c | |
20 | =================================================================== | |
21 | --- linux-2.6.27-SLE11_BRANCH.orig/fs/ocfs2/aops.c 2009-07-16 13:16:26.000000000 +0200 | |
22 | +++ linux-2.6.27-SLE11_BRANCH/fs/ocfs2/aops.c 2009-07-16 14:03:35.000000000 +0200 | |
23 | @@ -145,9 +145,11 @@ | |
24 | mlog_entry("(0x%p, %llu, 0x%p, %d)\n", inode, | |
25 | (unsigned long long)iblock, bh_result, create); | |
26 | ||
27 | - if (OCFS2_I(inode)->ip_flags & OCFS2_INODE_SYSTEM_FILE) | |
28 | + if (OCFS2_I(inode)->ip_flags & OCFS2_INODE_SYSTEM_FILE) { | |
29 | mlog(ML_NOTICE, "get_block on system inode 0x%p (%lu)\n", | |
30 | inode, inode->i_ino); | |
31 | + dump_stack(); | |
32 | + } | |
33 | ||
34 | if (S_ISLNK(inode->i_mode)) { | |
35 | /* this always does I/O for some reason. */ | |
36 | Index: linux-2.6.27-SLE11_BRANCH/fs/ocfs2/quota.h | |
37 | =================================================================== | |
38 | --- linux-2.6.27-SLE11_BRANCH.orig/fs/ocfs2/quota.h 2009-07-16 13:16:26.000000000 +0200 | |
39 | +++ linux-2.6.27-SLE11_BRANCH/fs/ocfs2/quota.h 2009-07-16 14:03:35.000000000 +0200 | |
40 | @@ -55,7 +55,6 @@ | |
41 | unsigned int dqi_chunks; /* Number of chunks in local quota file */ | |
42 | unsigned int dqi_blocks; /* Number of blocks allocated for local quota file */ | |
43 | unsigned int dqi_syncms; /* How often should we sync with other nodes */ | |
44 | - unsigned int dqi_syncjiff; /* Precomputed dqi_syncms in jiffies */ | |
45 | struct list_head dqi_chunk; /* List of chunks */ | |
46 | struct inode *dqi_gqinode; /* Global quota file inode */ | |
47 | struct ocfs2_lock_res dqi_gqlock; /* Lock protecting quota information structure */ | |
48 | Index: linux-2.6.27-SLE11_BRANCH/fs/ocfs2/quota_global.c | |
49 | =================================================================== | |
50 | --- linux-2.6.27-SLE11_BRANCH.orig/fs/ocfs2/quota_global.c 2009-07-16 13:25:41.000000000 +0200 | |
51 | +++ linux-2.6.27-SLE11_BRANCH/fs/ocfs2/quota_global.c 2009-07-16 14:04:51.000000000 +0200 | |
52 | @@ -277,7 +277,6 @@ | |
53 | info->dqi_bgrace = le32_to_cpu(dinfo.dqi_bgrace); | |
54 | info->dqi_igrace = le32_to_cpu(dinfo.dqi_igrace); | |
55 | oinfo->dqi_syncms = le32_to_cpu(dinfo.dqi_syncms); | |
56 | - oinfo->dqi_syncjiff = msecs_to_jiffies(oinfo->dqi_syncms); | |
57 | oinfo->dqi_gi.dqi_blocks = le32_to_cpu(dinfo.dqi_blocks); | |
58 | oinfo->dqi_gi.dqi_free_blk = le32_to_cpu(dinfo.dqi_free_blk); | |
59 | oinfo->dqi_gi.dqi_free_entry = le32_to_cpu(dinfo.dqi_free_entry); | |
60 | @@ -288,7 +287,7 @@ | |
61 | setup_timer(&oinfo->dqi_sync_timer, qsync_timer_fn, | |
62 | (unsigned long)oinfo); | |
63 | mod_timer(&oinfo->dqi_sync_timer, | |
64 | - round_jiffies(jiffies + oinfo->dqi_syncjiff)); | |
65 | + round_jiffies(jiffies+msecs_to_jiffies(oinfo->dqi_syncms))); | |
66 | out_err: | |
67 | mlog_exit(status); | |
68 | return status; | |
69 | @@ -547,7 +546,7 @@ | |
70 | ||
71 | pdflush_operation(ocfs2_do_qsync, oinfo_ptr); | |
72 | mod_timer(&oinfo->dqi_sync_timer, | |
73 | - round_jiffies(jiffies + oinfo->dqi_syncjiff)); | |
74 | + round_jiffies(jiffies+msecs_to_jiffies(oinfo->dqi_syncms))); | |
75 | } | |
76 | ||
77 | /* |