From: Will Deacon Date: Thu, 12 Dec 2013 17:40:21 +0000 (+0000) Subject: dcache: allow word-at-a-time name hashing with big-endian CPUs X-Git-Tag: v3.13-rc4~29 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a5c21dcefa1c3d759457a604b3cfc4af29c8713f;p=pandora-kernel.git dcache: allow word-at-a-time name hashing with big-endian CPUs When explicitly hashing the end of a string with the word-at-a-time interface, we have to be careful which end of the word we pick up. On big-endian CPUs, the upper-bits will contain the data we're after, so ensure we generate our masks accordingly (and avoid hashing whatever random junk may have been sitting after the string). This patch adds a new dcache helper, bytemask_from_count, which creates a mask appropriate for the CPU endianness. Cc: Al Viro Signed-off-by: Will Deacon Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed