msm: adsprpc: Share CP secure context banks
Currently CPZ secure context banks are not shared on CDSP. Share CP secure context banks among applications that use secure memory, so that many CPZ applications can be spawned and offloaded to DSP. Change-Id: I77d95bab86ef527e41c9fe79058742615f4adb0e Signed-off-by: Himateja Reddy <quic_hmreddy@quicinc.com>
This commit is contained in:

committed by
Gerrit - the friendly Code Review server

parent
4dc57d62a5
commit
38ca55b8e5
@@ -1207,7 +1207,7 @@ static int fastrpc_mmap_create(struct fastrpc_file *fl, int fd, struct dma_buf *
|
||||
map->secure = (mem_buf_dma_buf_exclusive_owner(map->buf)) ? 0 : 1;
|
||||
if (map->secure) {
|
||||
if (!fl->secsctx)
|
||||
err = fastrpc_session_alloc(chan, 1, 0,
|
||||
err = fastrpc_session_alloc(chan, 1, me->share_securecb,
|
||||
&fl->secsctx);
|
||||
if (err) {
|
||||
ADSPRPC_ERR(
|
||||
@@ -7374,6 +7374,9 @@ static int fastrpc_cb_probe(struct device *dev)
|
||||
|
||||
if (of_get_property(dev->of_node, "shared-cb", NULL) != NULL) {
|
||||
sess->smmu.sharedcb = 1;
|
||||
// Set share_securecb, if the secure context bank is shared
|
||||
if (sess->smmu.secure)
|
||||
me->share_securecb = 1;
|
||||
err = of_property_read_u32(dev->of_node, "shared-cb",
|
||||
&sharedcb_count);
|
||||
if (err)
|
||||
|
Reference in New Issue
Block a user