After updating to kernel 3.19 the virtualbox-guest-additions-4.3.20 package failed to compile. The compiler error is: "'struct file' has no member named 'f_dentry'" The reason is that the API has changed with kernel 3.19 [1]. The struct access f->f_dentry->d_inode was replaced by the accessor function file_inode(f). The "works for me" patch looks like this: --- src/VBox/Additions/linux/sharedfolders/dirops.c~ 2015-02-11 09:50:42.528112663 +0100 +++ src/VBox/Additions/linux/sharedfolders/dirops.c 2015-02-11 09:37:14.232081996 +0100 @@ -126,13 +126,13 @@ TRACE(); - sf_g = GET_GLOB_INFO(dir->f_dentry->d_inode->i_sb); + sf_g = GET_GLOB_INFO(file_inode(dir)->i_sb); sf_d = dir->private_data; BUG_ON(!sf_g); BUG_ON(!sf_d); - inode = dir->f_dentry->d_inode; + inode = file_inode(dir); sf_i = GET_INODE_INFO(inode); BUG_ON(!sf_i); --- src/VBox/Additions/linux/sharedfolders/regops.c~ 2015-02-11 09:50:47.272112843 +0100 +++ src/VBox/Additions/linux/sharedfolders/regops.c 2015-02-11 09:37:20.268082225 +0100 @@ -108,7 +108,7 @@ size_t tmp_size; size_t left = size; ssize_t total_bytes_read = 0; - struct inode *inode = file->f_dentry->d_inode; + struct inode *inode = file_inode(file); struct sf_glob_info *sf_g = GET_GLOB_INFO(inode->i_sb); struct sf_reg_info *sf_r = file->private_data; loff_t pos = *off; @@ -183,7 +183,7 @@ size_t tmp_size; size_t left = size; ssize_t total_bytes_written = 0; - struct inode *inode = file->f_dentry->d_inode; + struct inode *inode = file_inode(file); struct sf_inode_info *sf_i = GET_INODE_INFO(inode); struct sf_glob_info *sf_g = GET_GLOB_INFO(inode->i_sb); struct sf_reg_info *sf_r = file->private_data; @@ -465,7 +465,7 @@ uint32_t nread = PAGE_SIZE; int err; struct file *file = vma->vm_file; - struct inode *inode = file->f_dentry->d_inode; + struct inode *inode = file_inode(file); struct sf_glob_info *sf_g = GET_GLOB_INFO(inode->i_sb); struct sf_reg_info *sf_r = file->private_data; @@ -605,7 +605,7 @@ #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 0) static int sf_readpage(struct file *file, struct page *page) { - struct inode *inode = file->f_dentry->d_inode; + struct inode *inode = file_inode(file); struct sf_glob_info *sf_g = GET_GLOB_INFO(inode->i_sb); struct sf_reg_info *sf_r = file->private_data; uint32_t nread = PAGE_SIZE; [1] https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=496ad9aa8ef448058e36ca7a787c61f2e63f0f54 Reproducible: Always
Upstream bug[1] was fixed at virtualbox-4.3.22. See [2]. ----- [1] https://www.virtualbox.org/ticket/13741 [2] https://www.virtualbox.org/wiki/Changelog
Fixed with latest virtualbox versions.