Language Selection

English French German Italian Portuguese Spanish

DirectX on Linux - what it is/isn't

Filed under
Microsoft

First up clarify for the people who jump to insane conclusions:

The DX on Linux is a WSL2 only thing. Microsoft are not any way bringing DX12 to Linux outside of the Windows environment. They are also in no way open sourcing any of the DX12 driver code. They are recompiling the DX12 userspace drivers (from GPU vendors) into Linux shared libraries, and running them on a kernel driver shim that transfers the kernel interface up to the closed source Windows kernel driver. This is in no way useful for having DX12 on Linux baremetal or anywhere other than in a WSL2 environment. It is not useful for Linux gaming.

From my point of view the kernel shim driver doesn't really bring anything to Linux, it's just a tunnel for some binary data between a host windows kernel binary and a guest linux userspace binary. It doesn't enhance the Linux graphics ecosystem in any useful direction, and as such I'm questioning why we'd want this upstream at all.

Read more

Mainlining The Microsoft DirectX Kernel Driver For Linux...

  • Mainlining The Microsoft DirectX Kernel Driver For Linux Will Be An Uphill Battle

    Intel open-source developer Daniel Vetter who helps oversee the DRM subsystem immediately pointed out a number of problems, including the closed-source user-space. Among the issues raised by Vetter is that the DirectX kernel driver is "reinventing the world" in changing around device enumeration and a lot of other interfaces/features already supported in a common manner by upstream DRM drivers. There are also questions raised about how well this integrates with other common Linux features like DMA-BUF.

    DRM maintainer David Airlie was also quick to characterize this as a driver that connects a binary blob interface in Windows to a binary blob in Linux guests. He personally sees little value in having this driver upstreamed and raised concerns over how this driver will ultimately handle its planned presentation bits for displaying of Linux GUI applications within WSL2. He also raised the possibility of this landing in the Linux kernel as part of the Microsoft Hyper-V drivers rather than in the DRM driver area.

    Airlie also followed up that he isn't even fond of the idea of reviewing this open-source DXGKRNL code as since it's implementing proprietary Microsoft interfaces could potentially legally taint him in developing new graphics interfaces.

Microsoft Build - DirectX and Linux (WSL) plus more

  • Microsoft Build - DirectX and Linux (WSL) plus more

    Microsoft put up a developer blog post titled "DirectX ❤ Linux", which is a nice bit of PR bait. In reality, it means nothing for the standard desktop Linux. It's focused entirely on the Windows Subsystem for Linux which Microsoft tightly controls and DirectX itself remains firmly closed source. A Microsoft developer even said on the Linux Kernel mailing list, that there's "no intent" to have people coding for DX12 on Linux. Not only that, this implementation relies on pre-compiled user mode binaries that ship as part of Windows itself. Right now it seems to also be focused on CUDA and AI / Machine Learning, however, they also announced Linux GUI applications will eventually be supported on WSL as well.

    First they embraced Linux doing away with the Ballmer era of "Linux is a cancer", now they're extending a branch saying they were "on the wrong side of history" with open source and now they continue the extending. How long before extinguish phase starts (EEE)? Don't be fooled about Microsoft's stance and their aim here, it's not because they love Linux. They're going where the developers are to continue pulling people to Microsoft services. Nothing more.

    If any of it concerns you: I hope you put that energy and effort into continuing your support of the Linux desktop. Help it to grow and prosper. Support your favourite distribution, your favourite application and/or game developer by throwing some money at them.

Why DirectX On Linux? Kernel Developer Questions Microsoft

  • Why DirectX On Linux? Kernel Developer Questions Microsoft Developer

    Recently, at Build Conference 2020, Microsoft announced a new feature for its Windows subsystem for Linux 2 (WSL2). This time, it came up with ‘DirectX loves Linux‘ tagline that aims to further extend the computation capability of WSL2 instances.

    After huge demand from developers, Microsoft brought the GPU hardware acceleration support to the Linux system running on WSL2. For the same, Microsoft submitted the first draft of its new DirectX driver to the Linux kernel. But it does not seem like an easy way for Microsoft to upstream code to Linux.

    [...]

    Dave Airlie from Intel also put forward his thought that the patch would only add burden on upstream rather than adding any value to the Linux ecosystem. In his latest blog, he also expressed that it doesn’t enhance the Linux graphics ecosystem in any useful direction. Dave even declined to review the code.

    Well, it is quite clear that ‘DirectX on Linux’ has nothing to do with native Linux desktop support. It is not available for bare metal Linux systems but rather only for Linux VM running on WSL2 Windows. As Microsoft’s developer states, currently the driver code strives to add GPU resource sharing capability to Linux guests on WSL2.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

More in Tux Machines

Raspberry Pi HAT offer NMEA 2000 link for marine applications

