	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function img_ir_probe
_img_ir_probe:                          ## @img_ir_probe
	.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	%rdi, %rbx
	xorl	%esi, %esi
	callq	_platform_get_irq
	movl	%eax, %r15d
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	movl	$48, %esi
	callq	_devm_kzalloc
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	%rax, %r14
	movq	%rbx, %rdi
	movq	%rax, %rsi
	callq	_platform_set_drvdata
	movq	%rbx, 40(%r14)
	movq	%r14, %rdi
	addq	$32, %rdi
	callq	_spin_lock_init
	movq	_IORESOURCE_MEM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_platform_get_resource
	movq	%rbx, %rdi
	movq	%rax, %rsi
	callq	_devm_ioremap_resource
	movq	%rax, 24(%r14)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_5
## %bb.20:
	movq	24(%r14), %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_PTR_ERR                        ## TAILCALL
LBB0_1:
	movl	%r15d, %r12d
	jmp	LBB0_19
LBB0_3:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
LBB0_19:
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	callq	_devm_clk_get
	movq	%rax, 16(%r14)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdi
	callq	_dev_warn
LBB0_7:
	leaq	L_.str.2(%rip), %rsi
	movq	%rbx, %rdi
	callq	_devm_clk_get
	movq	%rax, 8(%r14)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	leaq	L_.str.3(%rip), %rsi
	movq	%rbx, %rdi
	callq	_dev_warn
LBB0_9:
	movq	8(%r14), %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_10
LBB0_12:
	movq	%r14, %rdi
	callq	_img_ir_probe_raw
	movl	%eax, %r13d
	movq	%r14, %rdi
	callq	_img_ir_probe_hw
	testl	%r13d, %r13d
	je	LBB0_15
## %bb.13:
	movl	%eax, %r12d
	testl	%eax, %eax
	je	LBB0_15
## %bb.14:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	addl	%r13d, %eax
	cmovnel	%r13d, %r12d
	jmp	LBB0_17
LBB0_15:
	movl	%r15d, (%r14)
	movq	_img_ir_isr@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.5(%rip), %rcx
	xorl	%r12d, %r12d
	movl	%r15d, %edi
	xorl	%edx, %edx
	movq	%r14, %r8
	callq	_request_irq
	testl	%eax, %eax
	je	LBB0_21
## %bb.16:
	movl	(%r14), %edx
	leaq	L_.str.6(%rip), %rsi
	movq	%rbx, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	movq	_EIO@GOTPCREL(%rip), %rax
	subl	(%rax), %r12d
	movq	%r14, %rdi
	callq	_img_ir_remove_hw
	movq	%r14, %rdi
	callq	_img_ir_remove_raw
LBB0_17:
	movq	8(%r14), %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	jne	LBB0_19
## %bb.18:
	movq	8(%r14), %rdi
	callq	_clk_disable_unprepare
	jmp	LBB0_19
LBB0_10:
	movq	8(%r14), %rdi
	callq	_clk_prepare_enable
	testl	%eax, %eax
	je	LBB0_12
## %bb.11:
	movl	%eax, %r12d
	leaq	L_.str.4(%rip), %rsi
	movq	%rbx, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_19
LBB0_21:
	movq	%r14, %rdi
	callq	_img_ir_ident
	movq	%r14, %rdi
	callq	_img_ir_setup
	jmp	LBB0_19
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_IORESOURCE_MEM,4,2             ## @IORESOURCE_MEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"core"

L_.str.1:                               ## @.str.1
	.asciz	"cannot get core clock resource\n"

L_.str.2:                               ## @.str.2
	.asciz	"sys"

L_.str.3:                               ## @.str.3
	.asciz	"cannot get sys clock resource\n"

L_.str.4:                               ## @.str.4
	.asciz	"cannot enable sys clock\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_img_ir_isr,4,2                 ## @img_ir_isr
L_.str.5:                               ## @.str.5
	.asciz	"img-ir"

L_.str.6:                               ## @.str.6
	.asciz	"cannot register IRQ %u\n"

	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_img_ir_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function img_ir_probe
_img_ir_probe:                          ; @img_ir_probe
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x21, x0
	mov	w1, #0
	bl	_platform_get_irq
	mov	x20, x0
	tbnz	w0, #31, LBB0_5
; %bb.1:
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	mov	x0, x21
	mov	w1, #48
	bl	_devm_kzalloc
	cbz	x0, LBB0_4
