summaryrefslogtreecommitdiffstats
path: root/src/client/Fh.h
diff options
context:
space:
mode:
authorAdam Crume <adamcrume@gmail.com>2014-09-16 03:17:24 +0200
committerAdam Crume <adamcrume@gmail.com>2014-09-17 21:02:18 +0200
commit95ee69989129750fddce6a3b5644238c4b88ed74 (patch)
tree9e07a33abb2b5f03f5e3b0e6118459b30e4dbd51 /src/client/Fh.h
parentlibrbd: Add read-ahead (diff)
downloadceph-95ee69989129750fddce6a3b5644238c4b88ed74.tar.xz
ceph-95ee69989129750fddce6a3b5644238c4b88ed74.zip
client: Replace client readahead logic with Readahead
Signed-off-by: Adam Crume <adamcrume@gmail.com>
Diffstat (limited to 'src/client/Fh.h')
-rw-r--r--src/client/Fh.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/client/Fh.h b/src/client/Fh.h
index 235b244b401..a4050a78480 100644
--- a/src/client/Fh.h
+++ b/src/client/Fh.h
@@ -1,6 +1,7 @@
#ifndef CEPH_CLIENT_FH_H
#define CEPH_CLIENT_FH_H
+#include "common/Readahead.h"
#include "include/types.h"
struct Inode;
@@ -18,13 +19,10 @@ struct Fh {
bool pos_locked; // pos is currently in use
list<Cond*> pos_waiters; // waiters for pos
- // readahead state
- loff_t last_pos;
- loff_t consec_read_bytes;
- int nr_consec_read;
+ Readahead readahead;
Fh() : inode(0), pos(0), mds(0), mode(0), flags(0), pos_locked(false),
- last_pos(0), consec_read_bytes(0), nr_consec_read(0) {}
+ readahead() {}
};