]> git.baikalelectronics.ru Git - kernel.git/commit
[media] st-hva: add debug file system
authorJean-Christophe Trotin <jean-christophe.trotin@st.com>
Tue, 31 Jan 2017 10:37:57 +0000 (08:37 -0200)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Tue, 31 Jan 2017 13:59:46 +0000 (11:59 -0200)
commit2855362818d1a5d4927db22af674e0f7cc17bd69
tree201df2a410b4852f61149646fc032f769d5854de
parent2a835e20b71af74dac416ef6e115eef3bce41a8d
[media] st-hva: add debug file system

This patch creates 4 static debugfs entries to dump:
- the device-related information ("st-hva/device")
- the list of registered encoders ("st-hva/encoders")
- the current values of the hva registers ("st-hva/regs")
- the information about the last closed instance ("st-hva/last")

It also creates dynamically a debugfs entry for each opened instance,
("st-hva/<instance identifier>") to dump:
- the information about the frame (format, resolution)
- the information about the stream (format, profile, level,
  resolution)
- the control parameters (bitrate mode, framerate, GOP size...)
- the potential (system, encoding...) errors
- the performance information about the encoding (HW processing
  duration, average bitrate, average framerate...)
Each time a running instance is closed, its context (including the
debug information) is saved to feed, on demand, the last closed
instance debugfs entry.

Signed-off-by: Yannick Fertre <yannick.fertre@st.com>
Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Jean-Christophe Trotin <jean-christophe.trotin@st.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
drivers/media/platform/Kconfig
drivers/media/platform/sti/hva/Makefile
drivers/media/platform/sti/hva/hva-debugfs.c [new file with mode: 0644]
drivers/media/platform/sti/hva/hva-hw.c
drivers/media/platform/sti/hva/hva-hw.h
drivers/media/platform/sti/hva/hva-v4l2.c
drivers/media/platform/sti/hva/hva.h