Commit Graph

9 Commits

Author SHA1 Message Date
Darshana Patil
10794c2968 video: driver: initial state machine changes
- hierarchical state model which comprises of
  top level states and sub states
- top level states include OPEN, CLOSE, ERROR,
  INPUT_STREAMING, OUTPUT_STREAMING, STREAMING.
- sub states include DRAIN, DRC, DRAIN_LAST_BUFFER,
  DRC_LAST_BUFFER, INPUT_PAUSE, OUTPUT_PAUSE.
- follows deterministic approach for key sequences
  like DRC, DRAIN and last flag handling i.e none
  of these events are ignored or discarded.
- removal of auto start of firmware input port as
  part of ipsc handling.
- introduction of hfi commands for host controlled
  PAUSE and RESUME of firmware ports.
- introduction of information last flag packets
  for DRC and DRAIN when FW has insufficient
  output buffers.

Change-Id: Ie8c8f44af464d06f5a7bb76822f749c9874f869a
Signed-off-by: Darshana Patil <quic_darshana@quicinc.com>
2022-06-29 10:47:54 -07:00
Govindaraj Rajagopal
ae4e77ad42 video: driver: fix deadlock issue with response workqueue
Both &inst->stats_work and &inst->response_work both were using
&inst->response_workq for scheduling works. From reverse thread
handle_session_response_work_handler incremented refcount via
get_inst_ref(), at the same time driverfd got closed by HAL.
So strongref is held by handle_session_response_work_handler and
as part of put_inst(refcount is zero), will attempt to destry
&inst->response_workq inside msm_vidc_close_helper.

destroy_workqueue() call will wait until all already fired events
to complete, which will never happen in this case i.e leading to
deadlock situation. It is an attempt to self destruction, which is
not allowed.

Added changes to avoid above mentioned situation.

Change-Id: Ieb26a4b02f87f2bb738027cfd16e4c261b756dc3
Signed-off-by: Govindaraj Rajagopal <quic_grajagop@quicinc.com>
2022-01-13 17:29:22 +05:30
Govindaraj Rajagopal
5c297b7d26 video: driver: print buffer statistics once at every sec
- Added change to print buffer statistics like total and avg
etb, ebd, ftb, fbd counts, client set fps, actual fps,
bitrate values in 1 sec window and these stats currently
configured to print at every 1sec boundary.
- Convert meta buffer prints to low level logs.

Change-Id: I1c93eea90fbd5460eb51bbf133c513157003d51e
Signed-off-by: Govindaraj Rajagopal <grajagop@codeaurora.org>
2021-07-22 19:13:19 +05:30
Govindaraj Rajagopal
659ec59888 video: driver: dump queues for system error
Add support to dump all queues(cmd, msg, dbg) as part
of handle_system_error using devcoredump framework.

Change-Id: Ia1b011a29e6bc657eb002dbba09deab62dc0b2b2
Signed-off-by: Govindaraj Rajagopal <grajagop@codeaurora.org>
2021-06-24 17:10:17 +05:30
Darshana Patil
74b6d67205 video: driver: remove release of dpb buffers
remove release of dpb buffers as part of start
of output port.
handle watchdog interrupt incase of page fault

Change-Id: Idaccbcaa92d4835dea2da3d8b6f645114baa338a
Signed-off-by: Darshana Patil <darshana@codeaurora.org>
2021-03-24 17:58:21 -07:00
Darshana Patil
481a6117d8 video: driver: update license year
update license year to 2020-2021

Change-Id: I5a67bf49c386e86337bc7449ded08d186fc9a280
Signed-off-by: Darshana Patil <darshana@codeaurora.org>
2021-03-01 18:07:35 -08:00
Darshana Patil
d98075c932 video: driver: fixes for PSC on latest fw
- post input psc, output psc and last flag
  events to response work handler
- fix issue with release and create internal
  buffers during input psc
- clear last flag after session continue

Change-Id: Ic0278a09a0f6ee8ffff8840a47cd80c046ecadc4
Signed-off-by: Darshana Patil <darshana@codeaurora.org>
2021-01-06 16:28:18 -08:00
Maheshwar Ajja
58cd1120ee video: driver: add support for instance states
Add support for all the required instance states and
move the states accordingly.

Change-Id: Iac1046ab8c7a0116df6ed3069d566c7a1b65e61c
Signed-off-by: Maheshwar Ajja <majja@codeaurora.org>
2020-12-30 12:09:01 -08:00
Darshana Patil
9a854613cd msm: vidc: response handling
add response handling for commands, properties,
system and session errors.

Change-Id: I87a8cba136979d425d978dfe55317a3deb081c53
Signed-off-by: Darshana Patil <darshana@codeaurora.org>
2020-09-30 14:08:32 -07:00