	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cc770_probe_chip
_cc770_probe_chip:                      ## @cc770_probe_chip
	.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	%rdi, %r14
	callq	_netdev_priv
	movq	%rax, %rbx
	movq	_control@GOTPCREL(%rip), %r12
	movq	_CTRL_CCE@GOTPCREL(%rip), %rax
	movq	_CTRL_EAF@GOTPCREL(%rip), %r15
	movl	(%r15), %edx
	orl	(%rax), %edx
	movl	(%r12), %esi
	movq	_CTRL_INI@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_cc770_write_reg
	movq	_cpu_interface@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movl	(%rbx), %edx
	movq	%rbx, %rdi
	callq	_cc770_write_reg
	movl	(%r13), %esi
	movq	%rbx, %rdi
	callq	_cc770_read_reg
	movq	_CPUIF_RST@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_3
## %bb.1:
	movl	8(%rbx), %edx
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_2
LBB0_3:
	movq	_msgobj@GOTPCREL(%rip), %r13
	movq	(%r13), %rax
	movq	8(%rax), %rax
	movl	4(%rax), %esi
	movq	%rbx, %rdi
	movl	$37, %edx
	callq	_cc770_write_reg
	movq	(%r13), %rax
	movq	16(%rax), %rax
	movl	12(%rax), %esi
	movq	%rbx, %rdi
	movl	$82, %edx
	callq	_cc770_write_reg
	movq	(%r13), %rax
	movq	80(%rax), %rax
	movl	24(%rax), %esi
	movq	%rbx, %rdi
	movl	$195, %edx
	callq	_cc770_write_reg
	movq	(%r13), %rax
	movq	8(%rax), %rax
	movl	4(%rax), %esi
	movq	%rbx, %rdi
	callq	_cc770_read_reg
	cmpl	$37, %eax
	jne	LBB0_6
## %bb.4:
	movq	(%r13), %rax
	movq	16(%rax), %rax
	movl	12(%rax), %esi
	movq	%rbx, %rdi
	callq	_cc770_read_reg
	cmpl	$82, %eax
	jne	LBB0_6
## %bb.5:
	movq	(%r13), %rax
	movq	80(%rax), %rax
	movl	24(%rax), %esi
	movq	%rbx, %rdi
	callq	_cc770_read_reg
	cmpl	$195, %eax
	jne	LBB0_6
## %bb.7:
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_cc770_read_reg
	movl	%eax, %ecx
	movl	(%r15), %edx
	xorl	%eax, %eax
	testl	%ecx, %edx
	je	LBB0_9
## %bb.8:
	orl	%edx, 4(%rbx)
	jmp	LBB0_9
LBB0_6:
	movl	8(%rbx), %edx
	leaq	L_.str.1(%rip), %rsi
LBB0_2:
	movq	%r14, %rdi
	callq	_netdev_info
	movq	_ENODEV@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_control,4,2                    ## @control
	.comm	_CTRL_CCE,4,2                   ## @CTRL_CCE
	.comm	_CTRL_EAF,4,2                   ## @CTRL_EAF
	.comm	_CTRL_INI,4,2                   ## @CTRL_INI
	.comm	_cpu_interface,4,2              ## @cpu_interface
	.comm	_CPUIF_RST,4,2                  ## @CPUIF_RST
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"probing @0x%p failed (reset)\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_msgobj,8,3                     ## @msgobj
L_.str.1:                               ## @.str.1
	.asciz	"probing @0x%p failed (pattern)\n"

	.no_dead_strip	_cc770_probe_chip
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cc770_probe_chip
_cc770_probe_chip:                      ; @cc770_probe_chip
	.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, x0
	bl	_netdev_priv
	mov	x19, x0
Lloh0:
	adrp	x22, _control@GOTPAGE
Lloh1:
	ldr	x22, [x22, _control@GOTPAGEOFF]
	ldr	w1, [x22]
Lloh2:
	adrp	x8, _CTRL_CCE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _CTRL_CCE@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x21, _CTRL_EAF@GOTPAGE
