VirtualBox

Ignore:
Timestamp:
Mar 15, 2019 1:49:43 AM (6 years ago)
Author:
vboxsync
Message:

linux/vboxsf: Use 'VBox' as f_type value. NFS_SUPER_MAGIC confuses umount from the debian mount package v2.25.2-6 (debian 8). bugref:9172

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/linux/sharedfolders/vfsmod.c

    r77626 r77709  
    5353#include <linux/seq_file.h>
    5454#include <linux/vfs.h>
    55 #include <linux/nfs_fs.h> /* for NFS_SUPER_MAGIC */
    5655#include <iprt/path.h>
    5756
     
    577576        rc = VbglR0SfHostReqQueryVolInfo(sf_g->map.root, pReq, SHFL_HANDLE_ROOT);
    578577        if (RT_SUCCESS(rc)) {
    579             stat->f_type   = NFS_SUPER_MAGIC; /** @todo vboxsf type? */
     578            stat->f_type   = UINT32_C(0x786f4256); /* 'VBox' little endian */
    580579            stat->f_bsize  = pVolInfo->ulBytesPerAllocationUnit;
    581580#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 5, 73)
     
    583582#endif
    584583            stat->f_blocks = pVolInfo->ullTotalAllocationBytes
    585                        / pVolInfo->ulBytesPerAllocationUnit;
     584                           / pVolInfo->ulBytesPerAllocationUnit;
    586585            stat->f_bfree  = pVolInfo->ullAvailableAllocationBytes
    587                        / pVolInfo->ulBytesPerAllocationUnit;
     586                           / pVolInfo->ulBytesPerAllocationUnit;
    588587            stat->f_bavail = pVolInfo->ullAvailableAllocationBytes
    589                        / pVolInfo->ulBytesPerAllocationUnit;
     588                           / pVolInfo->ulBytesPerAllocationUnit;
    590589            stat->f_files  = 1000;
    591             stat->f_ffree  = 1000; /* don't return 0 here since the guest may think
    592                         * that it is not possible to create any more files */
     590            stat->f_ffree  = 1000000; /* don't return 0 here since the guest may think
     591                                       * that it is not possible to create any more files */
    593592            stat->f_fsid.val[0] = 0;
    594593            stat->f_fsid.val[1] = 0;
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette