Lines Matching full:decoder
3 * ImgTec IR Hardware Decoder found in PowerDown Controller.
9 * translation functions to set up the hardware decoder and interpret the
58 * The decoder generates rapid interrupts without actually having
311 * img_ir_decoder_preprocess() - Preprocess timings in decoder.
312 * @decoder: Decoder to be preprocessed.
317 static void img_ir_decoder_preprocess(struct img_ir_decoder *decoder) in img_ir_decoder_preprocess() argument
320 if (!decoder->tolerance) in img_ir_decoder_preprocess()
321 decoder->tolerance = 10; /* percent */ in img_ir_decoder_preprocess()
323 decoder->tolerance = decoder->tolerance * 128 / 100; in img_ir_decoder_preprocess()
326 img_ir_timings_preprocess(&decoder->timings, decoder->unit); in img_ir_decoder_preprocess()
329 if (decoder->repeat) { in img_ir_decoder_preprocess()
330 img_ir_timings_preprocess(&decoder->rtimings, decoder->unit); in img_ir_decoder_preprocess()
331 img_ir_timings_defaults(&decoder->rtimings, &decoder->timings); in img_ir_decoder_preprocess()
336 * img_ir_decoder_convert() - Generate internal timings in decoder.
337 * @decoder: Decoder to be converted to internal timings.
344 static void img_ir_decoder_convert(const struct img_ir_decoder *decoder, in img_ir_decoder_convert() argument
349 reg_timings->ctrl = img_ir_control(&decoder->control); in img_ir_decoder_convert()
352 img_ir_timings_convert(®_timings->timings, &decoder->timings, in img_ir_decoder_convert()
353 decoder->tolerance, clock_hz); in img_ir_decoder_convert()
356 if (decoder->repeat) in img_ir_decoder_convert()
358 &decoder->rtimings, decoder->tolerance, in img_ir_decoder_convert()
478 /* current decoder must support scancode filtering */ in img_ir_set_filter()
479 if (!hw->decoder || !hw->decoder->filter) { in img_ir_set_filter()
489 ret = hw->decoder->filter(sc_filter, &filter, in img_ir_set_filter()
493 ret = hw->decoder->filter(sc_filter, &filter, in img_ir_set_filter()
534 * img_ir_set_decoder() - Set the current decoder.
536 * @decoder: Decoder to use with immediate effect.
537 * @proto: Protocol bitmap (or 0 to use decoder->type).
540 const struct img_ir_decoder *decoder, in img_ir_set_decoder() argument
597 /* switch decoder */ in img_ir_set_decoder()
598 hw->decoder = decoder; in img_ir_set_decoder()
599 if (!decoder) in img_ir_set_decoder()
604 proto = decoder->type; in img_ir_set_decoder()
608 img_ir_decoder_convert(decoder, &hw->reg_timings, hw->clk_hz); in img_ir_set_decoder()
620 * img_ir_decoder_compatible() - Find whether a decoder will work with a device.
622 * @dec: Decoder to check.
640 * img_ir_allowed_protos() - Get allowed protocols from global decoder list.
690 if (!hw->decoder || !hw->decoder->filter) in img_ir_change_protocol()
818 const struct img_ir_decoder *dec = hw->decoder; in img_ir_handle_data()
878 * img-ir decoder.
912 if (hw->decoder) { in img_ir_change_frequency()
913 img_ir_decoder_convert(hw->decoder, &hw->reg_timings, in img_ir_change_frequency()
959 /* use the current decoder */ in img_ir_isr_hw()
960 if (!hw->decoder) in img_ir_isr_hw()
963 ct = hw->decoder->control.code_type; in img_ir_isr_hw()
973 * received by the decoder. in img_ir_isr_hw()
974 * The decoder generates rapid interrupts without actually in img_ir_isr_hw()
1010 /* Use the first available decoder (or disable stuff if NULL) */ in img_ir_setup_hw()
1071 /* Allocate hardware decoder */ in img_ir_probe_hw()
1081 rdev->device_name = "IMG Infrared Decoder"; in img_ir_probe_hw()
1085 /* Register hardware decoder */ in img_ir_probe_hw()