summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--extent-tree.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/extent-tree.c b/extent-tree.c
index e4883903..a89f525c 100644
--- a/extent-tree.c
+++ b/extent-tree.c
@@ -18,6 +18,7 @@
#include <stdio.h>
#include <stdlib.h>
+#include <stdint.h>
#include "kerncompat.h"
#include "radix-tree.h"
#include "ctree.h"
@@ -3103,7 +3104,8 @@ int btrfs_free_block_groups(struct btrfs_fs_info *info)
break;
ret = get_state_private(&info->block_group_cache, start, &ptr);
if (!ret) {
- cache = (struct btrfs_block_group_cache *)ptr;
+ cache = (struct btrfs_block_group_cache *)
+ (uintptr_t)ptr;
if (cache->free_space_ctl) {
btrfs_remove_free_space_cache(cache);
kfree(cache->free_space_ctl);