SOURCES: shfs-d_entry.patch - Adjust patch to work also with kerne...
japhy
japhy at pld-linux.org
Wed May 10 15:38:22 CEST 2006
Author: japhy Date: Wed May 10 13:38:22 2006 GMT
Module: SOURCES Tag: HEAD
---- Log message:
- Adjust patch to work also with kernel < 2.6.16
---- Files affected:
SOURCES:
shfs-d_entry.patch (1.1 -> 1.2)
---- Diffs:
================================================================
Index: SOURCES/shfs-d_entry.patch
diff -u SOURCES/shfs-d_entry.patch:1.1 SOURCES/shfs-d_entry.patch:1.2
--- SOURCES/shfs-d_entry.patch:1.1 Mon May 8 17:33:29 2006
+++ SOURCES/shfs-d_entry.patch Wed May 10 15:38:17 2006
@@ -1,20 +1,34 @@
---- shfs/Linux-2.6/dcache.c 2004-06-01 15:16:19.000000000 +0200
-+++ shfs/Linux-2.6/dcache.c 2006-02-17 17:36:02.000000000 +0100
-@@ -68,7 +68,7 @@
+--- shfs-0.35-vanilla/shfs/Linux-2.6/dcache.c 2004-06-01 15:16:19.000000000 +0200
++++ shfs-0.35/shfs/Linux-2.6/dcache.c 2006-05-10 15:34:39.000000000 +0200
+@@ -19,6 +19,7 @@
+ #include <linux/mm.h>
+ #include <linux/dirent.h>
+ #include <linux/pagemap.h>
++#include <linux/version.h>
+ #include <asm/page.h>
+
+ #include "shfs_fs.h"
+@@ -68,7 +69,11 @@
spin_lock(&dcache_lock);
next = parent->d_subdirs.next;
while (next != &parent->d_subdirs) {
-- dentry = list_entry(next, struct dentry, d_child);
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16))
+ dentry = list_entry(next, struct dentry, d_u.d_child);
++#else
+ dentry = list_entry(next, struct dentry, d_child);
++#endif
dentry->d_fsdata = NULL;
shfs_age_dentry(info, dentry);
next = next->next;
-@@ -101,7 +101,7 @@
+@@ -101,7 +106,11 @@
spin_lock(&dcache_lock);
next = parent->d_subdirs.next;
while (next != &parent->d_subdirs) {
-- dent = list_entry(next, struct dentry, d_child);
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16))
+ dent = list_entry(next, struct dentry, d_u.d_child);
++#else
+ dent = list_entry(next, struct dentry, d_child);
++#endif
if ((unsigned long)dent->d_fsdata == fpos) {
if (dent->d_inode)
dget_locked(dent);
================================================================
---- CVS-web:
http://cvs.pld-linux.org/SOURCES/shfs-d_entry.patch?r1=1.1&r2=1.2&f=u
More information about the pld-cvs-commit
mailing list