msm: vidc: modify allocation of hfi_cmd_sys_set_property_packet
Allocating sufficient size for hfi_cmd_sys_set_property_packet. Change-Id: I8c0fe46a85dec537d856d0c2e6f92503246e4461 Signed-off-by: Agnimitra Sen <quic_agnimitr@quicinc.com>
This commit is contained in:
parent
07a303b15a
commit
60fdc65b86
1 changed files with 7 additions and 3 deletions
|
|
@ -2094,10 +2094,14 @@ static int venus_hfi_session_init(void *device, void *session_id,
|
|||
void **new_session)
|
||||
{
|
||||
struct hfi_cmd_sys_session_init_packet pkt;
|
||||
struct hfi_cmd_sys_set_property_packet feature_pkt;
|
||||
struct venus_hfi_device *dev;
|
||||
struct hal_session *s;
|
||||
|
||||
// allocating minimum packet size for feature_pkt
|
||||
u8 packet[VIDC_IFACEQ_VAR_SMALL_PKT_SIZE];
|
||||
struct hfi_cmd_sys_set_property_packet *feature_pkt =
|
||||
(struct hfi_cmd_sys_set_property_packet *) &packet;
|
||||
|
||||
if (!device || !new_session) {
|
||||
dprintk(VIDC_ERR, "%s - invalid input\n", __func__);
|
||||
return -EINVAL;
|
||||
|
|
@ -2128,14 +2132,14 @@ static int venus_hfi_session_init(void *device, void *session_id,
|
|||
if (dev->res->enable_feature_config) {
|
||||
dprintk(VIDC_DBG, "session init: sys_feature_config is enabled with value - %d\n", dev->res->enable_feature_config);
|
||||
if (call_hfi_pkt_op(dev, sys_feature_config,
|
||||
&feature_pkt,
|
||||
feature_pkt,
|
||||
dev->res->enable_feature_config)) {
|
||||
dprintk(VIDC_ERR,
|
||||
"Failed to create feature config pkt\n");
|
||||
goto err_session_init_fail;
|
||||
}
|
||||
|
||||
if (__iface_cmdq_write(dev, &feature_pkt)) {
|
||||
if (__iface_cmdq_write(dev, feature_pkt)) {
|
||||
dprintk(VIDC_WARN,
|
||||
"Failed to set max resolutionfeature in f/w\n");
|
||||
goto err_session_init_fail;
|
||||
|
|
|
|||
Loading…
Reference in a new issue