	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function usb_mmap
_usb_mmap:                              ## @usb_mmap
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	8(%rdi), %r14
	movl	(%rdi), %edi
	movq	_MON_IOCQ_RING_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_ioctl
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movl	%eax, (%r14)
	movq	_PROT_READ@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	_MAP_SHARED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	(%rbx), %r8d
	xorl	%edi, %edi
	movl	%eax, %esi
	xorl	%r9d, %r9d
	callq	_mmap
	movq	%rax, %rcx
	movq	%rax, 8(%r14)
	movq	_MAP_FAILED@GOTPCREL(%rip), %rdx
	xorl	%eax, %eax
	cmpq	(%rdx), %rcx
	setne	%al
	jmp	LBB0_3
LBB0_1:
	xorl	%eax, %eax
LBB0_3:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MON_IOCQ_RING_SIZE,4,2         ## @MON_IOCQ_RING_SIZE
	.comm	_PROT_READ,4,2                  ## @PROT_READ
	.comm	_MAP_SHARED,4,2                 ## @MAP_SHARED
	.comm	_MAP_FAILED,8,3                 ## @MAP_FAILED
	.no_dead_strip	_usb_mmap
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function usb_mmap
_usb_mmap:                              ; @usb_mmap
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	ldr	x20, [x0, #8]
	ldr	w0, [x0]
Lloh0:
	adrp	x8, _MON_IOCQ_RING_SIZE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MON_IOCQ_RING_SIZE@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_ioctl
	tbnz	w0, #31, LBB0_2
; %bb.1:
	mov	x1, x0
Lloh3:
	adrp	x8, _PROT_READ@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PROT_READ@GOTPAGEOFF]
	str	w0, [x20]
Lloh5:
	ldr	w2, [x8]
Lloh6:
	adrp	x8, _MAP_SHARED@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MAP_SHARED@GOTPAGEOFF]
Lloh8:
	ldr	w3, [x8]
	ldr	w4, [x19]
	mov	w0, #0
	mov	w5, #0
	bl	_mmap
	str	x0, [x20, #8]
Lloh9:
	adrp	x8, _MAP_FAILED@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MAP_FAILED@GOTPAGEOFF]
Lloh11:
	ldr	x8, [x8]
	cmp	x0, x8
	cset	w0, ne
	b	LBB0_3
LBB0_2:
	mov	w0, #0
LBB0_3:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_MON_IOCQ_RING_SIZE,4,2         ; @MON_IOCQ_RING_SIZE
	.comm	_PROT_READ,4,2                  ; @PROT_READ
	.comm	_MAP_SHARED,4,2                 ; @MAP_SHARED
	.comm	_MAP_FAILED,8,3                 ; @MAP_FAILED
	.no_dead_strip	_usb_mmap
.subsections_via_symbols
