Changeset 88906 in vbox for trunk/src/VBox
- Timestamp:
- May 6, 2021 2:24:47 PM (4 years ago)
- Location:
- trunk/src/VBox/Devices/Audio
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DevIchAc97.cpp
r88905 r88906 3921 3921 3922 3922 /** 3923 * Attach command, internal version. 3924 * 3925 * This is called to let the device attach to a driver for a specified LUN 3926 * during runtime. This is not called during VM construction, the device 3927 * constructor has to attach to all the available drivers. 3923 * Worker for ichac97R3Construct() and ichac97R3Attach(). 3928 3924 * 3929 3925 * @returns VBox status code. … … 3931 3927 * @param pThisCC The ring-3 AC'97 device state. 3932 3928 * @param iLun The logical unit which is being attached. 3933 * @param fFlags Flags, combination of the PDMDEVATT_FLAGS_* \#defines.3934 3929 * @param ppDrv Attached driver instance on success. Optional. 3935 3930 */ 3936 static int ichac97R3AttachInternal(PPDMDEVINS pDevIns, PAC97STATER3 pThisCC, unsigned iLun, uint32_t fFlags, PAC97DRIVER *ppDrv) 3937 { 3938 RT_NOREF(fFlags); 3939 3931 static int ichac97R3AttachInternal(PPDMDEVINS pDevIns, PAC97STATER3 pThisCC, unsigned iLun, PAC97DRIVER *ppDrv) 3932 { 3940 3933 /* 3941 3934 * Attach driver. … … 3977 3970 if (ppDrv) 3978 3971 *ppDrv = pDrv; 3979 LogFunc((" iLun=%u, fFlags=0x%x: VINF_SUCCESS\n", iLun, fFlags));3972 LogFunc(("LUN#%u: VINF_SUCCESS\n", iLun)); 3980 3973 return VINF_SUCCESS; 3981 3974 } … … 3992 3985 3993 3986 RTStrFree(pszDesc); 3994 LogFunc((" iLun=%u, fFlags=0x%x: rc=%Rrc\n", iLun, fFlags, rc));3987 LogFunc(("LUN#%u: rc=%Rrc\n", iLun, rc)); 3995 3988 return rc; 3996 3989 } … … 4003 3996 PAC97STATE pThis = PDMDEVINS_2_DATA(pDevIns, PAC97STATE); 4004 3997 PAC97STATER3 pThisCC = PDMDEVINS_2_DATA_CC(pDevIns, PAC97STATER3); 4005 4006 LogFunc(("iLUN=%u, fFlags= 0x%x\n", iLUN, fFlags));3998 RT_NOREF(fFlags); 3999 LogFunc(("iLUN=%u, fFlags=%#x\n", iLUN, fFlags)); 4007 4000 4008 4001 DEVAC97_LOCK(pDevIns, pThis); 4009 4002 4010 4003 PAC97DRIVER pDrv; 4011 int rc = ichac97R3AttachInternal(pDevIns, pThisCC, iLUN, fFlags,&pDrv);4004 int rc = ichac97R3AttachInternal(pDevIns, pThisCC, iLUN, &pDrv); 4012 4005 if (RT_SUCCESS(rc)) 4013 4006 { … … 4282 4275 AssertBreak(iLun < UINT8_MAX); 4283 4276 LogFunc(("Trying to attach driver for LUN#%u ...\n", iLun)); 4284 rc = ichac97R3AttachInternal(pDevIns, pThisCC, iLun, 0 /* fFlags */,NULL /* ppDrv */);4277 rc = ichac97R3AttachInternal(pDevIns, pThisCC, iLun, NULL /* ppDrv */); 4285 4278 if (rc == VERR_PDM_NO_ATTACHED_DRIVER) 4286 4279 { -
trunk/src/VBox/Devices/Audio/DevSB16.cpp
r88905 r88906 2850 2850 2851 2851 /** 2852 * Attach command, internal version. 2853 * 2854 * This is called to let the device attach to a driver for a specified LUN 2855 * during runtime. This is not called during VM construction, the device 2856 * constructor has to attach to all the available drivers. 2852 * Worker for sb16Construct() and sb16Attach(). 2857 2853 * 2858 2854 * @returns VBox status code. 2859 2855 * @param pThis SB16 state. 2860 2856 * @param uLUN The logical unit which is being detached. 2861 * @param fFlags Flags, combination of the PDMDEVATT_FLAGS_* \#defines.2862 2857 * @param ppDrv Attached driver instance on success. Optional. 2863 2858 */ 2864 static int sb16AttachInternal(PSB16STATE pThis, unsigned uLUN, uint32_t fFlags, PSB16DRIVER *ppDrv) 2865 { 2866 RT_NOREF(fFlags); 2867 2859 static int sb16AttachInternal(PSB16STATE pThis, unsigned uLUN, PSB16DRIVER *ppDrv) 2860 { 2868 2861 /* 2869 2862 * Allocate a new driver structure and try attach the driver. … … 2903 2896 if (ppDrv) 2904 2897 *ppDrv = pDrv; 2905 LogFunc((" iLUN=%u, fFlags=0x%x: VINF_SUCCESS\n", uLUN, fFlags));2898 LogFunc(("LUN#%u: VINF_SUCCESS\n", uLUN)); 2906 2899 return VINF_SUCCESS; 2907 2900 } … … 2914 2907 RTMemFree(pDrv); 2915 2908 2916 LogFunc((" iLUN=%u, fFlags=0x%x: rc=%Rrc\n", uLUN, fFlags, rc));2909 LogFunc(("LUN#%u: rc=%Rrc\n", uLUN, rc)); 2917 2910 return rc; 2918 2911 } … … 2924 2917 { 2925 2918 PSB16STATE pThis = PDMDEVINS_2_DATA(pDevIns, PSB16STATE); 2926 2927 LogFunc(("iLUN=%u, fFlags= 0x%x\n", iLUN, fFlags));2919 RT_NOREF(fFlags); 2920 LogFunc(("iLUN=%u, fFlags=%#x\n", iLUN, fFlags)); 2928 2921 2929 2922 /** @todo r=andy Any locking required here? */ 2930 2923 2931 2924 PSB16DRIVER pDrv; 2932 int rc = sb16AttachInternal(pThis, iLUN, fFlags,&pDrv);2925 int rc = sb16AttachInternal(pThis, iLUN, &pDrv); 2933 2926 if (RT_SUCCESS(rc)) 2934 2927 { … … 3263 3256 AssertBreak(iLun < UINT8_MAX); 3264 3257 LogFunc(("Trying to attach driver for LUN#%u ...\n", iLun)); 3265 rc = sb16AttachInternal(pThis, iLun, 0 /* fFlags */,NULL /* ppDrv */);3258 rc = sb16AttachInternal(pThis, iLun, NULL /* ppDrv */); 3266 3259 if (rc == VERR_PDM_NO_ATTACHED_DRIVER) 3267 3260 {
Note:
See TracChangeset
for help on using the changeset viewer.