Bug 223436

Summary: [GStreamer][EME] Remove DRM resources release
Product: WebKit Reporter: Xabier Rodríguez Calvar <calvaris>
Component: New BugsAssignee: Xabier Rodríguez Calvar <calvaris>
Status: RESOLVED FIXED    
Severity: Normal CC: bandou.yacine, cgarcia, eric.carlson, ews-watchlist, glenn, gustavo, jer.noble, menard, olivier.blin, philipj, pnormand, sergio, vjaquez, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch none

Description Xabier Rodríguez Calvar 2021-03-18 04:05:28 PDT
[GStreamer][EME] Remove DRM resources release
Comment 1 Xabier Rodríguez Calvar 2021-03-18 04:07:46 PDT
Created attachment 423582 [details]
Patch
Comment 2 EWS 2021-03-19 08:04:08 PDT
Committed r274719: <https://commits.webkit.org/r274719>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 423582 [details].
Comment 3 Radar WebKit Bug Importer 2021-03-19 08:05:15 PDT
<rdar://problem/75620889>
Comment 4 Yacine Bandou 2022-06-10 05:41:11 PDT
I think we should let
Comment 5 Yacine Bandou 2022-06-10 05:52:58 PDT
we should have left this "CDMInstanceProxy::releaseDecryptionResources" method, in order to be overloaded when we need release the resources.

In some proprietary embedded DRM implementation we need to release some resources  
 in order to be able change the DRM system (like passing from PlayReady to Widevine), and start a new playback, before the javascript GC is performed.

For example, in some chipsets, we cannot initialize the TEE for multiple DRM systems at the same time.

In this EME test page "https://ytlr-cert.appspot.com/2020/main.html?test_type=encryptedmedia-test" we change from Widevine to Playready."
Comment 6 Xabier Rodríguez Calvar 2022-06-12 23:53:47 PDT
(In reply to Yacine Bandou from comment #5)
> we should have left this "CDMInstanceProxy::releaseDecryptionResources"
> method, in order to be overloaded when we need release the resources.
> 
> In some proprietary embedded DRM implementation we need to release some
> resources  
>  in order to be able change the DRM system (like passing from PlayReady to
> Widevine), and start a new playback, before the javascript GC is performed.
> 
> For example, in some chipsets, we cannot initialize the TEE for multiple DRM
> systems at the same time.
> 
> In this EME test page
> "https://ytlr-cert.appspot.com/2020/main.html?test_type=encryptedmedia-test"
> we change from Widevine to Playready."

This was used before giving a spin to all session management and it was creating crashes with certain assets. For now, we don't see that necessary. I think you can keep that downstream if you don't find any other way.