	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mv_ic_attach
_mv_ic_attach:                          ## @mv_ic_attach
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movl	%edi, %r14d
	callq	_device_get_softc
	movq	%rax, %rbx
	movq	_mv_ic_sc@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	jne	LBB0_1
## %bb.2:
	movq	%rbx, (%rax)
	leaq	-24(%rbp), %rdi
	leaq	-32(%rbp), %rsi
	callq	_soc_id
	movq	$0, (%rbx)
	movq	-24(%rbp), %rax
	movq	_MV_DEV_88F6281@GOTPCREL(%rip), %rsi
	movq	_MV_DEV_MV78100@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	_MV_DEV_MV78100_Z0@GOTPCREL(%rip), %rdx
	cmpq	(%rsi), %rax
	je	LBB0_6
## %bb.3:
	movq	_MV_DEV_88F6282@GOTPCREL(%rip), %rsi
	cmpq	(%rsi), %rax
	je	LBB0_6
## %bb.4:
	cmpq	%rcx, %rax
	je	LBB0_6
## %bb.5:
	movq	(%rdx), %rsi
	cmpq	%rsi, %rax
	jne	LBB0_7
LBB0_6:
	movl	$1, (%rbx)
	movq	(%rdx), %rsi
LBB0_7:
	cmpq	%rcx, %rax
	je	LBB0_9
## %bb.8:
	cmpq	%rsi, %rax
	jne	LBB0_10
LBB0_9:
	movl	$1, 4(%rbx)
LBB0_10:
	movq	_mv_ic_spec@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	8(%rbx), %rdx
	movl	%r14d, %edi
	callq	_bus_alloc_resources
	testl	%eax, %eax
	je	LBB0_12
## %bb.11:
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edi
	callq	_device_printf
LBB0_1:
	movq	_ENXIO@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
LBB0_13:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_12:
	movq	8(%rbx), %rax
	movl	(%rax), %edi
	callq	_rman_get_bustag
	movl	%eax, 20(%rbx)
	movq	8(%rbx), %rax
	movl	(%rax), %edi
	callq	_rman_get_bushandle
	movl	%eax, 16(%rbx)
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_arm_mask_irq_all
	jmp	LBB0_13
	.cfi_endproc
                                        ## -- End function
	.comm	_mv_ic_sc,8,3                   ## @mv_ic_sc
	.comm	_ENXIO,4,2                      ## @ENXIO
	.comm	_MV_DEV_88F6281,8,3             ## @MV_DEV_88F6281
	.comm	_MV_DEV_88F6282,8,3             ## @MV_DEV_88F6282
	.comm	_MV_DEV_MV78100,8,3             ## @MV_DEV_MV78100
	.comm	_MV_DEV_MV78100_Z0,8,3          ## @MV_DEV_MV78100_Z0
	.comm	_mv_ic_spec,4,2                 ## @mv_ic_spec
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"could not allocate resources\n"

	.no_dead_strip	_mv_ic_attach
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mv_ic_attach
_mv_ic_attach:                          ; @mv_ic_attach
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x20, x0
	bl	_device_get_softc
Lloh0:
	adrp	x8, _mv_ic_sc@GOTPAGE
Lloh1:
	ldr	x8, [x8, _mv_ic_sc@GOTPAGEOFF]
	ldr	x9, [x8]
	cbnz	x9, LBB0_7
; %bb.1:
	mov	x19, x0
	str	x0, [x8]
	add	x0, sp, #8
	mov	x1, sp
	bl	_soc_id
	str	xzr, [x19]
	ldr	x8, [sp, #8]
Lloh2:
	adrp	x9, _MV_DEV_88F6281@GOTPAGE
Lloh3:
	ldr	x9, [x9, _MV_DEV_88F6281@GOTPAGEOFF]
Lloh4:
	adrp	x10, _MV_DEV_88F6282@GOTPAGE
Lloh5:
	ldr	x10, [x10, _MV_DEV_88F6282@GOTPAGEOFF]
Lloh6:
	ldr	x12, [x9]
Lloh7:
	ldr	x13, [x10]
Lloh8:
	adrp	x9, _MV_DEV_MV78100@GOTPAGE
Lloh9:
	ldr	x9, [x9, _MV_DEV_MV78100@GOTPAGEOFF]
Lloh10:
	adrp	x11, _MV_DEV_MV78100_Z0@GOTPAGE
Lloh11:
	ldr	x11, [x11, _MV_DEV_MV78100_Z0@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x9]
	ldr	x10, [x11]
	cmp	x8, x12
	ccmp	x8, x13, #4, ne
	ccmp	x8, x9, #4, ne
	ccmp	x8, x10, #4, ne
	b.ne	LBB0_3
; %bb.2:
	mov	w10, #1
	str	w10, [x19]
	ldr	x10, [x11]
LBB0_3:
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	b.ne	LBB0_5
; %bb.4:
	mov	w8, #1
	str	w8, [x19, #4]
LBB0_5:
Lloh13:
	adrp	x8, _mv_ic_spec@GOTPAGE
Lloh14:
	ldr	x8, [x8, _mv_ic_spec@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x8]
	ldr	x2, [x19, #8]
	mov	x0, x20
	bl	_bus_alloc_resources
	cbz	w0, LBB0_9
; %bb.6:
Lloh16:
	adrp	x1, l_.str@PAGE
Lloh17:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_device_printf
LBB0_7:
Lloh18:
	adrp	x8, _ENXIO@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ENXIO@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
LBB0_8:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_9:
	ldr	x8, [x19, #8]
	ldr	w0, [x8]
	bl	_rman_get_bustag
	str	w0, [x19, #20]
	ldr	x8, [x19, #8]
	ldr	w0, [x8]
	bl	_rman_get_bushandle
	str	w0, [x19, #16]
	bl	_arm_mask_irq_all
	mov	w0, #0
	b	LBB0_8
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh12
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh6
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_mv_ic_sc,8,3                   ; @mv_ic_sc
	.comm	_ENXIO,4,2                      ; @ENXIO
	.comm	_MV_DEV_88F6281,8,3             ; @MV_DEV_88F6281
	.comm	_MV_DEV_88F6282,8,3             ; @MV_DEV_88F6282
	.comm	_MV_DEV_MV78100,8,3             ; @MV_DEV_MV78100
	.comm	_MV_DEV_MV78100_Z0,8,3          ; @MV_DEV_MV78100_Z0
	.comm	_mv_ic_spec,4,2                 ; @mv_ic_spec
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"could not allocate resources\n"

	.no_dead_strip	_mv_ic_attach
.subsections_via_symbols
