media/gpu/v4l2: Do not call GetSupportedDecodeProfiles() with opened device
When checking for a V4L2 workaround, we first open the decoder device in order to check its name, before querying its supported profiles using GetSupportedDecodeProfiles(). However GetSupportedDecodeProfiles() DCHECKs that no device is currently opened, since it needs to open one itself - and the device is still opened at this time. Fix this by reinitializing the device before calling GetSupportedDecodeProfiles(). Bug: b:140222972 Test: assert of b:140222972 not triggered. Change-Id: I6ec44f6f6113c4fc69965d6012128b61a27cb473 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1775887 Auto-Submit: Alexandre Courbot <acourbot@chromium.org> Commit-Queue: Hirokazu Honda <hiroh@chromium.org> Reviewed-by:Hirokazu Honda <hiroh@chromium.org> Cr-Commit-Position: refs/heads/master@{#691953}
Showing
Please register or sign in to comment