--- libxfs/xfs_attr_remote.c.orig
+++ libxfs/xfs_attr_remote.c
@@ -17,6 +17,7 @@
  * Inc.,  51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
  */
 #include <xfs.h>
+#include <linux/limits.h>
 
 #define ATTR_RMTVALUE_MAPSIZE	1	/* # of map entries at once */
 
