	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lan743x_ptp_reset
_lan743x_ptp_reset:                     ## @lan743x_ptp_reset
	.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	%rdi, %rbx
	leaq	4(%rdi), %r14
	movq	%r14, %rdi
	callq	_mutex_lock
	movq	%rbx, %rdi
	callq	_lan743x_ptp_is_enabled
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_drv@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%rbx), %edx
	leaq	L_.str(%rip), %rcx
	movq	%rbx, %rdi
	callq	_netif_err
	jmp	LBB0_3
LBB0_2:
	movq	_PTP_CMD_CTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_PTP_CMD_CTL_PTP_RESET_@GOTPCREL(%rip), %r15
	movl	(%r15), %edx
	movq	%rbx, %rdi
	callq	_lan743x_csr_write
	movl	(%r15), %esi
	movq	%rbx, %rdi
	callq	_lan743x_ptp_wait_till_cmd_done
LBB0_3:
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_mutex_unlock                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_drv,4,2                        ## @drv
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Attempting reset while enabled\n"

	.comm	_PTP_CMD_CTL,4,2                ## @PTP_CMD_CTL
	.comm	_PTP_CMD_CTL_PTP_RESET_,4,2     ## @PTP_CMD_CTL_PTP_RESET_
	.no_dead_strip	_lan743x_ptp_reset
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function lan743x_ptp_reset
_lan743x_ptp_reset:                     ; @lan743x_ptp_reset
	.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	x20, x0
	add	x19, x0, #4
	mov	x0, x19
	bl	_mutex_lock
	mov	x0, x20
	bl	_lan743x_ptp_is_enabled
	cbz	x0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _drv@GOTPAGE
Lloh1:
	ldr	x8, [x8, _drv@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	ldr	w2, [x20]
Lloh3:
	adrp	x3, l_.str@PAGE
Lloh4:
	add	x3, x3, l_.str@PAGEOFF
	mov	x0, x20
	bl	_netif_err
	b	LBB0_3
LBB0_2:
Lloh5:
	adrp	x8, _PTP_CMD_CTL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _PTP_CMD_CTL@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
Lloh8:
	adrp	x21, _PTP_CMD_CTL_PTP_RESET_@GOTPAGE
Lloh9:
	ldr	x21, [x21, _PTP_CMD_CTL_PTP_RESET_@GOTPAGEOFF]
	ldr	w2, [x21]
	mov	x0, x20
	bl	_lan743x_csr_write
	ldr	w1, [x21]
	mov	x0, x20
	bl	_lan743x_ptp_wait_till_cmd_done
LBB0_3:
	mov	x0, x19
	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
	b	_mutex_unlock
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_drv,4,2                        ; @drv
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Attempting reset while enabled\n"

	.comm	_PTP_CMD_CTL,4,2                ; @PTP_CMD_CTL
	.comm	_PTP_CMD_CTL_PTP_RESET_,4,2     ; @PTP_CMD_CTL_PTP_RESET_
	.no_dead_strip	_lan743x_ptp_reset
.subsections_via_symbols