Lloh6:
	ldr	x21, [x21, _CTRL_EAF@GOTPAGEOFF]
	ldr	w9, [x21]
	orr	w8, w9, w8
Lloh7:
	adrp	x9, _CTRL_INI@GOTPAGE
Lloh8:
	ldr	x9, [x9, _CTRL_INI@GOTPAGEOFF]
Lloh9:
	ldr	w9, [x9]
	orr	w2, w8, w9
	bl	_cc770_write_reg
Lloh10:
	adrp	x23, _cpu_interface@GOTPAGE
Lloh11:
	ldr	x23, [x23, _cpu_interface@GOTPAGEOFF]
	ldr	w1, [x23]
	ldr	w2, [x19]
	mov	x0, x19
	bl	_cc770_write_reg
	ldr	w1, [x23]
	mov	x0, x19
	bl	_cc770_read_reg
Lloh12:
	adrp	x8, _CPUIF_RST@GOTPAGE
Lloh13:
	ldr	x8, [x8, _CPUIF_RST@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_2
; %bb.1:
	ldr	w2, [x19, #8]
Lloh15:
	adrp	x1, l_.str@PAGE
Lloh16:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_8
LBB0_2:
Lloh17:
	adrp	x23, _msgobj@GOTPAGE
Lloh18:
	ldr	x23, [x23, _msgobj@GOTPAGEOFF]
	ldr	x8, [x23]
	ldr	x8, [x8, #8]
	ldr	w1, [x8, #4]
	mov	x0, x19
	mov	w2, #37
	bl	_cc770_write_reg
	ldr	x8, [x23]
	ldr	x8, [x8, #16]
	ldr	w1, [x8, #12]
	mov	x0, x19
	mov	w2, #82
	bl	_cc770_write_reg
	ldr	x8, [x23]
	ldr	x8, [x8, #80]
	ldr	w1, [x8, #24]
	mov	x0, x19
	mov	w2, #195
	bl	_cc770_write_reg
	ldr	x8, [x23]
	ldr	x8, [x8, #8]
	ldr	w1, [x8, #4]
	mov	x0, x19
	bl	_cc770_read_reg
	cmp	w0, #37
	b.ne	LBB0_7
; %bb.3:
	ldr	x8, [x23]
	ldr	x8, [x8, #16]
	ldr	w1, [x8, #12]
	mov	x0, x19
	bl	_cc770_read_reg
	cmp	w0, #82
	b.ne	LBB0_7
; %bb.4:
	ldr	x8, [x23]
	ldr	x8, [x8, #80]
	ldr	w1, [x8, #24]
	mov	x0, x19
	bl	_cc770_read_reg
	cmp	w0, #195
	b.ne	LBB0_7
; %bb.5:
	ldr	w1, [x22]
	mov	x0, x19
	bl	_cc770_read_reg
	ldr	w8, [x21]
	tst	w8, w0
	b.eq	LBB0_10
; %bb.6:
	mov	w0, #0
	ldr	w9, [x19, #4]
	orr	w8, w9, w8
	str	w8, [x19, #4]
	b	LBB0_9
LBB0_7:
	ldr	w2, [x19, #8]
Lloh19:
	adrp	x1, l_.str.1@PAGE
Lloh20:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_8:
	mov	x0, x20
	bl	_netdev_info
Lloh21:
	adrp	x8, _ENODEV@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_9:
	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
LBB0_10:
	mov	w0, #0
	b	LBB0_9
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_control,4,2                    ; @control
	.comm	_CTRL_CCE,4,2                   ; @CTRL_CCE
	.comm	_CTRL_EAF,4,2                   ; @CTRL_EAF
	.comm	_CTRL_INI,4,2                   ; @CTRL_INI
	.comm	_cpu_interface,4,2              ; @cpu_interface
	.comm	_CPUIF_RST,4,2                  ; @CPUIF_RST
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"probing @0x%p failed (reset)\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_msgobj,8,3                     ; @msgobj
l_.str.1:                               ; @.str.1
	.asciz	"probing @0x%p failed (pattern)\n"

	.no_dead_strip	_cc770_probe_chip
.subsections_via_symbols
