Changeset 89742 in vbox for trunk/src/VBox/Devices/Audio
- Timestamp:
- Jun 16, 2021 1:48:45 PM (4 years ago)
- svn:sync-xref-src-repo-rev:
- 145193
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/DevIchAc97.cpp
r89739 r89742 2038 2038 } 2039 2039 2040 /** @todo r=bird: If uHz == 0 then we'll just keep the previous stream, so 2041 * wonder how that's going to play out if the guest tries to enable it... This 2042 * makes no real sense. 2043 * 2044 * Comment your code and changes you make, please! This is frigging tedious. 2045 * 2046 * Test added in r127402? The test is older (before r118166, r113296, r112652, 2047 * r112463, r107142), but it used to be placed after calling 2048 * ichac97R3MixerRemoveDrvStreams() since r112652. Till ~r112463 a zero uHz 2049 * caused a VERR_INVALID_PARAMETER return. Before r107142 it would disable the 2050 * stream if uHz was zero. */ 2051 if (Cfg.Props.uHz) 2052 { /* likely */ } 2053 else 2054 { 2055 LogFlowFunc(("[SD%RU8] Hz is zero!! skipping/ignoring\n", pStreamCC->u8SD)); 2056 return VINF_SUCCESS; 2057 } 2040 /* 2041 * Don't continue if the frequency is out of range (the rest of the 2042 * properties should be okay). 2043 */ 2044 char szTmp[PDMAUDIOSTRMCFGTOSTRING_MAX]; 2045 ASSERT_GUEST_MSG_RETURN(AudioHlpStreamCfgIsValid(&Cfg), 2046 ("Invalid stream #%u rate: %s\n", pStreamCC->u8SD, 2047 PDMAudioStrmCfgToString(&Cfg, szTmp, sizeof(szTmp)) ), 2048 VERR_INVALID_PARAMETER); 2058 2049 2059 2050 /* … … 2123 2114 if (Cfg.Props.uHz > 44100) /* E.g. 48000 Hz. */ 2124 2115 uTimerHz = 200; 2125 else /* Just take the global Hz rate otherwise. */2126 uTimerHz = pThis->uTimerHz;2116 else 2117 uTimerHz = AC97_TIMER_HZ_DEFAULT; 2127 2118 } 2128 2119 else … … 2205 2196 * Otherwise avoid this and just reuse it, as this costs performance. 2206 2197 */ 2207 char szTmp[PDMAUDIOSTRMCFGTOSTRING_MAX];2208 2198 int rc = VINF_SUCCESS; 2209 2199 if ( fForce
Note:
See TracChangeset
for help on using the changeset viewer.