Changeset 51330 in vbox for trunk/src/VBox/Additions/WINNT/Graphics/Video/mp
- Timestamp:
- May 21, 2014 7:46:25 PM (11 years ago)
- svn:sync-xref-src-repo-rev:
- 93813
- Location:
- trunk/src/VBox/Additions/WINNT/Graphics/Video/mp/wddm
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/WINNT/Graphics/Video/mp/wddm/VBoxMPCr.cpp
r51080 r51330 25 25 #include <cr_protocol.h> 26 26 27 static uint32_t g_VBoxMpCrHostCaps = 0;27 CR_CAPS_INFO g_VBoxMpCrHostCapsInfo; 28 28 static uint32_t g_VBoxMpCr3DSupported = 0; 29 29 30 30 uint32_t VBoxMpCrGetHostCaps() 31 31 { 32 return g_VBoxMpCrHostCaps ;32 return g_VBoxMpCrHostCapsInfo.u32Caps; 33 33 } 34 34 … … 815 815 } 816 816 817 static int vboxMpCrCtlConGetCaps (PVBOXMP_CRCTLCON pCrCtlCon, uint32_t u32ClientID, uint32_t *pu32Caps)817 static int vboxMpCrCtlConGetCapsLegacy(PVBOXMP_CRCTLCON pCrCtlCon, uint32_t u32ClientID, uint32_t *pu32Caps) 818 818 { 819 819 CRVBOXHGCMGETCAPS parms; … … 822 822 parms.hdr.result = VERR_WRONG_ORDER; 823 823 parms.hdr.u32ClientID = u32ClientID; 824 parms.hdr.u32Function = SHCRGL_GUEST_FN_GET_CAPS ;825 parms.hdr.cParms = SHCRGL_CPARMS_GET_CAPS ;824 parms.hdr.u32Function = SHCRGL_GUEST_FN_GET_CAPS_LEGACY; 825 parms.hdr.cParms = SHCRGL_CPARMS_GET_CAPS_LEGACY; 826 826 827 827 parms.Caps.type = VMMDevHGCMParmType_32bit; … … 839 839 if (RT_FAILURE(parms.hdr.result)) 840 840 { 841 WARN(("SHCRGL_GUEST_FN_GET_CAPS failed, rc (%d)", parms.hdr.result));841 WARN(("SHCRGL_GUEST_FN_GET_CAPS_LEGACY failed, rc (%d)", parms.hdr.result)); 842 842 return parms.hdr.result; 843 843 } 844 844 845 /* if host reports it supports CR_VBOX_CAP_CMDVBVA, clean it up, 846 * we only support CR_VBOX_CAP_CMDVBVA of the proper version reported by SHCRGL_GUEST_FN_GET_CAPS_NEW */ 847 parms.Caps.u.value32 &= ~CR_VBOX_CAP_CMDVBVA; 848 845 849 *pu32Caps = parms.Caps.u.value32; 850 851 return VINF_SUCCESS; 852 } 853 854 static int vboxMpCrCtlConGetCapsNew(PVBOXMP_CRCTLCON pCrCtlCon, uint32_t u32ClientID, CR_CAPS_INFO *pCapsInfo) 855 { 856 pCapsInfo->u32Caps = CR_VBOX_CAPS_ALL; 857 pCapsInfo->u32CmdVbvaVersion = CR_CMDVBVA_VERSION; 858 859 CRVBOXHGCMGETCAPS parms; 860 int rc; 861 862 parms.hdr.result = VERR_WRONG_ORDER; 863 parms.hdr.u32ClientID = u32ClientID; 864 parms.hdr.u32Function = SHCRGL_GUEST_FN_GET_CAPS_NEW; 865 parms.hdr.cParms = SHCRGL_CPARMS_GET_CAPS_NEW; 866 867 parms.Caps.type = VMMDevHGCMParmType_LinAddr; 868 parms.Caps.u.Pointer.u.linearAddr = (uintptr_t)pCapsInfo; 869 parms.Caps.u.Pointer.size = sizeof (*pCapsInfo); 870 871 rc = vboxCrCtlConCall(pCrCtlCon->hCrCtl, &parms.hdr, sizeof (parms)); 872 if (RT_FAILURE(rc)) 873 { 874 WARN(("vboxCrCtlConCall failed, rc (%d)", rc)); 875 return rc; 876 } 877 878 if (RT_FAILURE(parms.hdr.result)) 879 { 880 WARN(("SHCRGL_GUEST_FN_GET_CAPS_NEW failed, rc (%d)", parms.hdr.result)); 881 return parms.hdr.result; 882 } 883 884 if (pCapsInfo->u32CmdVbvaVersion != CR_CMDVBVA_VERSION) 885 { 886 WARN(("CmdVbva version mismatch (%d), expected(%d)", pCapsInfo->u32CmdVbvaVersion, CR_CMDVBVA_VERSION)); 887 pCapsInfo->u32Caps &= ~CR_VBOX_CAP_CMDVBVA; 888 } 889 890 pCapsInfo->u32Caps &= CR_VBOX_CAPS_ALL; 846 891 847 892 return VINF_SUCCESS; … … 1008 1053 { 1009 1054 g_VBoxMpCr3DSupported = 0; 1010 g_VBoxMpCrHostCaps = 0;1055 memset(&g_VBoxMpCrHostCapsInfo, 0, sizeof (g_VBoxMpCrHostCapsInfo)); 1011 1056 1012 1057 VBOXMP_CRCTLCON CrCtlCon = {0}; … … 1021 1066 g_VBoxMpCr3DSupported = 1; 1022 1067 1023 rc = vboxMpCrCtlConGetCaps (&CrCtlCon, u32ClientID, &g_VBoxMpCrHostCaps);1068 rc = vboxMpCrCtlConGetCapsNew(&CrCtlCon, u32ClientID, &g_VBoxMpCrHostCapsInfo); 1024 1069 if (RT_FAILURE(rc)) 1025 1070 { 1026 WARN(("vboxMpCrCtlConGetCaps failed rc (%d), ignoring..", rc)); 1027 g_VBoxMpCrHostCaps = 0; 1071 WARN(("vboxMpCrCtlConGetCapsNew failed rc (%d), ignoring..", rc)); 1072 g_VBoxMpCrHostCapsInfo.u32CmdVbvaVersion = 0; 1073 rc = vboxMpCrCtlConGetCapsLegacy(&CrCtlCon, u32ClientID, &g_VBoxMpCrHostCapsInfo.u32Caps); 1074 if (RT_FAILURE(rc)) 1075 { 1076 WARN(("vboxMpCrCtlConGetCapsLegacy failed rc (%d), ignoring..", rc)); 1077 g_VBoxMpCrHostCapsInfo.u32Caps = 0; 1078 } 1028 1079 } 1029 1080 1030 1081 #if 0 //ndef DEBUG_misha 1031 g_VBoxMpCrHostCaps &= ~CR_VBOX_CAP_CMDVBVA; 1082 g_VBoxMpCrHostCapsInfo.u32Caps &= ~CR_VBOX_CAP_CMDVBVA; 1083 g_VBoxMpCrHostCapsInfo.u32CmdVbvaVersion = 0; 1032 1084 #endif 1033 1085 -
trunk/src/VBox/Additions/WINNT/Graphics/Video/mp/wddm/VBoxMPVdma.cpp
r51260 r51330 1161 1161 } 1162 1162 1163 NTSTATUS Status = STATUS_ UNSUCCESSFUL;1163 NTSTATUS Status = STATUS_SUCCESS; 1164 1164 uint32_t hostID = pSrcAllocData->hostID; 1165 1165 int rc; -
trunk/src/VBox/Additions/WINNT/Graphics/Video/mp/wddm/VBoxMPVidPn.cpp
r51328 r51330 1893 1893 NTSTATUS VBoxVidPnCheckTopology(PVBOXMP_DEVEXT pDevExt, D3DKMDT_HVIDPNTOPOLOGY hVidPnTopology, const DXGK_VIDPNTOPOLOGY_INTERFACE* pVidPnTopologyInterface, BOOLEAN *pfSupported) 1894 1894 { 1895 UINT i;1896 1895 VBOXVIDPNGETPATHSINFO CbContext = {0}; 1897 1896 CbContext.pDevExt = pDevExt;
Note:
See TracChangeset
for help on using the changeset viewer.