	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_av7110_ir_init                 ## -- Begin function av7110_ir_init
	.p2align	4, 0x90
_av7110_ir_init:                        ## @av7110_ir_init
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	_RC_DRIVER_SCANCODE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_rc_allocate_device
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	movq	24(%r14), %rax
	movq	(%rax), %r15
	movl	12(%r14), %r12d
	movq	%r15, %rdi
	callq	_pci_name
	leaq	L_.str(%rip), %rdx
	movl	%r12d, %edi
	movl	$4, %esi
	movq	%rax, %rcx
	callq	_snprintf
	movl	16(%r14), %eax
	movl	%eax, 64(%rbx)
	movq	_KBUILD_MODNAME@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 60(%rbx)
	movl	12(%r14), %eax
	movl	%eax, 56(%rbx)
	movq	_BUS_PCI@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 48(%rbx)
	movl	$2, 32(%rbx)
	movq	24(%r15), %rax
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	leaq	16(%r15), %rcx
	jmp	LBB0_5
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	jmp	LBB0_8
LBB0_4:
	movq	8(%r15), %rax
	leaq	4(%r15), %rcx
LBB0_5:
	movl	(%rcx), %ecx
	movq	%rax, 40(%rbx)
	movl	%ecx, 36(%rbx)
	movq	%r15, 24(%rbx)
	movq	_RC_PROTO_BIT_RC5@GOTPCREL(%rip), %rax
	movq	_RC_PROTO_BIT_RCMM32@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	movl	%ecx, (%rbx)
	movq	_change_protocol@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 20(%rbx)
	movq	_RC_MAP_HAUPPAUGE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 16(%rbx)
	movq	%r14, 8(%rbx)
	movq	%rbx, (%r14)
	movq	_IR_RC5@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 8(%r14)
	movq	%r14, %rdi
	callq	_av7110_set_ir_config
	movq	%rbx, %rdi
	callq	_rc_register_device
	testl	%eax, %eax
	je	LBB0_6
## %bb.7:
	movl	%eax, %r15d
	movq	$0, (%r14)
	movq	%rbx, %rdi
	callq	_rc_free_device
	jmp	LBB0_8
LBB0_6:
	xorl	%r15d, %r15d
LBB0_8:
	movl	%r15d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_RC_DRIVER_SCANCODE,4,2         ## @RC_DRIVER_SCANCODE
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"pci-%s/ir0"

	.comm	_KBUILD_MODNAME,4,2             ## @KBUILD_MODNAME
	.comm	_BUS_PCI,4,2                    ## @BUS_PCI
	.comm	_RC_PROTO_BIT_RC5,4,2           ## @RC_PROTO_BIT_RC5
	.comm	_RC_PROTO_BIT_RCMM32,4,2        ## @RC_PROTO_BIT_RCMM32
	.comm	_change_protocol,4,2            ## @change_protocol
	.comm	_RC_MAP_HAUPPAUGE,4,2           ## @RC_MAP_HAUPPAUGE
	.comm	_IR_RC5,4,2                     ## @IR_RC5
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_av7110_ir_init                 ; -- Begin function av7110_ir_init
	.p2align	2
_av7110_ir_init:                        ; @av7110_ir_init
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, _RC_DRIVER_SCANCODE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RC_DRIVER_SCANCODE@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_rc_allocate_device
	cbz	x0, LBB0_3
; %bb.1:
	mov	x20, x0
	ldr	x8, [x19, #24]
	ldr	x21, [x8]
	ldr	w22, [x19, #12]
	mov	x0, x21
	bl	_pci_name
	mov	x3, x0
Lloh3:
	adrp	x2, l_.str@PAGE
Lloh4:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x22
	mov	w1, #4
	bl	_snprintf
	ldp	w9, w8, [x19, #12]
	str	w8, [x20, #64]
Lloh5:
	adrp	x8, _KBUILD_MODNAME@GOTPAGE
Lloh6:
	ldr	x8, [x8, _KBUILD_MODNAME@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
Lloh8:
	adrp	x10, _BUS_PCI@GOTPAGE
Lloh9:
	ldr	x10, [x10, _BUS_PCI@GOTPAGEOFF]
	stp	w9, w8, [x20, #56]
Lloh10:
	ldr	w8, [x10]
	str	w8, [x20, #48]
	mov	w8, #2
	str	w8, [x20, #32]
	ldr	x8, [x21, #24]
	cbz	x8, LBB0_4
; %bb.2:
	add	x9, x21, #16
	b	LBB0_5
LBB0_3:
Lloh11:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_7
LBB0_4:
	ldr	x8, [x21, #8]
	add	x9, x21, #4
LBB0_5:
	ldr	w9, [x9]
	str	x8, [x20, #40]
	str	w9, [x20, #36]
	str	x21, [x20, #24]
Lloh14:
	adrp	x8, _RC_PROTO_BIT_RC5@GOTPAGE
Lloh15:
	ldr	x8, [x8, _RC_PROTO_BIT_RC5@GOTPAGEOFF]
Lloh16:
	adrp	x9, _RC_PROTO_BIT_RCMM32@GOTPAGE
Lloh17:
	ldr	x9, [x9, _RC_PROTO_BIT_RCMM32@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
Lloh19:
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x20]
Lloh20:
	adrp	x8, _change_protocol@GOTPAGE
Lloh21:
	ldr	x8, [x8, _change_protocol@GOTPAGEOFF]
Lloh22:
	ldr	w8, [x8]
Lloh23:
	adrp	x9, _RC_MAP_HAUPPAUGE@GOTPAGE
Lloh24:
	ldr	x9, [x9, _RC_MAP_HAUPPAUGE@GOTPAGEOFF]
Lloh25:
	ldr	w9, [x9]
	stp	w9, w8, [x20, #16]
	str	x19, [x20, #8]
	str	x20, [x19]
Lloh26:
	adrp	x8, _IR_RC5@GOTPAGE
Lloh27:
	ldr	x8, [x8, _IR_RC5@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
	str	w8, [x19, #8]
	mov	x0, x19
	bl	_av7110_set_ir_config
	mov	x0, x20
	bl	_rc_register_device
	mov	x21, x0
	cbz	w0, LBB0_7
; %bb.6:
	str	xzr, [x19]
	mov	x0, x20
	bl	_rc_free_device
LBB0_7:
	mov	x0, x21
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_RC_DRIVER_SCANCODE,4,2         ; @RC_DRIVER_SCANCODE
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"pci-%s/ir0"

	.comm	_KBUILD_MODNAME,4,2             ; @KBUILD_MODNAME
	.comm	_BUS_PCI,4,2                    ; @BUS_PCI
	.comm	_RC_PROTO_BIT_RC5,4,2           ; @RC_PROTO_BIT_RC5
	.comm	_RC_PROTO_BIT_RCMM32,4,2        ; @RC_PROTO_BIT_RCMM32
	.comm	_change_protocol,4,2            ; @change_protocol
	.comm	_RC_MAP_HAUPPAUGE,4,2           ; @RC_MAP_HAUPPAUGE
	.comm	_IR_RC5,4,2                     ; @IR_RC5
.subsections_via_symbols
