Bug 1352016 - P5. Also check AMD cards with 0x1002 device id. r=mattwoodrow
authorJean-Yves Avenard <jyavenard@mozilla.com>
Sun, 10 Sep 2017 18:17:14 +0200
changeset 430094 84bd9434491c9391a6e961e63e15807224dbeb77
parent 430093 05e5403bdb90dc63a958a99d682e0539c6c8d7a3
child 430095 79b0b2a82a4d22a228e6a6c7bdf3657165b6c843
push id7761
push userjlund@mozilla.com
push dateFri, 15 Sep 2017 00:19:52 +0000
treeherdermozilla-beta@c38455951db4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmattwoodrow
bugs1352016
milestone57.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1352016 - P5. Also check AMD cards with 0x1002 device id. r=mattwoodrow MozReview-Commit-ID: DjCMDNfsfXe
dom/media/platforms/wmf/DXVA2Manager.cpp
--- a/dom/media/platforms/wmf/DXVA2Manager.cpp
+++ b/dom/media/platforms/wmf/DXVA2Manager.cpp
@@ -424,17 +424,18 @@ D3D9DXVA2Manager::Init(layers::KnowsComp
   D3DADAPTER_IDENTIFIER9 adapter;
   hr = d3d9Ex->GetAdapterIdentifier(D3DADAPTER_DEFAULT, 0, &adapter);
   if (!SUCCEEDED(hr)) {
     aFailureReason = nsPrintfCString(
       "IDirect3D9Ex::GetAdapterIdentifier failed with error %X", hr);
     return hr;
   }
 
-  if (adapter.VendorId == 0x1022 && !gfxPrefs::PDMWMFSkipBlacklist()) {
+  if ((adapter.VendorId == 0x1022  || adapter.VendorId == 0x1002) &&
+      !gfxPrefs::PDMWMFSkipBlacklist()) {
     for (const auto& model : sAMDPreUVD4) {
       if (adapter.DeviceId == model) {
         mIsAMDPreUVD4 = true;
         break;
       }
     }
   }
 
@@ -903,17 +904,18 @@ D3D11DXVA2Manager::InitInternal(layers::
   DXGI_ADAPTER_DESC adapterDesc;
   hr = adapter->GetDesc(&adapterDesc);
   if (!SUCCEEDED(hr)) {
     aFailureReason =
       nsPrintfCString("IDXGIAdapter::GetDesc failed with code %X", hr);
     return hr;
   }
 
-  if (adapterDesc.VendorId == 0x1022 && !gfxPrefs::PDMWMFSkipBlacklist()) {
+  if ((adapterDesc.VendorId == 0x1022 || adapterDesc.VendorId == 0x1002) &&
+      !gfxPrefs::PDMWMFSkipBlacklist()) {
     for (const auto& model : sAMDPreUVD4) {
       if (adapterDesc.DeviceId == model) {
         mIsAMDPreUVD4 = true;
         break;
       }
     }
   }
 
@@ -1302,17 +1304,17 @@ DXVA2Manager::IsUnsupportedResolution(co
          aFramerate > 45;
 }
 
 /* static */ bool
 DXVA2Manager::IsNV12Supported(uint32_t aVendorID,
                               uint32_t aDeviceID,
                               const nsAString& aDriverVersionString)
 {
-  if (aVendorID == 0x1022) {
+  if (aVendorID == 0x1022 || aVendorID == 0x1002) {
     // AMD
     // Block old cards regardless of driver version.
     for (const auto& model : sAMDPreUVD4) {
       if (aDeviceID == model) {
         return false;
       }
     }
     // AMD driver earlier than 21.19.411.0 have bugs in their handling of NV12