mirror of
https://github.com/torvalds/linux.git
synced 2024-11-16 17:12:06 +00:00
V4L/DVB (5850): ivtv: improve API command debugging
Turn off debugging of API commands that occur during encoding or decoding, unless they are explicitly requested. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
This commit is contained in:
parent
8f40a9f532
commit
67632e17da
@ -37,6 +37,7 @@
|
||||
#define API_RESULT (1 << 1) /* Allow 1 second for this cmd to end */
|
||||
#define API_FAST_RESULT (3 << 1) /* Allow 0.1 second for this cmd to end */
|
||||
#define API_DMA (1 << 3) /* DMA mailbox, has special handling */
|
||||
#define API_HIGH_VOL (1 << 5) /* High volume command (i.e. called during encoding or decoding) */
|
||||
#define API_NO_WAIT_MB (1 << 4) /* Command may not wait for a free mailbox */
|
||||
#define API_NO_WAIT_RES (1 << 5) /* Command may not wait for the result */
|
||||
|
||||
@ -77,11 +78,11 @@ static const struct ivtv_api_info api_info[256] = {
|
||||
API_ENTRY(CX2341X_ENC_SET_DMA_BLOCK_SIZE, API_CACHE),
|
||||
API_ENTRY(CX2341X_ENC_GET_PREV_DMA_INFO_MB_10, API_FAST_RESULT),
|
||||
API_ENTRY(CX2341X_ENC_GET_PREV_DMA_INFO_MB_9, API_FAST_RESULT),
|
||||
API_ENTRY(CX2341X_ENC_SCHED_DMA_TO_HOST, API_DMA),
|
||||
API_ENTRY(CX2341X_ENC_SCHED_DMA_TO_HOST, API_DMA | API_HIGH_VOL),
|
||||
API_ENTRY(CX2341X_ENC_INITIALIZE_INPUT, API_RESULT),
|
||||
API_ENTRY(CX2341X_ENC_SET_FRAME_DROP_RATE, API_CACHE),
|
||||
API_ENTRY(CX2341X_ENC_PAUSE_ENCODER, API_RESULT),
|
||||
API_ENTRY(CX2341X_ENC_REFRESH_INPUT, API_NO_WAIT_MB),
|
||||
API_ENTRY(CX2341X_ENC_REFRESH_INPUT, API_NO_WAIT_MB | API_HIGH_VOL),
|
||||
API_ENTRY(CX2341X_ENC_SET_COPYRIGHT, API_CACHE),
|
||||
API_ENTRY(CX2341X_ENC_SET_EVENT_NOTIFICATION, API_RESULT),
|
||||
API_ENTRY(CX2341X_ENC_SET_NUM_VSYNC_LINES, API_CACHE),
|
||||
@ -102,7 +103,7 @@ static const struct ivtv_api_info api_info[256] = {
|
||||
API_ENTRY(CX2341X_DEC_SET_DMA_BLOCK_SIZE, API_CACHE),
|
||||
API_ENTRY(CX2341X_DEC_GET_XFER_INFO, API_FAST_RESULT),
|
||||
API_ENTRY(CX2341X_DEC_GET_DMA_STATUS, API_FAST_RESULT),
|
||||
API_ENTRY(CX2341X_DEC_SCHED_DMA_FROM_HOST, API_DMA),
|
||||
API_ENTRY(CX2341X_DEC_SCHED_DMA_FROM_HOST, API_DMA | API_HIGH_VOL),
|
||||
API_ENTRY(CX2341X_DEC_PAUSE_PLAYBACK, API_RESULT),
|
||||
API_ENTRY(CX2341X_DEC_HALT_FW, API_FAST_RESULT),
|
||||
API_ENTRY(CX2341X_DEC_SET_STANDARD, API_CACHE),
|
||||
@ -227,7 +228,12 @@ static int ivtv_api_call(struct ivtv *itv, int cmd, int args, u32 data[])
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
IVTV_DEBUG_API("API Call: %s\n", api_info[cmd].name);
|
||||
if (api_info[cmd].flags & API_HIGH_VOL) {
|
||||
IVTV_DEBUG_HI_API("API Call: %s\n", api_info[cmd].name);
|
||||
}
|
||||
else {
|
||||
IVTV_DEBUG_API("API Call: %s\n", api_info[cmd].name);
|
||||
}
|
||||
|
||||
/* clear possibly uninitialized part of data array */
|
||||
for (i = args; i < CX2341X_MBOX_MAX_DATA; i++)
|
||||
|
Loading…
Reference in New Issue
Block a user