Lines 75-84
static int HgfsPackSymlinkCreateRequest(
Link Here
|
75 |
static int HgfsCreate(struct inode *dir, |
75 |
static int HgfsCreate(struct inode *dir, |
76 |
struct dentry *dentry, |
76 |
struct dentry *dentry, |
77 |
compat_umode_t mode, |
77 |
compat_umode_t mode, |
|
|
78 |
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 6, 0) |
79 |
bool excl); |
80 |
#else |
78 |
struct nameidata *nd); |
81 |
struct nameidata *nd); |
|
|
82 |
#endif |
79 |
static struct dentry *HgfsLookup(struct inode *dir, |
83 |
static struct dentry *HgfsLookup(struct inode *dir, |
80 |
struct dentry *dentry, |
84 |
struct dentry *dentry, |
|
|
85 |
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 6, 0) |
86 |
unsigned int flags); |
87 |
#else |
81 |
struct nameidata *nd); |
88 |
struct nameidata *nd); |
|
|
89 |
#endif |
82 |
static int HgfsMkdir(struct inode *dir, |
90 |
static int HgfsMkdir(struct inode *dir, |
83 |
struct dentry *dentry, |
91 |
struct dentry *dentry, |
84 |
compat_umode_t mode); |
92 |
compat_umode_t mode); |
Lines 952-958
static int
Link Here
|
952 |
HgfsCreate(struct inode *dir, // IN: Parent dir to create in |
960 |
HgfsCreate(struct inode *dir, // IN: Parent dir to create in |
953 |
struct dentry *dentry, // IN: Dentry containing name to create |
961 |
struct dentry *dentry, // IN: Dentry containing name to create |
954 |
compat_umode_t mode, // IN: Mode of file to be created |
962 |
compat_umode_t mode, // IN: Mode of file to be created |
|
|
963 |
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 6, 0) |
964 |
bool excl) |
965 |
#else |
955 |
struct nameidata *nd) // IN: Intent, vfsmount, ... |
966 |
struct nameidata *nd) // IN: Intent, vfsmount, ... |
|
|
967 |
#endif |
956 |
{ |
968 |
{ |
957 |
HgfsAttrInfo attr; |
969 |
HgfsAttrInfo attr; |
958 |
int result; |
970 |
int result; |
Lines 1025-1031
HgfsCreate(struct inode *dir, // IN:
Link Here
|
1025 |
static struct dentry * |
1037 |
static struct dentry * |
1026 |
HgfsLookup(struct inode *dir, // IN: Inode of parent directory |
1038 |
HgfsLookup(struct inode *dir, // IN: Inode of parent directory |
1027 |
struct dentry *dentry, // IN: Dentry containing name to look up |
1039 |
struct dentry *dentry, // IN: Dentry containing name to look up |
|
|
1040 |
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 6, 0) |
1041 |
unsigned int flags) |
1042 |
#else |
1028 |
struct nameidata *nd) // IN: Intent, vfsmount, ... |
1043 |
struct nameidata *nd) // IN: Intent, vfsmount, ... |
|
|
1044 |
#endif |
1029 |
{ |
1045 |
{ |
1030 |
HgfsAttrInfo attr; |
1046 |
HgfsAttrInfo attr; |
1031 |
struct inode *inode; |
1047 |
struct inode *inode; |
Lines 1801-1807
HgfsPermission(struct inode *inode,
Link Here
|
1801 |
#else |
1817 |
#else |
1802 |
if (mask & MAY_ACCESS) { /* For sys_access. */ |
1818 |
if (mask & MAY_ACCESS) { /* For sys_access. */ |
1803 |
#endif |
1819 |
#endif |
|
|
1820 |
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 6, 0) |
1821 |
struct hlist_node *p; |
1822 |
#else |
1804 |
struct list_head *pos; |
1823 |
struct list_head *pos; |
|
|
1824 |
#endif |
1805 |
int dcount = 0; |
1825 |
int dcount = 0; |
1806 |
struct dentry *dentry = NULL; |
1826 |
struct dentry *dentry = NULL; |
1807 |
|
1827 |
|
Lines 1817-1824
HgfsPermission(struct inode *inode,
Link Here
|
1817 |
#endif |
1837 |
#endif |
1818 |
|
1838 |
|
1819 |
/* Find a dentry with valid d_count. Refer bug 587789. */ |
1839 |
/* Find a dentry with valid d_count. Refer bug 587789. */ |
|
|
1840 |
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 6, 0) |
1841 |
hlist_for_each_entry(dentry, p, &inode->i_dentry, d_alias) { |
1842 |
#else |
1820 |
list_for_each(pos, &inode->i_dentry) { |
1843 |
list_for_each(pos, &inode->i_dentry) { |
1821 |
dentry = list_entry(pos, struct dentry, d_alias); |
1844 |
dentry = list_entry(pos, struct dentry, d_alias); |
|
|
1845 |
#endif |
1822 |
#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 38) |
1846 |
#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 38) |
1823 |
dcount = atomic_read(&dentry->d_count); |
1847 |
dcount = atomic_read(&dentry->d_count); |
1824 |
#else |
1848 |
#else |