Wednesday, 17 July 2013

vmblock patch for linux 3.11-rc1 (vmware 9)

Linux 3.11-rc1 was released a few days ago. With it comes a kernel-level API change related to VFS. Specifically, struct file_operations no longer contains the function pointer readdir and vfs_readdir() which was defined in fs/readdir.c is now gone. They are both superseded by iterate and iterate_dir() respectively. Unfortunately, these changes broke the compilation of the vmblock fs module.

So, here is a simple patch I've written for anyone who is interested. Note that you also have to apply the vmblock patch for linux 3.10 if you haven't already. Otherwise, the compilation would fail.

Download: vmblock.3.11.patch As usual, apply the patch and do: Verification to show that the patch works properly:


  1. Nice. This is what worked for me:

    cd /tmp
    curl -O
    curl -O
    cd /usr/lib/vmware/modules/source
    tar -xvf vmblock.tar
    tar -xvf vmnet.tar
    patch -p0 -i /tmp/vmblock-9.0.2-5.0.2-3.10.patch
    patch -p0 -i /tmp/vmnet-9.0.2-5.0.2-3.10.patch
    cd vmblock-only
    patch -p1 -i /tmp/vmblock.3.11.patch
    cd ..
    tar -cf vmblock.tar vmblock-only
    tar -cf vmnet.tar vmnet-only
    rm -r vmblock-only
    rm -r vmnet-only
    vmware-modconfig --console --install-all

    1. Thanks, works like a charm on Ubuntu 13.04 with kernel 3.11

  2. Really nice shell script ^ works on fedora rawhide

  3. Another API change in 3.12. See here for my patch:

  4. Why the hell so many API changes?

  5. Thanks a bunch!