	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mt7601u_probe
_mt7601u_probe:                         ## @mt7601u_probe
	.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	%rdi, %r14
	callq	_interface_to_usbdev
	movq	%rax, %rbx
	movq	%r14, %rdi
	callq	_mt7601u_alloc_device
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r15
	movq	%rbx, %rdi
	callq	_usb_get_dev
	movq	%rax, %rdi
	callq	_usb_reset_device
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_usb_set_intfdata
	movl	12(%r15), %edi
	movq	_MT_VEND_BUF@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_devm_kmalloc
	movl	%eax, 16(%r15)
	testl	%eax, %eax
	je	LBB0_3
## %bb.5:
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_mt7601u_assign_pipes
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.6:
	movq	%r15, %rdi
	callq	_mt7601u_wait_asic_ready
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.7:
	movq	_MT_ASIC_VERSION@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_mt7601u_rr
	movl	%eax, %ebx
	movq	_MT_MAC_CSR0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_mt7601u_rr
	movl	12(%r15), %edi
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edx
	movl	%eax, %ecx
	callq	_dev_info
	andl	$-65536, %ebx                   ## imm = 0xFFFF0000
	cmpl	$1979777024, %ebx               ## imm = 0x76010000
	jne	LBB0_8
## %bb.9:
	movq	_MT_EFUSE_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_mt7601u_rr
	movq	_MT_EFUSE_CTRL_SEL@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_11
## %bb.10:
	movl	12(%r15), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_dev_warn
LBB0_11:
	movq	%r15, %rdi
	callq	_mt7601u_init_hardware
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.12:
	movq	%r15, %rdi
	callq	_mt7601u_register_device
	testl	%eax, %eax
	je	LBB0_13
## %bb.14:
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_mt7601u_cleanup
	jmp	LBB0_15
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_16
LBB0_3:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_4:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_15:
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_usb_set_intfdata
	movq	%r14, %rdi
	callq	_interface_to_usbdev
	movq	%rax, %rdi
	callq	_usb_put_dev
	movl	4(%r15), %edi
	callq	_destroy_workqueue
	movl	(%r15), %edi
	callq	_ieee80211_free_hw
LBB0_16:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_13:
	movq	_MT7601U_STATE_INITIALIZED@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	addq	$8, %r15
	movq	%r15, %rsi
	callq	_set_bit
	xorl	%ebx, %ebx
	jmp	LBB0_16
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_MT_VEND_BUF,4,2                ## @MT_VEND_BUF
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_MT_ASIC_VERSION,4,2            ## @MT_ASIC_VERSION
	.comm	_MT_MAC_CSR0,4,2                ## @MT_MAC_CSR0
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ASIC revision: %08x MAC revision: %08x\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_MT_EFUSE_CTRL,4,2              ## @MT_EFUSE_CTRL
	.comm	_MT_EFUSE_CTRL_SEL,4,2          ## @MT_EFUSE_CTRL_SEL
L_.str.1:                               ## @.str.1
	.asciz	"Warning: eFUSE not present\n"

	.comm	_MT7601U_STATE_INITIALIZED,4,2  ## @MT7601U_STATE_INITIALIZED
	.no_dead_strip	_mt7601u_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mt7601u_probe
_mt7601u_probe:                         ; @mt7601u_probe
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x20, x0
	bl	_interface_to_usbdev
	mov	x21, x0
	mov	x0, x20
	bl	_mt7601u_alloc_device
	cbz	x0, LBB0_10
; %bb.1:
	mov	x19, x0
	mov	x0, x21
	bl	_usb_get_dev
	bl	_usb_reset_device
	mov	x0, x20
	mov	x1, x19
	bl	_usb_set_intfdata
	ldr	w0, [x19, #12]
Lloh0:
	adrp	x8, _MT_VEND_BUF@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MT_VEND_BUF@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	bl	_devm_kmalloc
	str	w0, [x19, #16]
	cbz	w0, LBB0_11
; %bb.2:
	mov	x0, x20
	mov	x1, x19
	bl	_mt7601u_assign_pipes
	mov	x21, x0
	cbnz	w0, LBB0_13
; %bb.3:
	mov	x0, x19
	bl	_mt7601u_wait_asic_ready
	mov	x21, x0
	cbnz	w0, LBB0_13
; %bb.4:
Lloh6:
	adrp	x8, _MT_ASIC_VERSION@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MT_ASIC_VERSION@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_mt7601u_rr
	mov	x21, x0
Lloh9:
	adrp	x8, _MT_MAC_CSR0@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MT_MAC_CSR0@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_mt7601u_rr
	mov	x3, x0
	ldr	w0, [x19, #12]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x21
	bl	_dev_info
	mov	w8, #30209
	cmp	w8, w21, lsr #16
	b.ne	LBB0_15
; %bb.5:
Lloh14:
	adrp	x8, _MT_EFUSE_CTRL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _MT_EFUSE_CTRL@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_mt7601u_rr
Lloh17:
	adrp	x8, _MT_EFUSE_CTRL_SEL@GOTPAGE
Lloh18:
	ldr	x8, [x8, _MT_EFUSE_CTRL_SEL@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	tst	w8, w0
	b.ne	LBB0_7
; %bb.6:
	ldr	w0, [x19, #12]
Lloh20:
	adrp	x1, l_.str.1@PAGE
Lloh21:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_warn
LBB0_7:
	mov	x0, x19
	bl	_mt7601u_init_hardware
	mov	x21, x0
	cbnz	w0, LBB0_13
; %bb.8:
	mov	x0, x19
	bl	_mt7601u_register_device
	mov	x21, x0
	cbz	w0, LBB0_16
; %bb.9:
	mov	x0, x19
	bl	_mt7601u_cleanup
	b	LBB0_13
LBB0_10:
Lloh22:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh23:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_14
LBB0_11:
Lloh25:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh26:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_12:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_13:
	mov	x0, x20
	mov	x1, #0
	bl	_usb_set_intfdata
	mov	x0, x20
	bl	_interface_to_usbdev
	bl	_usb_put_dev
	ldr	w0, [x19, #4]
	bl	_destroy_workqueue
	ldr	w0, [x19]
	bl	_ieee80211_free_hw
LBB0_14:
	mov	x0, x21
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_15:
Lloh27:
	adrp	x8, _ENODEV@GOTPAGE
Lloh28:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
	b	LBB0_12
LBB0_16:
Lloh29:
	adrp	x8, _MT7601U_STATE_INITIALIZED@GOTPAGE
Lloh30:
	ldr	x8, [x8, _MT7601U_STATE_INITIALIZED@GOTPAGEOFF]
Lloh31:
	ldr	w0, [x8]
	add	x1, x19, #8
	bl	_set_bit
	b	LBB0_14
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_MT_VEND_BUF,4,2                ; @MT_VEND_BUF
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_MT_ASIC_VERSION,4,2            ; @MT_ASIC_VERSION
	.comm	_MT_MAC_CSR0,4,2                ; @MT_MAC_CSR0
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ASIC revision: %08x MAC revision: %08x\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_MT_EFUSE_CTRL,4,2              ; @MT_EFUSE_CTRL
	.comm	_MT_EFUSE_CTRL_SEL,4,2          ; @MT_EFUSE_CTRL_SEL
l_.str.1:                               ; @.str.1
	.asciz	"Warning: eFUSE not present\n"

	.comm	_MT7601U_STATE_INITIALIZED,4,2  ; @MT7601U_STATE_INITIALIZED
	.no_dead_strip	_mt7601u_probe
.subsections_via_symbols
