diff options
author | Christoph Hellwig <hch@sgi.com> | 2005-11-01 18:21:14 -0500 |
---|---|---|
committer | Nathan Scott <nathans@sgi.com> | 2005-11-01 18:21:14 -0500 |
commit | 88741a95af0ecf3a745051bdc1d16897d3990cec (patch) | |
tree | e5a77a0b6e71629e299e161c39294760cc07e6a7 /fs/xfs/linux-2.6/xfs_buf.c | |
parent | 04d8b2841630b793919cc1ece9e77ac4de338c9e (diff) |
[XFS] remove unused pagebuf flags
SGI-PV: 908809
SGI-Modid: xfs-linux:xfs-kern:198656a
Signed-off-by: Christoph Hellwig <hch@sgi.com>
Signed-off-by: Nathan Scott <nathans@sgi.com>
Diffstat (limited to 'fs/xfs/linux-2.6/xfs_buf.c')
-rw-r--r-- | fs/xfs/linux-2.6/xfs_buf.c | 24 |
1 files changed, 7 insertions, 17 deletions
diff --git a/fs/xfs/linux-2.6/xfs_buf.c b/fs/xfs/linux-2.6/xfs_buf.c index 43128395d63b..489b7f63fd1f 100644 --- a/fs/xfs/linux-2.6/xfs_buf.c +++ b/fs/xfs/linux-2.6/xfs_buf.c | |||
@@ -458,14 +458,7 @@ _pagebuf_lookup_pages( | |||
458 | unlock_page(bp->pb_pages[i]); | 458 | unlock_page(bp->pb_pages[i]); |
459 | } | 459 | } |
460 | 460 | ||
461 | if (page_count) { | 461 | bp->pb_flags &= ~PBF_NONE; |
462 | /* if we have any uptodate pages, mark that in the buffer */ | ||
463 | bp->pb_flags &= ~PBF_NONE; | ||
464 | |||
465 | /* if some pages aren't uptodate, mark that in the buffer */ | ||
466 | if (page_count != bp->pb_page_count) | ||
467 | bp->pb_flags |= PBF_PARTIAL; | ||
468 | } | ||
469 | 462 | ||
470 | PB_TRACE(bp, "lookup_pages", (long)page_count); | 463 | PB_TRACE(bp, "lookup_pages", (long)page_count); |
471 | return error; | 464 | return error; |
@@ -676,7 +669,7 @@ xfs_buf_read_flags( | |||
676 | 669 | ||
677 | pb = xfs_buf_get_flags(target, ioff, isize, flags); | 670 | pb = xfs_buf_get_flags(target, ioff, isize, flags); |
678 | if (pb) { | 671 | if (pb) { |
679 | if (PBF_NOT_DONE(pb)) { | 672 | if (!XFS_BUF_ISDONE(pb)) { |
680 | PB_TRACE(pb, "read", (unsigned long)flags); | 673 | PB_TRACE(pb, "read", (unsigned long)flags); |
681 | XFS_STATS_INC(pb_get_read); | 674 | XFS_STATS_INC(pb_get_read); |
682 | pagebuf_iostart(pb, flags); | 675 | pagebuf_iostart(pb, flags); |
@@ -813,7 +806,7 @@ pagebuf_get_no_daddr( | |||
813 | bp = pagebuf_allocate(0); | 806 | bp = pagebuf_allocate(0); |
814 | if (unlikely(bp == NULL)) | 807 | if (unlikely(bp == NULL)) |
815 | goto fail; | 808 | goto fail; |
816 | _pagebuf_initialize(bp, target, 0, len, PBF_FORCEIO); | 809 | _pagebuf_initialize(bp, target, 0, len, 0); |
817 | 810 | ||
818 | try_again: | 811 | try_again: |
819 | data = kmem_alloc(malloc_len, KM_SLEEP | KM_MAYFAIL); | 812 | data = kmem_alloc(malloc_len, KM_SLEEP | KM_MAYFAIL); |
@@ -1121,21 +1114,18 @@ pagebuf_iodone_work( | |||
1121 | void | 1114 | void |
1122 | pagebuf_iodone( | 1115 | pagebuf_iodone( |
1123 | xfs_buf_t *pb, | 1116 | xfs_buf_t *pb, |
1124 | int dataio, | ||
1125 | int schedule) | 1117 | int schedule) |
1126 | { | 1118 | { |
1127 | pb->pb_flags &= ~(PBF_READ | PBF_WRITE); | 1119 | pb->pb_flags &= ~(PBF_READ | PBF_WRITE); |
1128 | if (pb->pb_error == 0) { | 1120 | if (pb->pb_error == 0) |
1129 | pb->pb_flags &= ~(PBF_PARTIAL | PBF_NONE); | 1121 | pb->pb_flags &= ~PBF_NONE; |
1130 | } | ||
1131 | 1122 | ||
1132 | PB_TRACE(pb, "iodone", pb->pb_iodone); | 1123 | PB_TRACE(pb, "iodone", pb->pb_iodone); |
1133 | 1124 | ||
1134 | if ((pb->pb_iodone) || (pb->pb_flags & PBF_ASYNC)) { | 1125 | if ((pb->pb_iodone) || (pb->pb_flags & PBF_ASYNC)) { |
1135 | if (schedule) { | 1126 | if (schedule) { |
1136 | INIT_WORK(&pb->pb_iodone_work, pagebuf_iodone_work, pb); | 1127 | INIT_WORK(&pb->pb_iodone_work, pagebuf_iodone_work, pb); |
1137 | queue_work(dataio ? xfsdatad_workqueue : | 1128 | queue_work(xfslogd_workqueue, &pb->pb_iodone_work); |
1138 | xfslogd_workqueue, &pb->pb_iodone_work); | ||
1139 | } else { | 1129 | } else { |
1140 | pagebuf_iodone_work(pb); | 1130 | pagebuf_iodone_work(pb); |
1141 | } | 1131 | } |
@@ -1235,7 +1225,7 @@ _pagebuf_iodone( | |||
1235 | { | 1225 | { |
1236 | if (atomic_dec_and_test(&pb->pb_io_remaining) == 1) { | 1226 | if (atomic_dec_and_test(&pb->pb_io_remaining) == 1) { |
1237 | pb->pb_locked = 0; | 1227 | pb->pb_locked = 0; |
1238 | pagebuf_iodone(pb, (pb->pb_flags & PBF_FS_DATAIOD), schedule); | 1228 | pagebuf_iodone(pb, schedule); |
1239 | } | 1229 | } |
1240 | } | 1230 | } |
1241 | 1231 | ||