	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_em28xx_ir_init                 ## -- Begin function em28xx_ir_init
	.p2align	4, 0x90
_em28xx_ir_init:                        ## @em28xx_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
	cmpq	$0, 16(%rdi)
	je	LBB0_7
## %bb.1:
	movq	%rdi, %r14
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$32, %edi
	callq	_kzalloc
	movq	%rax, %r15
	xorl	%eax, %eax
	callq	_rc_allocate_device
	movq	%rax, %r12
	testq	%r15, %r15
	je	LBB0_6
## %bb.2:
	testq	%r12, %r12
	je	LBB0_6
## %bb.3:
	movq	%r14, 24(%r15)
	movq	%r15, 8(%r14)
	movq	%r12, 16(%r15)
	movq	_RC_TYPE_RC5@GOTPCREL(%rip), %rax
	movq	_RC_TYPE_NEC@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	movl	%ecx, (%r12)
	movq	%r15, 88(%r12)
	movq	_em28xx_ir_change_protocol@GOTPCREL(%rip), %rax
	movq	%rax, 8(%r12)
	movq	_em28xx_ir_start@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 84(%r12)
	movq	_em28xx_ir_stop@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 80(%r12)
	movq	_RC_TYPE_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_em28xx_ir_change_protocol
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_6
## %bb.4:
	movl	$100, (%r15)
	movl	8(%r15), %edi
	movq	(%r14), %rcx
	leaq	L_.str(%rip), %rdx
	movl	$4, %esi
	callq	_snprintf
	movq	24(%r14), %rdi
	movl	4(%r15), %esi
	movl	$4, %edx
	callq	_usb_make_path
	movl	4(%r15), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	$4, %edx
	callq	_strlcat
	movl	8(%r15), %eax
	movl	%eax, 76(%r12)
	movl	4(%r15), %eax
	movl	%eax, 72(%r12)
	movq	_BUS_USB@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 64(%r12)
	movl	$1, 40(%r12)
	movq	24(%r14), %rax
	movl	8(%rax), %edi
	callq	_le16_to_cpu
	movq	%rax, 56(%r12)
	movq	24(%r14), %rax
	movl	4(%rax), %edi
	callq	_le16_to_cpu
	movq	%rax, 48(%r12)
	movq	24(%r14), %rax
	movq	%rax, 32(%r12)
	movq	16(%r14), %rax
	movq	%rax, 24(%r12)
	movq	_MODULE_NAME@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 16(%r12)
	movq	%r12, %rdi
	callq	_rc_register_device
	testl	%eax, %eax
	je	LBB0_7
## %bb.5:
	movl	%eax, %ebx
	movq	$0, 8(%r14)
LBB0_6:
	movq	%r12, %rdi
	callq	_rc_free_device
	movq	%r15, %rdi
	callq	_kfree
	jmp	LBB0_8
LBB0_7:
	xorl	%ebx, %ebx
LBB0_8:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_RC_TYPE_RC5,4,2                ## @RC_TYPE_RC5
	.comm	_RC_TYPE_NEC,4,2                ## @RC_TYPE_NEC
	.comm	_em28xx_ir_start,4,2            ## @em28xx_ir_start
	.comm	_em28xx_ir_stop,4,2             ## @em28xx_ir_stop
	.comm	_RC_TYPE_UNKNOWN,4,2            ## @RC_TYPE_UNKNOWN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"em28xx IR (%s)"

L_.str.1:                               ## @.str.1
	.asciz	"/input0"

	.comm	_BUS_USB,4,2                    ## @BUS_USB
	.comm	_MODULE_NAME,4,2                ## @MODULE_NAME
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_em28xx_ir_init                 ; -- Begin function em28xx_ir_init
	.p2align	2