; %bb.2:
	mov	x19, x0
	mov	x0, x21
	mov	x1, x19
	bl	_platform_set_drvdata
	str	x21, [x19, #40]
	add	x0, x19, #32
	bl	_spin_lock_init
Lloh3:
	adrp	x8, _IORESOURCE_MEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IORESOURCE_MEM@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x21
	mov	w2, #0
	bl	_platform_get_resource
	mov	x1, x0
	mov	x0, x21
	bl	_devm_ioremap_resource
	str	x0, [x19, #24]
	bl	_IS_ERR
	cbz	x0, LBB0_6
; %bb.3:
	ldr	x0, [x19, #24]
	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
	add	sp, sp, #64
	b	_PTR_ERR
LBB0_4:
Lloh6:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_5:
	mov	x0, x20
	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
	add	sp, sp, #64
	ret
LBB0_6:
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x21
	bl	_devm_clk_get
	str	x0, [x19, #16]
	bl	_IS_ERR
	cbz	x0, LBB0_8
; %bb.7:
Lloh11:
	adrp	x1, l_.str.1@PAGE
Lloh12:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x21
	bl	_dev_warn
LBB0_8:
Lloh13:
	adrp	x1, l_.str.2@PAGE
Lloh14:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x21
	bl	_devm_clk_get
	str	x0, [x19, #8]
	bl	_IS_ERR
	cbz	x0, LBB0_10
; %bb.9:
Lloh15:
	adrp	x1, l_.str.3@PAGE
Lloh16:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x21
	bl	_dev_warn
LBB0_10:
	ldr	x0, [x19, #8]
	bl	_IS_ERR
	cbz	x0, LBB0_18
LBB0_11:
	mov	x0, x19
	bl	_img_ir_probe_raw
	mov	x22, x0
	mov	x0, x19
	bl	_img_ir_probe_hw
	cbz	w22, LBB0_14
; %bb.12:
	cbz	w0, LBB0_14
; %bb.13:
Lloh17:
	adrp	x8, _ENODEV@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	cmn	w22, w8
	csel	w20, w0, w22, eq
	b	LBB0_16
LBB0_14:
	str	w20, [x19]
Lloh20:
	adrp	x8, _img_ir_isr@GOTPAGE
Lloh21:
	ldr	x8, [x8, _img_ir_isr@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
Lloh23:
	adrp	x3, l_.str.5@PAGE
Lloh24:
	add	x3, x3, l_.str.5@PAGEOFF
	mov	x0, x20
	mov	w2, #0
	mov	x4, x19
	bl	_request_irq
	cbz	w0, LBB0_20
; %bb.15:
	ldr	w8, [x19]
	str	x8, [sp]
Lloh25:
	adrp	x1, l_.str.6@PAGE
Lloh26:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x0, x21
	bl	_dev_err
Lloh27:
	adrp	x8, _EIO@GOTPAGE
Lloh28:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
	neg	w20, w8
	mov	x0, x19
	bl	_img_ir_remove_hw
	mov	x0, x19
	bl	_img_ir_remove_raw
LBB0_16:
	ldr	x0, [x19, #8]
	bl	_IS_ERR
	cbnz	x0, LBB0_5
; %bb.17:
	ldr	x0, [x19, #8]
	bl	_clk_disable_unprepare
	b	LBB0_5
LBB0_18:
	ldr	x0, [x19, #8]
	bl	_clk_prepare_enable
	cbz	w0, LBB0_11
; %bb.19:
	mov	x22, x0
Lloh30:
	adrp	x1, l_.str.4@PAGE
Lloh31:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x21
	bl	_dev_err
	mov	x20, x22
	b	LBB0_5
LBB0_20:
	mov	x0, x19
	bl	_img_ir_ident
	mov	x0, x19
	bl	_img_ir_setup
	mov	w20, #0
	b	LBB0_5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh30, Lloh31
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_IORESOURCE_MEM,4,2             ; @IORESOURCE_MEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"core"

l_.str.1:                               ; @.str.1
	.asciz	"cannot get core clock resource\n"

l_.str.2:                               ; @.str.2
	.asciz	"sys"

l_.str.3:                               ; @.str.3
	.asciz	"cannot get sys clock resource\n"

l_.str.4:                               ; @.str.4
	.asciz	"cannot enable sys clock\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_img_ir_isr,4,2                 ; @img_ir_isr
l_.str.5:                               ; @.str.5
	.asciz	"img-ir"

l_.str.6:                               ; @.str.6
	.asciz	"cannot register IRQ %u\n"

	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_img_ir_probe
.subsections_via_symbols
