Lines Matching +full:1 +full:mb

22 #define API_FAST (1 << 2) /* Short timeout */
23 #define API_SLOW (1 << 3) /* Additional 300ms timeout */
91 /* Call with buf of n*11+1 bytes */
105 static void dump_mb(struct cx18 *cx, struct cx18_mailbox *mb, char *name) in dump_mb() argument
107 char argstr[MAX_MB_ARGUMENTS*11+1]; in dump_mb()
113 name, mb->request, mb->ack, mb->cmd, mb->error, in dump_mb()
114 u32arr2hex(mb->args, MAX_MB_ARGUMENTS, argstr)); in dump_mb()
186 dispatch = 1; in cx18_mdl_send_to_videobuf()
233 struct cx18_mailbox *mb; in epu_dma_done() local
239 mb = &order->mb; in epu_dma_done()
240 handle = mb->args[0]; in epu_dma_done()
247 "stale" : "good", mb->request); in epu_dma_done()
251 mdl_ack_count = mb->args[2]; in epu_dma_done()
280 mb->request); in epu_dma_done()
319 if (s->id != -1) in epu_dma_done()
328 CX18_DEBUG_INFO("%x %s\n", order->mb.args[0], str); in epu_debug()
331 CX18_INFO("FW version: %s\n", p - 1); in epu_debug()
339 switch (order->mb.cmd) { in epu_cmd()
348 order->mb.cmd); in epu_cmd()
355 order->mb.cmd); in epu_cmd()
398 order->rpu, order->mb.cmd); in mb_ack_irq()
402 req = order->mb.request; in mb_ack_irq()
419 struct cx18_mailbox *mb; in epu_dma_done_irq() local
422 mb = &order->mb; in epu_dma_done_irq()
423 handle = mb->args[0]; in epu_dma_done_irq()
424 mdl_ack_offset = mb->args[1]; in epu_dma_done_irq()
425 mdl_ack_count = mb->args[2]; in epu_dma_done_irq()
431 return -1; in epu_dma_done_irq()
440 return 1; in epu_dma_done_irq()
450 str_offset = order->mb.args[1]; in epu_debug_irq()
461 return str_offset ? 1 : 0; in epu_debug_irq()
467 int ret = -1; in epu_cmd_irq()
472 switch (order->mb.cmd) { in epu_cmd_irq()
481 order->mb.cmd); in epu_cmd_irq()
488 order->mb.cmd); in epu_cmd_irq()
506 * 1. Any work handler thread only clears "pending" and only in alloc_in_work_order_irq()
513 atomic_set(&order->pending, 1); in alloc_in_work_order_irq()
522 struct cx18_mailbox __iomem *mb; in cx18_api_epu_cmd_irq() local
530 mb = &cx->scb->cpu2epu_mb; in cx18_api_epu_cmd_irq()
533 mb = &cx->scb->apu2epu_mb; in cx18_api_epu_cmd_irq()
547 order_mb = &order->mb; in cx18_api_epu_cmd_irq()
549 /* mb->cmd and mb->args[0] through mb->args[2] */ in cx18_api_epu_cmd_irq()
551 (&order_mb->cmd)[i] = cx18_readl(cx, &mb->cmd + i); in cx18_api_epu_cmd_irq()
553 /* mb->request and mb->ack. N.B. we want to read mb->ack last */ in cx18_api_epu_cmd_irq()
555 (&order_mb->request)[i] = cx18_readl(cx, &mb->request + i); in cx18_api_epu_cmd_irq()
584 struct cx18_mailbox __iomem *mb; in cx18_api_call() local
589 char argstr[MAX_MB_ARGUMENTS*11+1]; in cx18_api_call()
614 mb = &cx->scb->epu2apu_mb; in cx18_api_call()
620 mb = &cx->scb->epu2cpu_mb; in cx18_api_call()
638 req = cx18_readl(cx, &mb->request); in cx18_api_call()
641 (ack = cx18_readl(cx, &mb->ack)) == req, in cx18_api_call()
645 cx18_writel(cx, req, &mb->ack); in cx18_api_call()
653 req = ((req & 0xfffffffe) == 0xfffffffe) ? 1 : req + 1; in cx18_api_call()
655 cx18_writel(cx, cmd, &mb->cmd); in cx18_api_call()
657 cx18_writel(cx, data[i], &mb->args[i]); in cx18_api_call()
658 cx18_writel(cx, 0, &mb->error); in cx18_api_call()
659 cx18_writel(cx, req, &mb->request); in cx18_api_call()
660 cx18_writel(cx, req - 1, &mb->ack); /* ensure ack & req are distinct */ in cx18_api_call()
675 ack = cx18_readl(cx, &mb->ack); in cx18_api_call()
679 ack = cx18_readl(cx, &mb->ack); in cx18_api_call()
710 data[i] = cx18_readl(cx, &mb->args[i]); in cx18_api_call()
711 err = cx18_readl(cx, &mb->error); in cx18_api_call()
739 mode = (cx->filter_mode & 1) ? 2 : (cx->spatial_strength ? 1 : 0); in cx18_set_filter_param()
741 s->handle, 1, mode, cx->spatial_strength); in cx18_set_filter_param()
742 mode = (cx->filter_mode & 2) ? 2 : (cx->temporal_strength ? 1 : 0); in cx18_set_filter_param()
764 s->handle, data[1], data[0]); in cx18_api_func()
774 s->handle, data[0], data[1]); in cx18_api_func()
785 s->handle, data[0], data[1], data[2], data[3]); in cx18_api_func()
794 s->handle, data[0], data[1], data[2]); in cx18_api_func()
796 cx->filter_mode = (data[0] & 3) | (data[1] << 2); in cx18_api_func()
800 cx->temporal_strength = data[1]; in cx18_api_func()
804 s->handle, data[0], data[1]); in cx18_api_func()
807 s->handle, data[0], data[1], data[2], data[3]); in cx18_api_func()