Skip to content

Commit

Permalink
Btrfs: use plain page_address() in header fields setget functions
Browse files Browse the repository at this point in the history
We've stopped using highmem for extent buffers.

Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Signed-off-by: Chris Mason <chris.mason@oracle.com>
  • Loading branch information
Li Zefan authored and Chris Mason committed Aug 17, 2011
1 parent cb1b69f commit c97c291
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions fs/btrfs/ctree.h
Original file line number Diff line number Diff line change
Expand Up @@ -1415,17 +1415,15 @@ void btrfs_set_##name(struct extent_buffer *eb, type *s, u##bits val);
#define BTRFS_SETGET_HEADER_FUNCS(name, type, member, bits) \
static inline u##bits btrfs_##name(struct extent_buffer *eb) \
{ \
type *p = kmap_atomic(eb->first_page, KM_USER0); \
type *p = page_address(eb->first_page); \
u##bits res = le##bits##_to_cpu(p->member); \
kunmap_atomic(p, KM_USER0); \
return res; \
} \
static inline void btrfs_set_##name(struct extent_buffer *eb, \
u##bits val) \
{ \
type *p = kmap_atomic(eb->first_page, KM_USER0); \
type *p = page_address(eb->first_page); \
p->member = cpu_to_le##bits(val); \
kunmap_atomic(p, KM_USER0); \
}

#define BTRFS_SETGET_STACK_FUNCS(name, type, member, bits) \
Expand Down

0 comments on commit c97c291

Please sign in to comment.