	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sja1105_rgmii_clocking_setup
_sja1105_rgmii_clocking_setup:          ## @sja1105_rgmii_clocking_setup
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	movl	%esi, %r15d
	movq	%rdi, %r13
	movq	8(%rdi), %rax
	movq	16(%rdi), %rcx
	movq	(%rcx), %r14
	movq	_BLK_IDX_MAC_CONFIG@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %rax
	movslq	%esi, %rdx
	movl	(%rax,%rdx,4), %r12d
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r14, %rdi
                                        ## kill: def $edx killed $edx killed $rdx
	movl	%r12d, %ecx
	xorl	%eax, %eax
	callq	_dev_dbg
	leal	-128(%r12), %eax
	cmpl	$3, %eax
	ja	LBB0_7
## %bb.1:
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_18:
	leaq	L_.str.1(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_dbg
	jmp	LBB0_19
LBB0_7:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	testl	%ebx, %ebx
	jns	LBB0_11
LBB0_9:
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_10
LBB0_6:
	movq	%r13, %rdi
	movl	%r15d, %esi
	movl	$1, %edx
	movl	$10, %ecx
	jmp	LBB0_4
LBB0_5:
	movq	%r13, %rdi
	movl	%r15d, %esi
	movl	$1, %edx
	jmp	LBB0_3
LBB0_2:
	movq	%r13, %rdi
	movl	%r15d, %esi
	xorl	%edx, %edx
LBB0_3:
	movl	$1, %ecx
LBB0_4:
	callq	_sja1105_cgu_idiv_config
	movl	%eax, %ebx
	testl	%ebx, %ebx
	js	LBB0_9
LBB0_11:
	movq	%r13, %rdi
	movl	%r15d, %esi
	movl	%r12d, %edx
	callq	_sja1105_cgu_rgmii_tx_clk_config
	testl	%eax, %eax
	js	LBB0_12
## %bb.13:
	movq	%r13, %rdi
	movl	%r15d, %esi
	callq	_sja1105_rgmii_cfg_pad_tx_config
	testl	%eax, %eax
	js	LBB0_14
## %bb.15:
	movq	(%r13), %rax
	movq	(%rax), %rax
	xorl	%ebx, %ebx
	testq	%rax, %rax
	je	LBB0_19
## %bb.16:
	movq	_XMII_MAC@GOTPCREL(%rip), %rcx
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	cmpq	%rdx, (%rcx)
	je	LBB0_19
## %bb.17:
	movq	%r13, %rdi
	movl	%r15d, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmpq	*%rax                           ## TAILCALL
LBB0_12:
	movl	%eax, %ebx
	leaq	L_.str.3(%rip), %rsi
	jmp	LBB0_10
LBB0_14:
	movl	%eax, %ebx
	leaq	L_.str.4(%rip), %rsi
LBB0_10:
	movq	%r14, %rdi
	callq	_dev_err
LBB0_19:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_18, LBB0_18-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
.set L0_0_set_2, LBB0_2-LJTI0_0
LJTI0_0:
	.long	L0_0_set_18
	.long	L0_0_set_6
	.long	L0_0_set_5
	.long	L0_0_set_2
	.end_data_region
                                        ## -- End function
	.comm	_BLK_IDX_MAC_CONFIG,8,3         ## @BLK_IDX_MAC_CONFIG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Configuring port %d RGMII at speed %dMbps\n"

L_.str.1:                               ## @.str.1
	.asciz	"Speed not available, skipping CGU config\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.2:                               ## @.str.2
	.asciz	"Failed to configure idiv\n"

L_.str.3:                               ## @.str.3
	.asciz	"Failed to configure RGMII Tx clock\n"

L_.str.4:                               ## @.str.4
	.asciz	"Failed to configure Tx pad registers\n"

	.comm	_XMII_MAC,8,3                   ## @XMII_MAC
	.no_dead_strip	_sja1105_rgmii_clocking_setup
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sja1105_rgmii_clocking_setup
_sja1105_rgmii_clocking_setup:          ; @sja1105_rgmii_clocking_setup
	.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	x19, x1
	mov	x20, x0
	ldp	x9, x8, [x0, #8]
Lloh0:
	adrp	x10, _BLK_IDX_MAC_CONFIG@GOTPAGE
Lloh1:
	ldr	x10, [x10, _BLK_IDX_MAC_CONFIG@GOTPAGEOFF]
	ldr	x21, [x8]
Lloh2:
	ldr	x8, [x10]
	ldr	x8, [x9, x8, lsl #3]
	ldr	w23, [x8, w1, sxtw #2]
	stp	x19, x23, [sp]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x21
	bl	_dev_dbg
	sub	w8, w23, #128
	cmp	w8, #3
	b.hi	LBB0_3
; %bb.1:
Lloh5:
	adrp	x9, lJTI0_0@PAGE
Lloh6:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_2
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_2:
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x21
	bl	_dev_dbg
	b	LBB0_13
LBB0_3:
Lloh9:
	adrp	x8, _EINVAL@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	neg	w24, w8
	tbz	w24, #31, LBB0_10
LBB0_4:
Lloh12:
	adrp	x1, l_.str.2@PAGE
Lloh13:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_16
LBB0_5:
	mov	x0, x20
	mov	x1, x19
	mov	w2, #1
	mov	w3, #10
	b	LBB0_9
LBB0_6:
	mov	x0, x20
	mov	x1, x19
	mov	w2, #1
	b	LBB0_8
LBB0_7:
	mov	x0, x20
	mov	x1, x19
	mov	w2, #0
LBB0_8:
	mov	w3, #1
LBB0_9:
	bl	_sja1105_cgu_idiv_config
	mov	x24, x0
	tbnz	w24, #31, LBB0_4
LBB0_10:
	mov	x0, x20
	mov	x1, x19
	mov	x2, x23
	bl	_sja1105_cgu_rgmii_tx_clk_config
	tbnz	w0, #31, LBB0_14
; %bb.11:
	mov	x0, x20
	mov	x1, x19
	bl	_sja1105_rgmii_cfg_pad_tx_config
	tbnz	w0, #31, LBB0_15
; %bb.12:
	ldr	x8, [x20]
	ldr	x2, [x8]
Lloh14:
	adrp	x8, _XMII_MAC@GOTPAGE
Lloh15:
	ldr	x8, [x8, _XMII_MAC@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	cmp	x2, #0
	ccmp	x8, x22, #4, ne
	b.ne	LBB0_18
LBB0_13:
	mov	w24, #0
	b	LBB0_17
LBB0_14:
	mov	x24, x0
Lloh17:
	adrp	x1, l_.str.3@PAGE
Lloh18:
	add	x1, x1, l_.str.3@PAGEOFF
	b	LBB0_16
LBB0_15:
	mov	x24, x0
Lloh19:
	adrp	x1, l_.str.4@PAGE
Lloh20:
	add	x1, x1, l_.str.4@PAGEOFF
LBB0_16:
	mov	x0, x21
	bl	_dev_err
LBB0_17:
	mov	x0, x24
	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
LBB0_18:
	mov	x0, x20
	mov	x1, x19
	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
	br	x2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_5-LBB0_2)>>2
	.byte	(LBB0_6-LBB0_2)>>2
	.byte	(LBB0_7-LBB0_2)>>2
                                        ; -- End function
	.comm	_BLK_IDX_MAC_CONFIG,8,3         ; @BLK_IDX_MAC_CONFIG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Configuring port %d RGMII at speed %dMbps\n"

l_.str.1:                               ; @.str.1
	.asciz	"Speed not available, skipping CGU config\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.2:                               ; @.str.2
	.asciz	"Failed to configure idiv\n"

l_.str.3:                               ; @.str.3
	.asciz	"Failed to configure RGMII Tx clock\n"

l_.str.4:                               ; @.str.4
	.asciz	"Failed to configure Tx pad registers\n"

	.comm	_XMII_MAC,8,3                   ; @XMII_MAC
	.no_dead_strip	_sja1105_rgmii_clocking_setup
.subsections_via_symbols
