	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function usb_get_dr_mode
_usb_get_dr_mode:                       ## @usb_get_dr_mode
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movl	%edi, %r14d
	leaq	-24(%rbp), %rax
	movl	%esi, %edi
	movq	%rdx, %rsi
	movq	%rax, %rdx
	callq	_OF_getprop_alloc
	movq	_USB_DR_MODE_UNKNOWN@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	testl	%eax, %eax
	jle	LBB0_10
## %bb.1:
	movq	-24(%rbp), %rdi
	leaq	L_.str(%rip), %rsi
	callq	_strcmp
	testq	%rax, %rax
	je	LBB0_5
## %bb.2:
	movq	-24(%rbp), %rdi
	leaq	L_.str.1(%rip), %rsi
	callq	_strcmp
	testq	%rax, %rax
	je	LBB0_6
## %bb.3:
	movq	-24(%rbp), %rdi
	leaq	L_.str.2(%rip), %rsi
	callq	_strcmp
	testq	%rax, %rax
	je	LBB0_7
## %bb.4:
	movq	-24(%rbp), %rdx
	leaq	L_.str.3(%rip), %rsi
	movl	%r14d, %edi
	callq	_device_printf
	jmp	LBB0_9
LBB0_5:
	movq	_USB_DR_MODE_DEVICE@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_6:
	movq	_USB_DR_MODE_HOST@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_7:
	movq	_USB_DR_MODE_OTG@GOTPCREL(%rip), %rax
LBB0_8:
	movl	(%rax), %ebx
LBB0_9:
	movq	-24(%rbp), %rdi
	callq	_OF_prop_free
LBB0_10:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_USB_DR_MODE_UNKNOWN,4,2        ## @USB_DR_MODE_UNKNOWN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"device"

	.comm	_USB_DR_MODE_DEVICE,4,2         ## @USB_DR_MODE_DEVICE
L_.str.1:                               ## @.str.1
	.asciz	"host"

	.comm	_USB_DR_MODE_HOST,4,2           ## @USB_DR_MODE_HOST
L_.str.2:                               ## @.str.2
	.asciz	"otg"

	.comm	_USB_DR_MODE_OTG,4,2            ## @USB_DR_MODE_OTG
L_.str.3:                               ## @.str.3
	.asciz	"Unknown dr mode: %s\n"

	.no_dead_strip	_usb_get_dr_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function usb_get_dr_mode
_usb_get_dr_mode:                       ; @usb_get_dr_mode
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x8, x2
	mov	x20, x0
	add	x2, sp, #8
	mov	x0, x1
	mov	x1, x8
	bl	_OF_getprop_alloc
Lloh0:
	adrp	x8, _USB_DR_MODE_UNKNOWN@GOTPAGE
Lloh1:
	ldr	x8, [x8, _USB_DR_MODE_UNKNOWN@GOTPAGEOFF]
Lloh2:
	ldr	w19, [x8]
	cmp	w0, #1
	b.lt	LBB0_10
; %bb.1:
	ldr	x0, [sp, #8]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_strcmp
	cbz	x0, LBB0_5
; %bb.2:
	ldr	x0, [sp, #8]
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_strcmp
	cbz	x0, LBB0_6
; %bb.3:
	ldr	x0, [sp, #8]
Lloh7:
	adrp	x1, l_.str.2@PAGE
Lloh8:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_strcmp
	cbz	x0, LBB0_7
; %bb.4:
	ldr	x2, [sp, #8]
Lloh9:
	adrp	x1, l_.str.3@PAGE
Lloh10:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x20
	bl	_device_printf
	b	LBB0_9
LBB0_5:
Lloh11:
	adrp	x8, _USB_DR_MODE_DEVICE@GOTPAGE
Lloh12:
	ldr	x8, [x8, _USB_DR_MODE_DEVICE@GOTPAGEOFF]
	b	LBB0_8
LBB0_6:
Lloh13:
	adrp	x8, _USB_DR_MODE_HOST@GOTPAGE
Lloh14:
	ldr	x8, [x8, _USB_DR_MODE_HOST@GOTPAGEOFF]
	b	LBB0_8
LBB0_7:
Lloh15:
	adrp	x8, _USB_DR_MODE_OTG@GOTPAGE
Lloh16:
	ldr	x8, [x8, _USB_DR_MODE_OTG@GOTPAGEOFF]
LBB0_8:
	ldr	w19, [x8]
LBB0_9:
	ldr	x0, [sp, #8]
	bl	_OF_prop_free
LBB0_10:
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_USB_DR_MODE_UNKNOWN,4,2        ; @USB_DR_MODE_UNKNOWN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"device"

	.comm	_USB_DR_MODE_DEVICE,4,2         ; @USB_DR_MODE_DEVICE
l_.str.1:                               ; @.str.1
	.asciz	"host"

	.comm	_USB_DR_MODE_HOST,4,2           ; @USB_DR_MODE_HOST
l_.str.2:                               ; @.str.2
	.asciz	"otg"

	.comm	_USB_DR_MODE_OTG,4,2            ; @USB_DR_MODE_OTG
l_.str.3:                               ; @.str.3
	.asciz	"Unknown dr mode: %s\n"

	.no_dead_strip	_usb_get_dr_mode
.subsections_via_symbols
