aboutsummaryrefslogtreecommitdiff
path: root/fs/sdfat
diff options
context:
space:
mode:
authorPaul Keith <javelinanddart@gmail.com>2018-02-19 18:04:06 +0100
committerMoyster <oysterized@gmail.com>2018-12-02 01:33:10 +0100
commit1bf12021da32d0549ccb29f024f226afc3c35f69 (patch)
tree0460e1f60666ab8e81e85c2a207ce1b857bcb7f5 /fs/sdfat
parent06f1c035067f79bc31f17ca77fea81d5b502fc09 (diff)
fs: sdfat: Fix compilation on Linux 3.4
Change-Id: I3a500f03f399abc9af9586e80419d75aca5b4320 Signed-off-by: Paul Keith <javelinanddart@gmail.com>
Diffstat (limited to 'fs/sdfat')
-rw-r--r--fs/sdfat/sdfat.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/sdfat/sdfat.c b/fs/sdfat/sdfat.c
index 49bc22ff7..060418bed 100644
--- a/fs/sdfat/sdfat.c
+++ b/fs/sdfat/sdfat.c
@@ -2423,7 +2423,11 @@ static struct dentry *__sdfat_lookup(struct inode *dir, struct dentry *dentry)
* In such case, we reuse an alias instead of new dentry
*/
if (d_unhashed(alias)) {
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0)
+ BUG_ON(alias->d_name.hash != dentry->d_name.hash && alias->d_name.len != dentry->d_name.len);
+#else
BUG_ON(alias->d_name.hash_len != dentry->d_name.hash_len);
+#endif
sdfat_msg(sb, KERN_INFO, "rehashed a dentry(%p) "
"in read lookup", alias);
d_drop(dentry);