	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mv88e6352_ptp_enable_extts
_mv88e6352_ptp_enable_extts:            ## @mv88e6352_ptp_enable_extts
	.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
	movl	%edx, %r12d
	movq	%rdi, %r15
	movq	_PTP_RISING_EDGE@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	andl	(%rsi), %r14d
	movl	4(%rdi), %edi
	movq	_PTP_PF_EXTTS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	4(%rsi), %edx
	movl	%eax, %esi
	callq	_ptp_find_pin
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_mv88e6xxx_reg_lock
	testl	%r12d, %r12d
	je	LBB0_5
## %bb.3:
	movq	_MV88E6352_G2_SCRATCH_GPIO_PCTL_EVREQ@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	movl	%ebx, %esi
	movl	$1, %ecx
	callq	_mv88e6352_set_gpio_func
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_6
## %bb.4:
	movq	_TAI_EVENT_WORK_INTERVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_schedule_delayed_work
	movq	_PTP_CLOCK_EXTTS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_mv88e6352_config_eventcap
	movl	%eax, %ebx
	jmp	LBB0_6
LBB0_1:
	movq	_EBUSY@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_7
LBB0_5:
	movq	_MV88E6352_G2_SCRATCH_GPIO_PCTL_GPIO@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	movl	%ebx, %esi
	movl	$1, %ecx
	callq	_mv88e6352_set_gpio_func
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_cancel_delayed_work_sync
LBB0_6:
	movq	%r15, %rdi
	callq	_mv88e6xxx_reg_unlock
LBB0_7:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PTP_RISING_EDGE,4,2            ## @PTP_RISING_EDGE
	.comm	_PTP_PF_EXTTS,4,2               ## @PTP_PF_EXTTS
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_MV88E6352_G2_SCRATCH_GPIO_PCTL_EVREQ,4,2 ## @MV88E6352_G2_SCRATCH_GPIO_PCTL_EVREQ
	.comm	_TAI_EVENT_WORK_INTERVAL,4,2    ## @TAI_EVENT_WORK_INTERVAL
	.comm	_PTP_CLOCK_EXTTS,4,2            ## @PTP_CLOCK_EXTTS
	.comm	_MV88E6352_G2_SCRATCH_GPIO_PCTL_GPIO,4,2 ## @MV88E6352_G2_SCRATCH_GPIO_PCTL_GPIO
	.no_dead_strip	_mv88e6352_ptp_enable_extts
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mv88e6352_ptp_enable_extts
_mv88e6352_ptp_enable_extts:            ; @mv88e6352_ptp_enable_extts
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x20, x2
	mov	x19, x0
Lloh0:
	adrp	x8, _PTP_RISING_EDGE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PTP_RISING_EDGE@GOTPAGEOFF]
Lloh2:
	ldr	w22, [x8]
	ldr	w0, [x0, #4]
Lloh3:
	adrp	x8, _PTP_PF_EXTTS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PTP_PF_EXTTS@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	ldp	w23, w2, [x1]
	mov	x1, x8
	bl	_ptp_find_pin
	tbnz	w0, #31, LBB0_4
; %bb.1:
	mov	x21, x0
	mov	x0, x19
	bl	_mv88e6xxx_reg_lock
	cbz	w20, LBB0_5
; %bb.2:
Lloh6:
	adrp	x8, _MV88E6352_G2_SCRATCH_GPIO_PCTL_EVREQ@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MV88E6352_G2_SCRATCH_GPIO_PCTL_EVREQ@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x1, x21
	mov	w3, #1
	bl	_mv88e6352_set_gpio_func
	mov	x20, x0
	cbnz	w0, LBB0_6
; %bb.3:
	and	w20, w22, w23
Lloh9:
	adrp	x8, _TAI_EVENT_WORK_INTERVAL@GOTPAGE
Lloh10:
	ldr	x8, [x8, _TAI_EVENT_WORK_INTERVAL@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_schedule_delayed_work
Lloh12:
	adrp	x8, _PTP_CLOCK_EXTTS@GOTPAGE
Lloh13:
	ldr	x8, [x8, _PTP_CLOCK_EXTTS@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x20
	bl	_mv88e6352_config_eventcap
	mov	x20, x0
	b	LBB0_6
LBB0_4:
Lloh15:
	adrp	x8, _EBUSY@GOTPAGE
Lloh16:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	neg	w20, w8
	b	LBB0_7
LBB0_5:
Lloh18:
	adrp	x8, _MV88E6352_G2_SCRATCH_GPIO_PCTL_GPIO@GOTPAGE
Lloh19:
	ldr	x8, [x8, _MV88E6352_G2_SCRATCH_GPIO_PCTL_GPIO@GOTPAGEOFF]
Lloh20:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x1, x21
	mov	w3, #1
	bl	_mv88e6352_set_gpio_func
	mov	x20, x0
	mov	x0, x19
	bl	_cancel_delayed_work_sync
LBB0_6:
	mov	x0, x19
	bl	_mv88e6xxx_reg_unlock
LBB0_7:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_PTP_RISING_EDGE,4,2            ; @PTP_RISING_EDGE
	.comm	_PTP_PF_EXTTS,4,2               ; @PTP_PF_EXTTS
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_MV88E6352_G2_SCRATCH_GPIO_PCTL_EVREQ,4,2 ; @MV88E6352_G2_SCRATCH_GPIO_PCTL_EVREQ
	.comm	_TAI_EVENT_WORK_INTERVAL,4,2    ; @TAI_EVENT_WORK_INTERVAL
	.comm	_PTP_CLOCK_EXTTS,4,2            ; @PTP_CLOCK_EXTTS
	.comm	_MV88E6352_G2_SCRATCH_GPIO_PCTL_GPIO,4,2 ; @MV88E6352_G2_SCRATCH_GPIO_PCTL_GPIO
	.no_dead_strip	_mv88e6352_ptp_enable_extts
.subsections_via_symbols
