	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function skge_set_ring_param
_skge_set_ring_param:                   ## @skge_set_ring_param
	.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	%rsi, %rbx
	movq	%rdi, %r14
	callq	_netdev_priv
	movq	(%rbx), %rcx
	testq	%rcx, %rcx
	je	LBB0_4
## %bb.1:
	movq	_MAX_RX_RING_SIZE@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jg	LBB0_4
## %bb.2:
	movq	8(%rbx), %rdx
	movq	_TX_LOW_WATER@GOTPCREL(%rip), %rsi
	cmpq	(%rsi), %rdx
	jl	LBB0_4
## %bb.3:
	movq	_MAX_TX_RING_SIZE@GOTPCREL(%rip), %rsi
	cmpq	(%rsi), %rdx
	jg	LBB0_4
## %bb.5:
	movq	%rcx, 8(%rax)
	movq	%rdx, (%rax)
	movq	%r14, %rdi
	callq	_netif_running
	xorl	%ebx, %ebx
	testq	%rax, %rax
	je	LBB0_8
## %bb.6:
	movq	%r14, %rdi
	callq	_skge_down
	movq	%r14, %rdi
	callq	_skge_up
	testl	%eax, %eax
	je	LBB0_8
## %bb.7:
	movl	%eax, %r15d
	movq	%r14, %rdi
	callq	_dev_close
	movl	%r15d, %ebx
	jmp	LBB0_8
LBB0_4:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_8:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_RX_RING_SIZE,8,3           ## @MAX_RX_RING_SIZE
	.comm	_TX_LOW_WATER,8,3               ## @TX_LOW_WATER
	.comm	_MAX_TX_RING_SIZE,8,3           ## @MAX_TX_RING_SIZE
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_skge_set_ring_param
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function skge_set_ring_param
_skge_set_ring_param:                   ; @skge_set_ring_param
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x20, x1
	mov	x19, x0
	bl	_netdev_priv
	ldr	x8, [x20]
Lloh0:
	adrp	x9, _MAX_RX_RING_SIZE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _MAX_RX_RING_SIZE@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, #0
	ccmp	x8, x9, #0, ne
	b.gt	LBB0_2
; %bb.1:
	ldr	x9, [x20, #8]
Lloh3:
	adrp	x10, _TX_LOW_WATER@GOTPAGE
Lloh4:
	ldr	x10, [x10, _TX_LOW_WATER@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
Lloh6:
	adrp	x11, _MAX_TX_RING_SIZE@GOTPAGE
Lloh7:
	ldr	x11, [x11, _MAX_TX_RING_SIZE@GOTPAGEOFF]
Lloh8:
	ldr	x11, [x11]
	cmp	x9, x10
	ccmp	x9, x11, #0, ge
	b.le	LBB0_4
LBB0_2:
Lloh9:
	adrp	x8, _EINVAL@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_3:
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_4:
	stp	x9, x8, [x0]
	mov	x0, x19
	bl	_netif_running
	cbz	x0, LBB0_7
; %bb.5:
	mov	x0, x19
	bl	_skge_down
	mov	x0, x19
	bl	_skge_up
	mov	x20, x0
	cbz	w0, LBB0_3
; %bb.6:
	mov	x0, x19
	bl	_dev_close
	b	LBB0_3
LBB0_7:
	mov	w20, #0
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_RX_RING_SIZE,8,3           ; @MAX_RX_RING_SIZE
	.comm	_TX_LOW_WATER,8,3               ; @TX_LOW_WATER
	.comm	_MAX_TX_RING_SIZE,8,3           ; @MAX_TX_RING_SIZE
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_skge_set_ring_param
.subsections_via_symbols
