	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function img_ir_set_decoder
_img_ir_set_decoder:                    ## @img_ir_set_decoder
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	56(%rdi), %r13
	callq	_spin_lock_irq
	movl	$1, 8(%rbx)
	movq	%rbx, %rdi
	callq	_spin_unlock_irq
	leaq	48(%rbx), %rdi
	callq	_del_timer_sync
	leaq	44(%rbx), %rdi
	callq	_del_timer_sync
	movq	%rbx, %rdi
	callq	_spin_lock_irq
	movl	$0, 8(%rbx)
	movq	_IMG_IR_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_img_ir_write
	movq	_IMG_IR_IRQ_ENABLE@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_img_ir_read
	movl	(%r12), %esi
	movq	_IMG_IR_IRQ_EDGE@GOTPCREL(%rip), %r12
	andl	(%r12), %eax
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_img_ir_write
	movq	_IMG_IR_IRQ_CLEAR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_IMG_IR_IRQ_ALL@GOTPCREL(%rip), %rax
	movl	(%r12), %edx
	notl	%edx
	andl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_img_ir_write
	movq	_IMG_IR_STATUS@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_img_ir_read
	movq	_IMG_IR_RXDVAL@GOTPCREL(%rip), %rdx
	movq	_IMG_IR_RXDVALD2@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rdx), %ecx
	testl	%eax, %ecx
	je	LBB0_2
## %bb.1:
	notl	%ecx
	andl	%ecx, %eax
	movl	(%r12), %esi
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_img_ir_write
LBB0_2:
	movq	_IMG_IR_DATA_LW@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_img_ir_read
	movq	_IMG_IR_DATA_UP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_img_ir_read
	movq	_IMG_IR_M_NORMAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 40(%rbx)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 8(%r13)
	movq	_RC_PROTO_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%r13)
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	__img_ir_set_filter
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	__img_ir_set_wake_filter
	movq	$0, 24(%rbx)
	movq	%r14, 32(%rbx)
	testq	%r14, %r14
	je	LBB0_6
## %bb.3:
	testq	%r15, %r15
	jne	LBB0_5
## %bb.4:
	movq	(%r14), %r15
LBB0_5:
	movq	%r15, 24(%rbx)
	leaq	12(%rbx), %rsi
	movl	20(%rbx), %edx
	movq	%r14, %rdi
	callq	_img_ir_decoder_convert
	leaq	16(%rbx), %rsi
	movq	_RC_FILTER_NORMAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_img_ir_write_timings
	movq	_IMG_IR_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	12(%rbx), %edx
	movq	%rbx, %rdi
	callq	_img_ir_write
