	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function carl9170_usb_alloc_rx_urb
_carl9170_usb_alloc_rx_urb:             ## @carl9170_usb_alloc_rx_urb
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	movq	%rdi, %r14
	movl	(%rdi), %edi
	callq	_kmalloc
	testq	%rax, %rax
	je	LBB0_5
## %bb.1:
	movq	%rax, %r15
	xorl	%edi, %edi
	movl	%ebx, %esi
	callq	_usb_alloc_urb
	testq	%rax, %rax
	je	LBB0_4
## %bb.2:
	movq	%rax, %rbx
	movl	4(%r14), %r12d
	movq	_AR9170_USB_EP_RX@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r12d, %edi
	callq	_usb_rcvbulkpipe
	movl	(%r14), %r8d
	movq	_carl9170_usb_rx_complete@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r9d
	movq	%r14, (%rsp)
	movq	%rbx, %rdi
	movl	%r12d, %esi
	movl	%eax, %edx
	movq	%r15, %rcx
	callq	_usb_fill_bulk_urb
	movq	_URB_FREE_BUFFER@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%rbx)
	jmp	LBB0_6
LBB0_4:
	movq	%r15, %rdi
	callq	_kfree
LBB0_5:
	xorl	%ebx, %ebx
LBB0_6:
	movq	%rbx, %rax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AR9170_USB_EP_RX,4,2           ## @AR9170_USB_EP_RX
	.comm	_carl9170_usb_rx_complete,4,2   ## @carl9170_usb_rx_complete
	.comm	_URB_FREE_BUFFER,4,2            ## @URB_FREE_BUFFER
	.no_dead_strip	_carl9170_usb_alloc_rx_urb
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function carl9170_usb_alloc_rx_urb
_carl9170_usb_alloc_rx_urb:             ; @carl9170_usb_alloc_rx_urb
	.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, x1
	mov	x19, x0
	ldr	w0, [x0]
	bl	_kmalloc
	cbz	x0, LBB0_3
; %bb.1:
	mov	x21, x0
	mov	w0, #0
	mov	x1, x20
	bl	_usb_alloc_urb
	mov	x20, x0
	cbz	x0, LBB0_4
; %bb.2:
	ldr	w22, [x19, #4]
Lloh0:
	adrp	x8, _AR9170_USB_EP_RX@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AR9170_USB_EP_RX@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x22
	bl	_usb_rcvbulkpipe
	mov	x2, x0
	ldr	w4, [x19]
Lloh3:
	adrp	x8, _carl9170_usb_rx_complete@GOTPAGE
Lloh4:
	ldr	x8, [x8, _carl9170_usb_rx_complete@GOTPAGEOFF]
Lloh5:
	ldr	w5, [x8]
	mov	x0, x20
	mov	x1, x22
	mov	x3, x21
	mov	x6, x19
	bl	_usb_fill_bulk_urb
Lloh6:
	adrp	x8, _URB_FREE_BUFFER@GOTPAGE
Lloh7:
	ldr	x8, [x8, _URB_FREE_BUFFER@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	ldr	w9, [x20]
	orr	w8, w9, w8
	str	w8, [x20]
	b	LBB0_5
LBB0_3:
	mov	x20, #0
	b	LBB0_5
LBB0_4:
	mov	x0, x21
	bl	_kfree
LBB0_5:
	mov	x0, x20
	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
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_AR9170_USB_EP_RX,4,2           ; @AR9170_USB_EP_RX
	.comm	_carl9170_usb_rx_complete,4,2   ; @carl9170_usb_rx_complete
	.comm	_URB_FREE_BUFFER,4,2            ; @URB_FREE_BUFFER
	.no_dead_strip	_carl9170_usb_alloc_rx_urb
.subsections_via_symbols
