	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_v3d_irq_init                   ## -- Begin function v3d_irq_init
	.p2align	4, 0x90
_v3d_irq_init:                          ## @v3d_irq_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, %r15
	addq	$16, %rdi
	movq	_v3d_overflow_mem_work@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_INIT_WORK
	cmpl	$0, (%r15)
	jle	LBB0_3
## %bb.1:
	xorl	%ebx, %ebx
	movq	_V3D_CTL_INT_CLR@GOTPCREL(%rip), %r14
	movq	_V3D_CORE_IRQS@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r14), %esi
	movl	(%r12), %edx
	movl	%ebx, %edi
	callq	_V3D_CORE_WRITE
	incl	%ebx
	cmpl	(%r15), %ebx
	jl	LBB0_2
LBB0_3:
	movq	_V3D_HUB_INT_CLR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_V3D_HUB_IRQS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_V3D_WRITE
	movl	12(%r15), %edi
	movl	$1, %esi
	callq	_platform_get_irq
	movl	%eax, %r14d
	movq	_EPROBE_DEFER@GOTPCREL(%rip), %rbx
	movl	(%rbx), %eax
	addl	%r14d, %eax
	je	LBB0_12
## %bb.4:
	testl	%r14d, %r14d
	jle	LBB0_7
## %bb.5:
	movl	8(%r15), %edi
	movq	_v3d_irq@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_IRQF_SHARED@GOTPCREL(%rip), %r12
	movl	(%r12), %ecx
	leaq	L_.str(%rip), %r8
	movl	%r14d, %esi
	movq	%r15, %r9
	callq	_devm_request_irq
	movl	%eax, %r14d
	testl	%eax, %eax
	jne	LBB0_10
## %bb.6:
	movl	8(%r15), %r14d
	movl	12(%r15), %edi
	xorl	%esi, %esi
	callq	_platform_get_irq
	movq	_v3d_hub_irq@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	(%r12), %ecx
	leaq	L_.str.1(%rip), %r8
	jmp	LBB0_8
LBB0_7:
	movl	$1, 4(%r15)
	movl	8(%r15), %r14d
	movl	12(%r15), %edi
	xorl	%esi, %esi
	callq	_platform_get_irq
	movq	_v3d_irq@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	_IRQF_SHARED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	leaq	L_.str.2(%rip), %r8
LBB0_8:
	movl	%r14d, %edi
	movl	%eax, %esi
	movq	%r15, %r9
	callq	_devm_request_irq
	movl	%eax, %r14d
	testl	%eax, %eax
	je	LBB0_9
LBB0_10:
	movl	(%rbx), %eax
	addl	%r14d, %eax
	je	LBB0_12
## %bb.11:
	movl	8(%r15), %edi
	leaq	L_.str.3(%rip), %rsi
	movl	%r14d, %edx
	callq	_dev_err
	jmp	LBB0_12
LBB0_9:
	movq	%r15, %rdi
	callq	_v3d_irq_enable
	xorl	%r14d, %r14d
LBB0_12:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_v3d_overflow_mem_work,4,2      ## @v3d_overflow_mem_work
	.comm	_V3D_CTL_INT_CLR,4,2            ## @V3D_CTL_INT_CLR
	.comm	_V3D_CORE_IRQS,4,2              ## @V3D_CORE_IRQS
	.comm	_V3D_HUB_INT_CLR,4,2            ## @V3D_HUB_INT_CLR
	.comm	_V3D_HUB_IRQS,4,2               ## @V3D_HUB_IRQS
	.comm	_EPROBE_DEFER,4,2               ## @EPROBE_DEFER
	.comm	_v3d_irq,4,2                    ## @v3d_irq
	.comm	_IRQF_SHARED,4,2                ## @IRQF_SHARED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"v3d_core0"

	.comm	_v3d_hub_irq,4,2                ## @v3d_hub_irq
L_.str.1:                               ## @.str.1
	.asciz	"v3d_hub"

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

L_.str.3:                               ## @.str.3
	.asciz	"IRQ setup failed: %d\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_v3d_irq_init                   ; -- Begin function v3d_irq_init
	.p2align	2
_v3d_irq_init:                          ; @v3d_irq_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
	add	x0, x0, #16
Lloh0:
	adrp	x8, _v3d_overflow_mem_work@GOTPAGE