_em28xx_ir_init:                        ; @em28xx_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
	ldr	x8, [x0, #16]
	cbz	x8, LBB0_3
; %bb.1:
	mov	x20, x0
Lloh0:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh2:
	ldr	w22, [x8]
Lloh3:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	w0, #32
	bl	_kzalloc
	mov	x19, x0
	bl	_rc_allocate_device
	mov	x21, x0
	cmp	x19, #0
	ccmp	x0, #0, #4, ne
	b.ne	LBB0_4
; %bb.2:
	neg	w22, w22
	b	LBB0_7
LBB0_3:
	mov	w22, #0
	b	LBB0_8
LBB0_4:
	str	x19, [x20, #8]
	stp	x21, x20, [x19, #16]
Lloh6:
	adrp	x8, _RC_TYPE_RC5@GOTPAGE
Lloh7:
	ldr	x8, [x8, _RC_TYPE_RC5@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
Lloh9:
	adrp	x9, _RC_TYPE_NEC@GOTPAGE
Lloh10:
	ldr	x9, [x9, _RC_TYPE_NEC@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x21]
	str	x19, [x21, #88]
Lloh12:
	adrp	x8, _em28xx_ir_change_protocol@GOTPAGE
Lloh13:
	ldr	x8, [x8, _em28xx_ir_change_protocol@GOTPAGEOFF]
	str	x8, [x21, #8]
Lloh14:
	adrp	x8, _em28xx_ir_start@GOTPAGE
Lloh15:
	ldr	x8, [x8, _em28xx_ir_start@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
Lloh17:
	adrp	x9, _em28xx_ir_stop@GOTPAGE
Lloh18:
	ldr	x9, [x9, _em28xx_ir_stop@GOTPAGEOFF]
Lloh19:
	ldr	w9, [x9]
	stp	w9, w8, [x21, #80]
Lloh20:
	adrp	x8, _RC_TYPE_UNKNOWN@GOTPAGE
Lloh21:
	ldr	x8, [x8, _RC_TYPE_UNKNOWN@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_em28xx_ir_change_protocol
	mov	x22, x0
	cbnz	w0, LBB0_7
; %bb.5:
	mov	w8, #100
	str	w8, [x19]
	ldr	w0, [x19, #8]
	ldr	x3, [x20]
Lloh23:
	adrp	x2, l_.str@PAGE
Lloh24:
	add	x2, x2, l_.str@PAGEOFF
	mov	w1, #4
	bl	_snprintf
	ldr	x0, [x20, #24]
	ldr	w1, [x19, #4]
	mov	w2, #4
	bl	_usb_make_path
	ldr	w0, [x19, #4]
Lloh25:
	adrp	x1, l_.str.1@PAGE
Lloh26:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	w2, #4
	bl	_strlcat
	ldur	d0, [x19, #4]
	str	d0, [x21, #72]
Lloh27:
	adrp	x8, _BUS_USB@GOTPAGE
Lloh28:
	ldr	x8, [x8, _BUS_USB@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
	str	w8, [x21, #64]
	mov	w8, #1
	str	w8, [x21, #40]
	ldr	x8, [x20, #24]
	ldr	w0, [x8, #8]
	bl	_le16_to_cpu
	str	x0, [x21, #56]
	ldr	x8, [x20, #24]
	ldr	w0, [x8, #4]
	bl	_le16_to_cpu
	str	x0, [x21, #48]
	ldp	x9, x8, [x20, #16]
	stp	x9, x8, [x21, #24]
Lloh30:
	adrp	x8, _MODULE_NAME@GOTPAGE
Lloh31:
	ldr	x8, [x8, _MODULE_NAME@GOTPAGEOFF]
Lloh32:
	ldr	w8, [x8]
	str	w8, [x21, #16]
	mov	x0, x21
	bl	_rc_register_device
	mov	x22, x0
	cbz	w0, LBB0_8
; %bb.6:
	str	xzr, [x20, #8]
LBB0_7:
	mov	x0, x21
	bl	_rc_free_device
	mov	x0, x19
	bl	_kfree
LBB0_8:
	mov	x0, x22
	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	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.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 AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_RC_TYPE_RC5,4,2                ; @RC_TYPE_RC5
	.comm	_RC_TYPE_NEC,4,2                ; @RC_TYPE_NEC
	.comm	_em28xx_ir_start,4,2            ; @em28xx_ir_start
	.comm	_em28xx_ir_stop,4,2             ; @em28xx_ir_stop
	.comm	_RC_TYPE_UNKNOWN,4,2            ; @RC_TYPE_UNKNOWN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"em28xx IR (%s)"

l_.str.1:                               ; @.str.1
	.asciz	"/input0"

	.comm	_BUS_USB,4,2                    ; @BUS_USB
	.comm	_MODULE_NAME,4,2                ; @MODULE_NAME
.subsections_via_symbols