Copperhill’s $99 “PiCAN-M” HAT for the Raspberry Pi provides CAN-based NMEA 2000 and RS-422 driven NMEA 0183 ports for marine applications. The HAT includes a 3A SMPS supply and a Qwiic link. In 2019, Copperhill Technologies launched a PiCAN3 CAN-Bus HAT for the Raspberry Pi 4. The new PiCAN-M (for Marine), built for Copperhill by SK Pang, offers a marine-specific, NMEA 2000 compatible version of CAN. The $98.50 HAT also supplies an RS-422-based NMEA 0183 interface plus a Qwiic interface for adding SparkFun’s Qwiic add-ons. Read more

How a Linux migration led to the creation of Amazon Web Services

Dan Rose, chairman of Coatue Ventures and Coatue Growth, posted a thread on Twitter the other day, 280 characters or less at a time, in which he chronicled how it came about that AWS infrastructure is built on Linux. Rose was at Amazon from 1999 to 2006, where he managed retail divisions and helped incubate the Kindle reader before moving to Facebook. So he was at Amazon in 2000 when the internet bubble popped,and one high-flying dot-com after another was shriveling up and dying, having burned through ridiculous amounts of capital on luxurious offices while often having nothing by way of a product to show for it. Rose said Amazon’s biggest expense was the data center outfitted with expensive Sun servers. Amazon’s motto was “get big fast,” and site stability was critical. Every second of downtime meant lost sales, and Sun was the gold standard for internet servers back then. I can recall them having a significant software business led by a VP named Eric Schmidt. Read more

Kernel: Restricted DMA and AMD Work in Linux 5.11

  • Restricted DMA

    A key component of system hardening is restricting access to memory; this extends to preventing the kernel itself from accessing or modifying much of the memory in the system most of the time. Memory that cannot be accessed cannot be read or changed by an attacker. On many systems, though, these restrictions do not apply to peripheral devices, which can happily use direct memory access (DMA) on most or all of the available memory. The recently posted restricted DMA patch set aims to reduce exposure to buggy or malicious device activity by tightening up control over the memory that DMA operations are allowed to access. DMA allows devices to directly read from or write to memory in the system; it is needed to get reasonable I/O performance from anything but the slowest devices. Normally, the kernel is in charge of DMA operations; device drivers allocate buffers and instruct devices to perform I/O on those buffers, and everything works as expected. If the driver or the hardware contains bugs, though, the potential exists for DMA transfers to overwrite unrelated memory, leading to corrupted systems and unhappy users. Malicious (or compromised) hardware can use DMA to compromise the system the hardware is attached to, making users unhappier still; examples of this type of attack have been posted over the years. One way to address this problem is to place an I/O memory-management unit (IOMMU) between devices and memory. The kernel programs the IOMMU to allow access to a specific region of memory; the IOMMU then keeps devices from straying outside of that region. Not all systems are equipped with an IOMMU, though; they are mostly limited to the larger processors found in desktop machines, data centers, and the like. Mobile systems usually lack an IOMMU.

  •  
  • A Fix Has Been Proposed For The Slower AMD Performance On Linux 5.11

    With the in-development Linux 5.11 kernel there are many great features and improvements especially for AMD users with some new drivers and other pleasant enhancements. But as I outlined back on Christmas day: Linux 5.11 Is Regressing Hard For AMD Performance With Schedutil. Fortunately, a fix is now en route to the Linux 5.11 kernel for fixing that performance regression affecting AMD Zen 2/3 desktops and servers.  As outlined in that original article after bisecting the sizable performance regressions and in follow-up tests, AMD hardware performing slower on Linux 5.11 came down to the CPU frequency invariance support introduced this cycle and is utilized by the "Schedutil" CPU frequency scaling governor. With Schedutil often being the default for AMD systems on newer versions of the Linux kernel, this regression on Linux 5.11 compared to prior kernel releases has been unfortunate. 

  • Linux 5.11 Is Now Looking Great For AMD Zen 2 / Zen 3 Performance - Phoronix

    Not only is the AMD "CPU frequency invariance regression" from that new support with the in-development Linux 5.11 kernel on course to address the performance shortcomings I outlined last month, but with the patched kernel for a number of workloads the performance is now ahead of where it was at with Linux 5.10.

System76 Brings Back the Darter Pro Linux Laptop with Longer Battery Life, Tiger Lake CPUs

The Darter Pro is one of System76's most versatile all-around Linux laptops and the 2021 refresh is here with 11th Gen Intel Core i5-1135G7 and i7-1165G7 CPUs with 4 cores / 8 threads and integrated Iris Xe graphics, up to 64GB dual-channel DDR4 3200MHz RAM, and up to 4TB M.2 SSD storage. Best of all, the new Darter Pro comes with System76’s Coreboot-based Open Firmware and Open Source Embedded Controller Firmware to give customers full control over the hardware, and also make the Linux laptop faster and more secure. Read more