	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function skge_ioctl
_skge_ioctl:                            ## @skge_ioctl
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r13d
	movq	%rdi, %r14
	movq	%rsi, %rdi
	callq	_if_mii
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	%r14, %rdi
	callq	_netdev_priv
	movq	%rax, %r15
	movq	8(%rax), %r12
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	%r14, %rdi
	callq	_netif_running
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	cmpl	$128, %r13d
	je	LBB0_11
## %bb.3:
	cmpl	$129, %r13d
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	%r12, %r14
	movq	%rax, %r12
	je	LBB0_7
## %bb.4:
	cmpl	$130, %r13d
	jne	LBB0_5
## %bb.6:
	movl	4(%r14), %eax
	movl	%eax, 12(%r12)
LBB0_7:
	movl	$0, -44(%rbp)
	movq	%r14, %rdi
	callq	_spin_lock_bh
	movq	%r14, %rdi
	callq	_is_genesis
	movl	(%r12), %edx
	andl	$31, %edx
	movl	(%r15), %esi
	leaq	-44(%rbp), %rcx
	movq	%r14, %rdi
	testl	%eax, %eax
	je	LBB0_9
## %bb.8:
	callq	___xm_phy_read
	jmp	LBB0_10
LBB0_1:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_15
LBB0_11:
	movq	%r12, %rdi
	callq	_spin_lock_bh
	movq	%r12, %rdi
	callq	_is_genesis
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movl	(%rcx), %edx
	movl	4(%rcx), %ecx
	andl	$31, %edx
	movl	(%r15), %esi
	movq	%r12, %rdi
	testl	%eax, %eax
	je	LBB0_13
## %bb.12:
	callq	_xm_phy_write
	jmp	LBB0_14
LBB0_5:
	negl	%ebx
	jmp	LBB0_15
LBB0_9:
	callq	___gm_phy_read
LBB0_10:
	movl	%eax, %ebx
	movq	%r14, %rdi
	callq	_spin_unlock_bh
	movl	-44(%rbp), %eax
	movl	%eax, 8(%r12)
	jmp	LBB0_15
LBB0_13:
	callq	_gm_phy_write
LBB0_14:
	movl	%eax, %ebx
	movq	%r12, %rdi
	callq	_spin_unlock_bh
LBB0_15:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
	.comm	_ENODEV,4,2                     ## @ENODEV
	.no_dead_strip	_skge_ioctl
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function skge_ioctl
_skge_ioctl:                            ; @skge_ioctl
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x22, x2
	mov	x23, x0
	mov	x0, x1
	bl	_if_mii
	mov	x20, x0
	mov	x0, x23
	bl	_netdev_priv
	mov	x21, x0
	ldr	x19, [x0, #8]
Lloh0:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
Lloh2:
	ldr	w24, [x8]
	mov	x0, x23
	bl	_netif_running
	cbz	w0, LBB0_7
; %bb.1:
	cmp	w22, #128
	b.eq	LBB0_8
; %bb.2:
	cmp	w22, #129
	b.eq	LBB0_5
; %bb.3:
	cmp	w22, #130
	b.ne	LBB0_10
; %bb.4:
	ldr	w8, [x19, #4]
	str	w8, [x20, #12]
LBB0_5:
	str	wzr, [sp, #12]
	mov	x0, x19
	bl	_spin_lock_bh
	mov	x0, x19
	bl	_is_genesis
	ldr	w1, [x21]
	ldr	w8, [x20]
	and	w2, w8, #0x1f
	add	x3, sp, #12
	cbz	w0, LBB0_11
; %bb.6:
	mov	x0, x19
	bl	___xm_phy_read
	b	LBB0_12
LBB0_7:
Lloh3:
	adrp	x8, _ENODEV@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_15
LBB0_8:
	mov	x0, x19
	bl	_spin_lock_bh
	mov	x0, x19
	bl	_is_genesis
	ldr	w1, [x21]
	ldp	w8, w3, [x20]
	and	w2, w8, #0x1f
	cbz	w0, LBB0_13
; %bb.9:
	mov	x0, x19
	bl	_xm_phy_write
	b	LBB0_14
LBB0_10:
	neg	w21, w24
	b	LBB0_15
LBB0_11:
	mov	x0, x19
	bl	___gm_phy_read
LBB0_12:
	mov	x21, x0
	mov	x0, x19
	bl	_spin_unlock_bh
	ldr	w8, [sp, #12]
	str	w8, [x20, #8]
	b	LBB0_15
LBB0_13:
	mov	x0, x19
	bl	_gm_phy_write
LBB0_14:
	mov	x21, x0
	mov	x0, x19
	bl	_spin_unlock_bh
LBB0_15:
	mov	x0, x21
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
	.comm	_ENODEV,4,2                     ; @ENODEV
	.no_dead_strip	_skge_ioctl
.subsections_via_symbols
