]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - fs/xfs/xfs_dir2_data.c
ACPI: check a return value correctly in acpi_power_get_context()
[linux-2.6-omap-h63xx.git] / fs / xfs / xfs_dir2_data.c
index 7ebe295bd6d3bf459836a72a0cca4b1b6fd7ef8b..fb8c9e08b23db9bf94151bbf86a45feccdf0d676 100644 (file)
@@ -22,6 +22,7 @@
 #include "xfs_inum.h"
 #include "xfs_trans.h"
 #include "xfs_sb.h"
+#include "xfs_ag.h"
 #include "xfs_dir2.h"
 #include "xfs_dmapi.h"
 #include "xfs_mount.h"
@@ -586,7 +587,7 @@ xfs_dir2_data_make_free(
                /*
                 * Fix up the new big freespace.
                 */
-               be16_add(&prevdup->length, len + be16_to_cpu(postdup->length));
+               be16_add_cpu(&prevdup->length, len + be16_to_cpu(postdup->length));
                *xfs_dir2_data_unused_tag_p(prevdup) =
                        cpu_to_be16((char *)prevdup - (char *)d);
                xfs_dir2_data_log_unused(tp, bp, prevdup);
@@ -620,7 +621,7 @@ xfs_dir2_data_make_free(
         */
        else if (prevdup) {
                dfp = xfs_dir2_data_freefind(d, prevdup);
-               be16_add(&prevdup->length, len);
+               be16_add_cpu(&prevdup->length, len);
                *xfs_dir2_data_unused_tag_p(prevdup) =
                        cpu_to_be16((char *)prevdup - (char *)d);
                xfs_dir2_data_log_unused(tp, bp, prevdup);