	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function __zd_usb_enable_rx
___zd_usb_enable_rx:                    ## @__zd_usb_enable_rx
	.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
	movq	%rdi, %r12
	callq	_zd_usb_dev
	leaq	L_.str(%rip), %rsi
	movl	%eax, %edi
	callq	_dev_dbg_f
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
	movq	_RX_URBS_COUNT@GOTPCREL(%rip), %r13
	movl	(%r13), %edi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	$8, %esi
	callq	_kcalloc
	testq	%rax, %rax
	je	LBB0_10
## %bb.1:
	movq	%rax, %r15
	cmpl	$0, (%r13)
	jle	LBB0_5
## %bb.2:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r12, %rdi
	callq	_alloc_rx_urb
	movq	%rax, (%r15,%rbx,8)
	testq	%rax, %rax
	je	LBB0_7
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	incq	%rbx
	movslq	(%r13), %rax
	cmpq	%rax, %rbx
	jl	LBB0_3
LBB0_5:
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_irqs_disabled
	xorl	%edi, %edi
	testl	%eax, %eax
	sete	%dil
	callq	_ZD_ASSERT
	leaq	4(%r12), %rbx
	movq	%rbx, %rdi
	callq	_spin_lock_irq
	cmpq	$0, 8(%r12)
	je	LBB0_11
LBB0_6:
	movq	%rbx, %rdi
	callq	_spin_unlock_irq
LBB0_7:
	cmpl	$0, (%r13)
	jle	LBB0_10
## %bb.8:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r15,%rbx,8), %rdi
	callq	_free_rx_urb
	incq	%rbx
	movslq	(%r13), %rax
	cmpq	%rax, %rbx
	jl	LBB0_9
	jmp	LBB0_10
LBB0_11:
	movq	%r15, 8(%r12)
	movl	(%r13), %eax
	movl	%eax, (%r12)
	movq	%rbx, %rdi
	callq	_spin_unlock_irq
	cmpl	$0, (%r13)
	jle	LBB0_16
## %bb.12:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	xorl	%r12d, %r12d
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rbx
	.p2align	4, 0x90
LBB0_13:                                ## =>This Inner Loop Header: Depth=1
	movq	(%r15,%r12,8), %rdi
	movl	(%rbx), %esi
	callq	_usb_submit_urb
	testl	%eax, %eax
	jne	LBB0_17
## %bb.14:                              ##   in Loop: Header=BB0_13 Depth=1
	incq	%r12
	movslq	(%r13), %rax
	cmpq	%rax, %r12
	jl	LBB0_13
LBB0_16:
	xorl	%r14d, %r14d
LBB0_10:
	movl	%r14d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_17:
	movl	%eax, %r14d
	cmpl	$0, (%r13)
	jle	LBB0_20
## %bb.18:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movq	(%r15,%rbx,8), %rdi
	callq	_usb_kill_urb
	incq	%rbx
	movslq	(%r13), %rax
	cmpq	%rax, %rbx
	jl	LBB0_19
LBB0_20:
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	callq	_spin_lock_irq
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	$0, 8(%rax)
	movl	$0, (%rax)
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_RX_URBS_COUNT,4,2              ## @RX_URBS_COUNT
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.no_dead_strip	___zd_usb_enable_rx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function __zd_usb_enable_rx
___zd_usb_enable_rx:                    ; @__zd_usb_enable_rx
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x0
	bl	_zd_usb_dev
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_dbg_f
Lloh2:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w21, w8
Lloh5:
	adrp	x23, _RX_URBS_COUNT@GOTPAGE
Lloh6:
	ldr	x23, [x23, _RX_URBS_COUNT@GOTPAGEOFF]
	ldr	w0, [x23]
Lloh7:
	adrp	x24, _GFP_KERNEL@GOTPAGE
Lloh8:
	ldr	x24, [x24, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w2, [x24]
	mov	w1, #8
	bl	_kcalloc
	cbz	x0, LBB0_16
; %bb.1:
	mov	x19, x0
	ldr	w8, [x23]
	cmp	w8, #1
	b.lt	LBB0_5
; %bb.2:
	mov	x22, #0
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	bl	_alloc_rx_urb
	str	x0, [x19, x22, lsl #3]
	cbz	x0, LBB0_8
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x22, x22, #1
	ldrsw	x8, [x23]
	cmp	x22, x8
	b.lt	LBB0_3
LBB0_5:
	bl	_irqs_disabled
	cmp	w0, #0
	cset	w0, eq
	bl	_ZD_ASSERT
	add	x22, x20, #4
	mov	x0, x22
	bl	_spin_lock_irq
	ldr	x8, [x20, #8]
	cbz	x8, LBB0_11
; %bb.6:
	mov	w21, #0
LBB0_7:
	mov	x0, x22
	bl	_spin_unlock_irq
LBB0_8:
	ldr	w8, [x23]
	cmp	w8, #1
	b.lt	LBB0_16
; %bb.9:
	mov	x20, #0
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x19, x20, lsl #3]
	bl	_free_rx_urb
	add	x20, x20, #1
	ldrsw	x8, [x23]
	cmp	x20, x8
	b.lt	LBB0_10
	b	LBB0_16
LBB0_11:
	str	x19, [x20, #8]
	ldr	w8, [x23]
	str	w8, [x20]
	mov	x0, x22
	bl	_spin_unlock_irq
	ldr	w8, [x23]
	cmp	w8, #1
	b.lt	LBB0_15
; %bb.12:
	mov	x25, #0
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x19, x25, lsl #3]
	ldr	w1, [x24]
	bl	_usb_submit_urb
	cbnz	w0, LBB0_17
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	add	x25, x25, #1
	ldrsw	x8, [x23]
	cmp	x25, x8
	b.lt	LBB0_13
LBB0_15:
	mov	w21, #0
LBB0_16:
	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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_17:
	mov	x21, x0
	ldr	w8, [x23]
	cmp	w8, #1
	b.lt	LBB0_20
; %bb.18:
	mov	x24, #0
LBB0_19:                                ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x19, x24, lsl #3]
	bl	_usb_kill_urb
	add	x24, x24, #1
	ldrsw	x8, [x23]
	cmp	x24, x8
	b.lt	LBB0_19
LBB0_20:
	mov	x0, x22
	bl	_spin_lock_irq
	str	xzr, [x20, #8]
	str	wzr, [x20]
	b	LBB0_7
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_RX_URBS_COUNT,4,2              ; @RX_URBS_COUNT
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.no_dead_strip	___zd_usb_enable_rx
.subsections_via_symbols
