]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - lib/radix-tree.c
[ARM] 3917/1: Fix dmabounce symbol exports
[linux-2.6-omap-h63xx.git] / lib / radix-tree.c
index b32efae7688e316e8825df6fd76a316a2c6f18bf..aa9bfd0bdbd1bd720ed1eb8c5416b180bad3b98a 100644 (file)
@@ -160,13 +160,13 @@ static inline int tag_get(struct radix_tree_node *node, unsigned int tag,
 
 static inline void root_tag_set(struct radix_tree_root *root, unsigned int tag)
 {
-       root->gfp_mask |= (1 << (tag + __GFP_BITS_SHIFT));
+       root->gfp_mask |= (__force gfp_t)(1 << (tag + __GFP_BITS_SHIFT));
 }
 
 
 static inline void root_tag_clear(struct radix_tree_root *root, unsigned int tag)
 {
-       root->gfp_mask &= ~(1 << (tag + __GFP_BITS_SHIFT));
+       root->gfp_mask &= (__force gfp_t)~(1 << (tag + __GFP_BITS_SHIFT));
 }
 
 static inline void root_tag_clear_all(struct radix_tree_root *root)
@@ -176,7 +176,7 @@ static inline void root_tag_clear_all(struct radix_tree_root *root)
 
 static inline int root_tag_get(struct radix_tree_root *root, unsigned int tag)
 {
-       return root->gfp_mask & (1 << (tag + __GFP_BITS_SHIFT));
+       return (__force unsigned)root->gfp_mask & (1 << (tag + __GFP_BITS_SHIFT));
 }
 
 /*
@@ -530,7 +530,7 @@ int radix_tree_tag_get(struct radix_tree_root *root,
                        int ret = tag_get(slot, tag, offset);
 
                        BUG_ON(ret && saw_unset_tag);
-                       return ret;
+                       return !!ret;
                }
                slot = slot->slots[offset];
                shift -= RADIX_TREE_MAP_SHIFT;