Lloh1:
	ldr	x8, [x8, _v3d_overflow_mem_work@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_INIT_WORK
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_3
; %bb.1:
	mov	w20, #0
Lloh3:
	adrp	x21, _V3D_CTL_INT_CLR@GOTPAGE
Lloh4:
	ldr	x21, [x21, _V3D_CTL_INT_CLR@GOTPAGEOFF]
Lloh5:
	adrp	x22, _V3D_CORE_IRQS@GOTPAGE
Lloh6:
	ldr	x22, [x22, _V3D_CORE_IRQS@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x21]
	ldr	w2, [x22]
	mov	x0, x20
	bl	_V3D_CORE_WRITE
	add	w20, w20, #1
	ldr	w8, [x19]
	cmp	w20, w8
	b.lt	LBB0_2
LBB0_3:
Lloh7:
	adrp	x8, _V3D_HUB_INT_CLR@GOTPAGE
Lloh8:
	ldr	x8, [x8, _V3D_HUB_INT_CLR@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
Lloh10:
	adrp	x8, _V3D_HUB_IRQS@GOTPAGE
Lloh11:
	ldr	x8, [x8, _V3D_HUB_IRQS@GOTPAGEOFF]
Lloh12:
	ldr	w1, [x8]
	bl	_V3D_WRITE
	ldr	w0, [x19, #12]
	mov	w1, #1
	bl	_platform_get_irq
	mov	x20, x0
Lloh13:
	adrp	x21, _EPROBE_DEFER@GOTPAGE
Lloh14:
	ldr	x21, [x21, _EPROBE_DEFER@GOTPAGEOFF]
	ldr	w8, [x21]
	cmn	w0, w8
	b.eq	LBB0_12
; %bb.4:
	cmp	w20, #1
	b.lt	LBB0_7
; %bb.5:
	ldr	w0, [x19, #8]
Lloh15:
	adrp	x8, _v3d_irq@GOTPAGE
Lloh16:
	ldr	x8, [x8, _v3d_irq@GOTPAGEOFF]
Lloh17:
	ldr	w2, [x8]
Lloh18:
	adrp	x22, _IRQF_SHARED@GOTPAGE
Lloh19:
	ldr	x22, [x22, _IRQF_SHARED@GOTPAGEOFF]
	ldr	w3, [x22]
Lloh20:
	adrp	x4, l_.str@PAGE
Lloh21:
	add	x4, x4, l_.str@PAGEOFF
	mov	x1, x20
	mov	x5, x19
	bl	_devm_request_irq
	mov	x20, x0
	cbnz	w0, LBB0_9
; %bb.6:
	ldp	w20, w0, [x19, #8]
	mov	w1, #0
	bl	_platform_get_irq
	mov	x1, x0
Lloh22:
	adrp	x8, _v3d_hub_irq@GOTPAGE
Lloh23:
	ldr	x8, [x8, _v3d_hub_irq@GOTPAGEOFF]
Lloh24:
	ldr	w2, [x8]
	ldr	w3, [x22]
Lloh25:
	adrp	x4, l_.str.1@PAGE
Lloh26:
	add	x4, x4, l_.str.1@PAGEOFF
	b	LBB0_8
LBB0_7:
	mov	w8, #1
	str	w8, [x19, #4]
	ldp	w20, w0, [x19, #8]
	mov	w1, #0
	bl	_platform_get_irq
	mov	x1, x0
Lloh27:
	adrp	x8, _v3d_irq@GOTPAGE
Lloh28:
	ldr	x8, [x8, _v3d_irq@GOTPAGEOFF]
Lloh29:
	ldr	w2, [x8]
Lloh30:
	adrp	x8, _IRQF_SHARED@GOTPAGE
Lloh31:
	ldr	x8, [x8, _IRQF_SHARED@GOTPAGEOFF]
Lloh32:
	ldr	w3, [x8]
Lloh33:
	adrp	x4, l_.str.2@PAGE
Lloh34:
	add	x4, x4, l_.str.2@PAGEOFF
LBB0_8:
	mov	x0, x20
	mov	x5, x19
	bl	_devm_request_irq
	mov	x20, x0
	cbz	w0, LBB0_11
LBB0_9:
	ldr	w8, [x21]
	cmn	w20, w8
	b.eq	LBB0_12
; %bb.10:
	ldr	w0, [x19, #8]
Lloh35:
	adrp	x1, l_.str.3@PAGE
Lloh36:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x2, x20
	bl	_dev_err
	b	LBB0_12
LBB0_11:
	mov	x0, x19
	bl	_v3d_irq_enable
	mov	w20, #0
LBB0_12:
	mov	x0, x20
	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 AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh35, Lloh36
	.cfi_endproc
                                        ; -- End function
	.comm	_v3d_overflow_mem_work,4,2      ; @v3d_overflow_mem_work
	.comm	_V3D_CTL_INT_CLR,4,2            ; @V3D_CTL_INT_CLR
	.comm	_V3D_CORE_IRQS,4,2              ; @V3D_CORE_IRQS
	.comm	_V3D_HUB_INT_CLR,4,2            ; @V3D_HUB_INT_CLR
	.comm	_V3D_HUB_IRQS,4,2               ; @V3D_HUB_IRQS
	.comm	_EPROBE_DEFER,4,2               ; @EPROBE_DEFER
	.comm	_v3d_irq,4,2                    ; @v3d_irq
	.comm	_IRQF_SHARED,4,2                ; @IRQF_SHARED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"v3d_core0"

	.comm	_v3d_hub_irq,4,2                ; @v3d_hub_irq
l_.str.1:                               ; @.str.1
	.asciz	"v3d_hub"

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

l_.str.3:                               ; @.str.3
	.asciz	"IRQ setup failed: %d\n"

.subsections_via_symbols
