	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mv_wdt_attach
_mv_wdt_attach:                         ## @mv_wdt_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	%r15
	pushq	%r14
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_wdt_softc@GOTPCREL(%rip), %r15
	cmpq	$0, (%r15)
	jne	LBB0_1
## %bb.2:
	movl	%edi, %ebx
	callq	_device_get_softc
	movq	%rax, %r14
	movq	%rax, (%r15)
	movq	_mv_wdt_spec@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	12(%r14), %rdx
	movl	%ebx, %edi
	callq	_bus_alloc_resources
	testl	%eax, %eax
	je	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edi
	callq	_device_printf
LBB0_1:
	movq	_ENXIO@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
LBB0_9:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movq	%r14, %rdi
	addq	$8, %rdi
	movq	_MTX_DEF@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leaq	L_.str.1(%rip), %rsi
	xorl	%edx, %edx
	callq	_mtx_init
	movq	_mv_wdt_compat@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%ebx, %edi
	callq	_ofw_bus_search_compatible
	movq	(%rax), %rax
	movq	%rax, (%r14)
	cmpq	$0, (%rax)
	jne	LBB0_6
## %bb.5:
	xorl	%eax, %eax
	callq	_get_tclk
	movq	(%r14), %rcx
	movq	%rax, (%rcx)
LBB0_6:
	movq	(%r15), %rax
	movq	(%rax), %rax
	movq	8(%rax), %rcx
	testq	%rcx, %rcx
	je	LBB0_8
## %bb.7:
	xorl	%eax, %eax
	callq	*%rcx
LBB0_8:
	movq	_watchdog_list@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_mv_watchdog_event@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%ebx, %ebx
	movq	%r14, %rdx
	xorl	%ecx, %ecx
	callq	_EVENTHANDLER_REGISTER
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_wdt_softc,8,3                  ## @wdt_softc
	.comm	_ENXIO,4,2                      ## @ENXIO
	.comm	_mv_wdt_spec,4,2                ## @mv_wdt_spec
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"could not allocate resources\n"

L_.str.1:                               ## @.str.1
	.asciz	"watchdog"

	.comm	_MTX_DEF,4,2                    ## @MTX_DEF
	.comm	_mv_wdt_compat,4,2              ## @mv_wdt_compat
	.comm	_watchdog_list,4,2              ## @watchdog_list
	.comm	_mv_watchdog_event,4,2          ## @mv_watchdog_event
	.no_dead_strip	_mv_wdt_attach
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mv_wdt_attach
_mv_wdt_attach:                         ; @mv_wdt_attach
	.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
Lloh0:
	adrp	x21, _wdt_softc@GOTPAGE
Lloh1:
	ldr	x21, [x21, _wdt_softc@GOTPAGEOFF]
	ldr	x8, [x21]
	cbnz	x8, LBB0_3
; %bb.1:
	mov	x20, x0
	bl	_device_get_softc
	mov	x19, x0
	str	x0, [x21]
Lloh2:
	adrp	x8, _mv_wdt_spec@GOTPAGE
Lloh3:
	ldr	x8, [x8, _mv_wdt_spec@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	add	x2, x0, #12
	mov	x0, x20
	bl	_bus_alloc_resources
	cbz	w0, LBB0_5
; %bb.2:
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_device_printf
LBB0_3:
Lloh7:
	adrp	x8, _ENXIO@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ENXIO@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
LBB0_4:
	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
LBB0_5:
	add	x0, x19, #8
Lloh10:
	adrp	x8, _MTX_DEF@GOTPAGE
Lloh11:
	ldr	x8, [x8, _MTX_DEF@GOTPAGEOFF]
Lloh12:
	ldr	w3, [x8]
Lloh13:
	adrp	x1, l_.str.1@PAGE
Lloh14:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, #0
	bl	_mtx_init
Lloh15:
	adrp	x8, _mv_wdt_compat@GOTPAGE
Lloh16:
	ldr	x8, [x8, _mv_wdt_compat@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_ofw_bus_search_compatible
	ldr	x8, [x0]
	str	x8, [x19]
	ldr	x8, [x8]
	cbnz	x8, LBB0_7
; %bb.6:
	bl	_get_tclk
	ldr	x8, [x19]
	str	x0, [x8]
LBB0_7:
	ldr	x8, [x21]
	ldr	x8, [x8]
	ldr	x8, [x8, #8]
	cbz	x8, LBB0_9
; %bb.8:
	blr	x8
LBB0_9:
Lloh18:
	adrp	x8, _watchdog_list@GOTPAGE
Lloh19:
	ldr	x8, [x8, _watchdog_list@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
Lloh21:
	adrp	x8, _mv_watchdog_event@GOTPAGE
Lloh22:
	ldr	x8, [x8, _mv_watchdog_event@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
	mov	x2, x19
	mov	w3, #0
	bl	_EVENTHANDLER_REGISTER
	mov	w0, #0
	b	LBB0_4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_wdt_softc,8,3                  ; @wdt_softc
	.comm	_ENXIO,4,2                      ; @ENXIO
	.comm	_mv_wdt_spec,4,2                ; @mv_wdt_spec
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"could not allocate resources\n"

l_.str.1:                               ; @.str.1
	.asciz	"watchdog"

	.comm	_MTX_DEF,4,2                    ; @MTX_DEF
	.comm	_mv_wdt_compat,4,2              ; @mv_wdt_compat
	.comm	_watchdog_list,4,2              ; @watchdog_list
	.comm	_mv_watchdog_event,4,2          ; @mv_watchdog_event
	.no_dead_strip	_mv_wdt_attach
.subsections_via_symbols
