{"id":1528,"date":"2015-08-01T20:26:34","date_gmt":"2015-08-01T19:26:34","guid":{"rendered":"http:\/\/rglinuxtech.com\/?p=1528"},"modified":"2015-08-01T20:26:34","modified_gmt":"2015-08-01T19:26:34","slug":"vmware-fix-for-kernel-4-2","status":"publish","type":"post","link":"https:\/\/rglinuxtech.com\/?p=1528","title":{"rendered":"VMware &#8211; Fix for Kernel 4.2..?"},"content":{"rendered":"<p>Thanks to <em><strong>craigacgomez<\/strong><\/em> on the VMware Forum, there is a hack to fix VMware (vmnet) with Kernel 4.2..\u00a0 <a href=\"https:\/\/communities.vmware.com\/thread\/516196\" target=\"_blank\">https:\/\/communities.vmware.com\/thread\/516196<\/a><\/p>\n<p>I made some more changes, to make it backward-compatible, and it seems to work OK with Kernels 4.1.3 and 4.2-rc4..<\/p>\n<p>I should emphasize that I am an <span style=\"text-decoration: underline;\">amateur<\/span> at such things, but if you want to try this, then this is what I did, after expanding <span style=\"font-family: courier new,courier,monospace;\"><strong>vmnet.tar<\/strong><\/span>:<\/p>\n<p>In <strong><span style=\"font-family: courier new,courier,monospace;\">vmnet-only\/vmnetInt.h<\/span><\/strong>..<\/p>\n<p>Around line 79, change:<\/p>\n<pre><span style=\"font-family: courier new,courier,monospace;\"><strong>#ifdef VMW_NETDEV_HAS_NET<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong># define compat_sk_alloc(_bri, _pri) sk_alloc(&amp;init_net, \\<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong>                        PF_NETLINK, _pri, &amp;vmnet_proto,)<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong>#else<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong># define compat_sk_alloc(_bri, _pri) sk_alloc(PF_NETLINK, _pri, &amp;vmnet_proto, 1)<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong>#endif<\/strong><\/span><\/pre>\n<p>to:<\/p>\n<pre><span style=\"font-family: courier new,courier,monospace;\"><strong>#ifdef VMW_NETDEV_HAS_NET<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong>#if LINUX_VERSION_CODE &gt;= KERNEL_VERSION(4, 2, 00)<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong># define compat_sk_alloc(_bri, _pri) sk_alloc(&amp;init_net, \\<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong>                        PF_NETLINK, _pri, &amp;vmnet_proto, 1)<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong>#else<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong># define compat_sk_alloc(_bri, _pri) sk_alloc(&amp;init_net, \\<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong>                        PF_NETLINK, _pri, &amp;vmnet_proto)<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong>#endif<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong>#else<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong># define compat_sk_alloc(_bri, _pri) sk_alloc(PF_NETLINK, _pri, &amp;vmnet_proto, 1)<\/strong><\/span>\r\n<span style=\"font-family: courier new,courier,monospace;\"><strong>#endif<\/strong><\/span><\/pre>\n<p>I have applied this change, and VMware compiles and runs OK on Kernel 4.1.3, and 4.2-rc4..<\/p>\n<p>YMMV&#8230;\u00a0 Usual disclaimer applies!<\/p>\n<p><em>Robert Gadsdon.\u00a0\u00a0\u00a0 August 1, 2015.<\/em><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Thanks to craigacgomez on the VMware Forum, there is a hack to fix VMware (vmnet) with Kernel 4.2..\u00a0 https:\/\/communities.vmware.com\/thread\/516196 I made some more changes, to make it backward-compatible, and it seems to work OK with Kernels 4.1.3 and 4.2-rc4.. I should emphasize that I am an amateur at such things, but if you want to try this, <span class=\"excerpt-dots\">&hellip;<\/span> <a class=\"more-link\" href=\"https:\/\/rglinuxtech.com\/?p=1528\"><span class=\"more-msg\">Continue reading &rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[5,862,11,14,15,25],"tags":[991,182,1165,1145,987,1166,957],"class_list":["post-1528","post","type-post","status-publish","format-standard","hentry","category-compilation","category-cubox","category-hacks","category-kernel","category-linux-2","category-vmware","tag-backward-compatible","tag-hack","tag-kernel-4-2","tag-sk_alloc","tag-vmnet-fix","tag-vmnetint-h","tag-vmware-11"],"_links":{"self":[{"href":"https:\/\/rglinuxtech.com\/index.php?rest_route=\/wp\/v2\/posts\/1528","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/rglinuxtech.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/rglinuxtech.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/rglinuxtech.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/rglinuxtech.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1528"}],"version-history":[{"count":2,"href":"https:\/\/rglinuxtech.com\/index.php?rest_route=\/wp\/v2\/posts\/1528\/revisions"}],"predecessor-version":[{"id":1530,"href":"https:\/\/rglinuxtech.com\/index.php?rest_route=\/wp\/v2\/posts\/1528\/revisions\/1530"}],"wp:attachment":[{"href":"https:\/\/rglinuxtech.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1528"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/rglinuxtech.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1528"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/rglinuxtech.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1528"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}