LBB0_6:
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_spin_unlock_irq                ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_IMG_IR_CONTROL,4,2             ## @IMG_IR_CONTROL
	.comm	_IMG_IR_IRQ_ENABLE,4,2          ## @IMG_IR_IRQ_ENABLE
	.comm	_IMG_IR_IRQ_EDGE,4,2            ## @IMG_IR_IRQ_EDGE
	.comm	_IMG_IR_IRQ_CLEAR,4,2           ## @IMG_IR_IRQ_CLEAR
	.comm	_IMG_IR_IRQ_ALL,4,2             ## @IMG_IR_IRQ_ALL
	.comm	_IMG_IR_STATUS,4,2              ## @IMG_IR_STATUS
	.comm	_IMG_IR_RXDVAL,4,2              ## @IMG_IR_RXDVAL
	.comm	_IMG_IR_RXDVALD2,4,2            ## @IMG_IR_RXDVALD2
	.comm	_IMG_IR_DATA_LW,4,2             ## @IMG_IR_DATA_LW
	.comm	_IMG_IR_DATA_UP,4,2             ## @IMG_IR_DATA_UP
	.comm	_IMG_IR_M_NORMAL,4,2            ## @IMG_IR_M_NORMAL
	.comm	_RC_PROTO_UNKNOWN,4,2           ## @RC_PROTO_UNKNOWN
	.comm	_RC_FILTER_NORMAL,4,2           ## @RC_FILTER_NORMAL
	.no_dead_strip	_img_ir_set_decoder
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function img_ir_set_decoder
_img_ir_set_decoder:                    ; @img_ir_set_decoder
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x21, x2
	mov	x20, x1
	mov	x19, x0
	ldr	x23, [x0, #56]
	bl	_spin_lock_irq
	mov	w8, #1
	str	w8, [x19, #8]
	mov	x0, x19
	bl	_spin_unlock_irq
	add	x0, x19, #48
	bl	_del_timer_sync
	add	x0, x19, #44
	bl	_del_timer_sync
	mov	x0, x19
	bl	_spin_lock_irq
	str	wzr, [x19, #8]
Lloh0:
	adrp	x22, _IMG_IR_CONTROL@GOTPAGE
Lloh1:
	ldr	x22, [x22, _IMG_IR_CONTROL@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x19
	mov	w2, #0
	bl	_img_ir_write
Lloh2:
	adrp	x24, _IMG_IR_IRQ_ENABLE@GOTPAGE
Lloh3:
	ldr	x24, [x24, _IMG_IR_IRQ_ENABLE@GOTPAGEOFF]
	ldr	w1, [x24]
	mov	x0, x19
	bl	_img_ir_read
	ldr	w1, [x24]
Lloh4:
	adrp	x24, _IMG_IR_IRQ_EDGE@GOTPAGE
Lloh5:
	ldr	x24, [x24, _IMG_IR_IRQ_EDGE@GOTPAGEOFF]
	ldr	w8, [x24]
	and	w2, w8, w0
	mov	x0, x19
	bl	_img_ir_write
Lloh6:
	adrp	x8, _IMG_IR_IRQ_CLEAR@GOTPAGE
Lloh7:
	ldr	x8, [x8, _IMG_IR_IRQ_CLEAR@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
Lloh9:
	adrp	x8, _IMG_IR_IRQ_ALL@GOTPAGE
Lloh10:
	ldr	x8, [x8, _IMG_IR_IRQ_ALL@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	ldr	w9, [x24]
	bic	w2, w8, w9
	mov	x0, x19
	bl	_img_ir_write
Lloh12:
	adrp	x24, _IMG_IR_STATUS@GOTPAGE
Lloh13:
	ldr	x24, [x24, _IMG_IR_STATUS@GOTPAGEOFF]
	ldr	w1, [x24]
	mov	x0, x19
	bl	_img_ir_read
Lloh14:
	adrp	x8, _IMG_IR_RXDVAL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _IMG_IR_RXDVAL@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
Lloh17:
	adrp	x9, _IMG_IR_RXDVALD2@GOTPAGE
Lloh18:
	ldr	x9, [x9, _IMG_IR_RXDVALD2@GOTPAGEOFF]
Lloh19:
	ldr	w9, [x9]
	orr	w8, w9, w8
	tst	w8, w0
	b.eq	LBB0_2
; %bb.1:
	bic	w2, w0, w8
	ldr	w1, [x24]
	mov	x0, x19
	bl	_img_ir_write
LBB0_2:
Lloh20:
	adrp	x8, _IMG_IR_DATA_LW@GOTPAGE
Lloh21:
	ldr	x8, [x8, _IMG_IR_DATA_LW@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_img_ir_read
Lloh23:
	adrp	x8, _IMG_IR_DATA_UP@GOTPAGE
Lloh24:
	ldr	x8, [x8, _IMG_IR_DATA_UP@GOTPAGEOFF]
Lloh25:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_img_ir_read
Lloh26:
	adrp	x8, _IMG_IR_M_NORMAL@GOTPAGE
Lloh27:
	ldr	x8, [x8, _IMG_IR_M_NORMAL@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
	str	w8, [x19, #40]
	stp	xzr, xzr, [x23, #8]
Lloh29:
	adrp	x8, _RC_PROTO_UNKNOWN@GOTPAGE
Lloh30:
	ldr	x8, [x8, _RC_PROTO_UNKNOWN@GOTPAGEOFF]
Lloh31:
	ldr	w8, [x8]
	str	w8, [x23]
	mov	x0, x19
	mov	x1, #0
	bl	__img_ir_set_filter
	mov	x0, x19
	mov	x1, #0
	bl	__img_ir_set_wake_filter
	stp	xzr, x20, [x19, #24]
	cbz	x20, LBB0_6
; %bb.3:
	cbnz	x21, LBB0_5
; %bb.4:
	ldr	x21, [x20]
LBB0_5:
	str	x21, [x19, #24]
	add	x1, x19, #12
	ldr	w2, [x19, #20]
	mov	x0, x20
	bl	_img_ir_decoder_convert
	add	x1, x19, #16
Lloh32:
	adrp	x8, _RC_FILTER_NORMAL@GOTPAGE
Lloh33:
	ldr	x8, [x8, _RC_FILTER_NORMAL@GOTPAGEOFF]
Lloh34:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_img_ir_write_timings
	ldr	w1, [x22]
	ldr	w2, [x19, #12]
	mov	x0, x19
	bl	_img_ir_write
LBB0_6:
	mov	x0, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_spin_unlock_irq
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_IMG_IR_CONTROL,4,2             ; @IMG_IR_CONTROL
	.comm	_IMG_IR_IRQ_ENABLE,4,2          ; @IMG_IR_IRQ_ENABLE
	.comm	_IMG_IR_IRQ_EDGE,4,2            ; @IMG_IR_IRQ_EDGE
	.comm	_IMG_IR_IRQ_CLEAR,4,2           ; @IMG_IR_IRQ_CLEAR
	.comm	_IMG_IR_IRQ_ALL,4,2             ; @IMG_IR_IRQ_ALL
	.comm	_IMG_IR_STATUS,4,2              ; @IMG_IR_STATUS
	.comm	_IMG_IR_RXDVAL,4,2              ; @IMG_IR_RXDVAL
	.comm	_IMG_IR_RXDVALD2,4,2            ; @IMG_IR_RXDVALD2
	.comm	_IMG_IR_DATA_LW,4,2             ; @IMG_IR_DATA_LW
	.comm	_IMG_IR_DATA_UP,4,2             ; @IMG_IR_DATA_UP
	.comm	_IMG_IR_M_NORMAL,4,2            ; @IMG_IR_M_NORMAL
	.comm	_RC_PROTO_UNKNOWN,4,2           ; @RC_PROTO_UNKNOWN
	.comm	_RC_FILTER_NORMAL,4,2           ; @RC_FILTER_NORMAL
	.no_dead_strip	_img_ir_set_decoder
.subsections_via_symbols
