	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cx231xx_send_vendor_cmd        ## -- Begin function cx231xx_send_vendor_cmd
	.p2align	4, 0x90
_cx231xx_send_vendor_cmd:               ## @cx231xx_send_vendor_cmd
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_DEV_DISCONNECTED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rdi)
	je	LBB0_3
## %bb.1:
	movq	_ENODEV@GOTPCREL(%rip), %rcx
	jmp	LBB0_2
LBB0_3:
	movq	%rsi, %r12
	movl	(%rsi), %eax
	movq	_URB_MAX_CTRL_SIZE@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jle	LBB0_5
## %bb.4:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
LBB0_2:
	xorl	%eax, %eax
	subl	(%rcx), %eax
	addq	$8, %rsp
LBB0_15:
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	%rdi, %r15
	cmpl	$0, 4(%r12)
	movl	4(%rdi), %edi
	je	LBB0_7
## %bb.6:
	xorl	%esi, %esi
	callq	_usb_rcvctrlpipe
	jmp	LBB0_8
LBB0_7:
	xorl	%esi, %esi
	callq	_usb_sndctrlpipe
LBB0_8:
	movl	%eax, %esi
	movl	(%r12), %r13d
	movl	8(%r12), %edx
	cmpl	$5, %r13d
	jl	LBB0_16
## %bb.9:
	cmpl	$6, %edx
	ja	LBB0_16
## %bb.10:
	movl	$116, %eax
	btl	%edx, %eax
	jae	LBB0_16
## %bb.11:
	movq	16(%r12), %rbx
	movl	$65465, %r8d                    ## imm = 0xFFB9
	andl	12(%r12), %r8d
	orl	$2, %r8d
	movl	%r8d, 12(%r12)
	movq	_USB_TYPE_VENDOR@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	orl	4(%r12), %ecx
	movq	_USB_RECIP_DEVICE@GOTPCREL(%rip), %rax
	orl	(%rax), %ecx
	movl	24(%r12), %r9d
	movq	_HZ@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	subq	$8, %rsp
	movq	%r15, %rdi
	movl	%esi, %r14d
	pushq	%rax
	pushq	$4
	pushq	%rbx
	callq	___usb_control_msg
	addq	$32, %rsp
	movzwl	12(%r12), %r8d
	orl	$66, %r8d
	movl	%r8d, 12(%r12)
	cmpl	$9, %r13d
	jb	LBB0_13
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movq	_USB_TYPE_VENDOR@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	orl	4(%r12), %ecx
	movq	_USB_RECIP_DEVICE@GOTPCREL(%rip), %rax
	orl	(%rax), %ecx
	addq	$16, %rbx
	movl	8(%r12), %edx
	movl	24(%r12), %r9d
	movq	_HZ@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	subq	$8, %rsp
	movq	%r15, %rdi
	movl	%r14d, %esi
	pushq	%rax
	pushq	$4
	pushq	%rbx
	callq	___usb_control_msg
	addq	$32, %rsp
	movl	12(%r12), %r8d
	addl	$-4, %r13d
	cmpl	$8, %r13d
	jg	LBB0_12
LBB0_13:
	addl	$-4, %r13d
	movq	_USB_TYPE_VENDOR@GOTPCREL(%rip), %rax
	movq	_USB_RECIP_DEVICE@GOTPCREL(%rip), %rdx
	movq	_HZ@GOTPCREL(%rip), %rdi
	andl	$65469, %r8d                    ## imm = 0xFFBD
	orl	$64, %r8d
	movl	%r8d, 12(%r12)
	movl	(%rax), %ecx
	orl	4(%r12), %ecx
	orl	(%rdx), %ecx
	addq	$16, %rbx
	movl	8(%r12), %edx
	movl	24(%r12), %r9d
	movl	(%rdi), %eax
	subq	$8, %rsp
	movq	%r15, %rdi
	movl	%r14d, %esi
	pushq	%rax
	pushq	%r13
	pushq	%rbx
	jmp	LBB0_14
LBB0_16:
	movq	_USB_TYPE_VENDOR@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	orl	4(%r12), %ecx
	movq	_USB_RECIP_DEVICE@GOTPCREL(%rip), %rax
	orl	(%rax), %ecx
	movl	12(%r12), %r8d
	movl	24(%r12), %r9d
	movq	_HZ@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	subq	$8, %rsp
	movq	%r15, %rdi
	pushq	%rax
	pushq	%r13
	pushq	16(%r12)
LBB0_14:
	callq	___usb_control_msg
	addq	$40, %rsp
	jmp	LBB0_15
	.cfi_endproc
                                        ## -- End function
	.comm	_DEV_DISCONNECTED,4,2           ## @DEV_DISCONNECTED
	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_URB_MAX_CTRL_SIZE,4,2          ## @URB_MAX_CTRL_SIZE
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_USB_TYPE_VENDOR,4,2            ## @USB_TYPE_VENDOR
	.comm	_USB_RECIP_DEVICE,4,2           ## @USB_RECIP_DEVICE
	.comm	_HZ,4,2                         ## @HZ
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cx231xx_send_vendor_cmd        ; -- Begin function cx231xx_send_vendor_cmd
	.p2align	2
_cx231xx_send_vendor_cmd:               ; @cx231xx_send_vendor_cmd
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	ldr	w8, [x0]
Lloh0:
	adrp	x9, _DEV_DISCONNECTED@GOTPAGE
Lloh1:
	ldr	x9, [x9, _DEV_DISCONNECTED@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _ENODEV@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:
	mov	x20, x1
	ldr	w8, [x1]
Lloh5:
	adrp	x9, _URB_MAX_CTRL_SIZE@GOTPAGE
Lloh6:
	ldr	x9, [x9, _URB_MAX_CTRL_SIZE@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	cmp	w8, w9
	b.le	LBB0_6
; %bb.3:
Lloh8:
	adrp	x8, _EINVAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_4:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_5:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_6:
	mov	x19, x0
	ldr	w8, [x20, #4]
	ldr	w0, [x0, #4]
	mov	w1, #0
	cbz	w8, LBB0_8
; %bb.7:
	bl	_usb_rcvctrlpipe
	b	LBB0_9
LBB0_8:
	bl	_usb_sndctrlpipe
LBB0_9:
	mov	x21, x0
	ldr	w22, [x20]
	ldr	w2, [x20, #8]
	cmp	w22, #5
	b.lt	LBB0_15
; %bb.10:
	cmp	w2, #6
	b.hi	LBB0_15
; %bb.11:
	mov	w8, #1
	lsl	w8, w8, w2
	mov	w9, #116
	tst	w8, w9
	b.eq	LBB0_15
; %bb.12:
	ldr	x23, [x20, #16]
	ldr	w8, [x20, #12]
	mov	w9, #65465
	and	w8, w8, w9
	orr	w4, w8, #0x2
	str	w4, [x20, #12]
	ldr	w8, [x20, #4]
Lloh10:
	adrp	x24, _USB_TYPE_VENDOR@GOTPAGE
Lloh11:
	ldr	x24, [x24, _USB_TYPE_VENDOR@GOTPAGEOFF]
	ldr	w9, [x24]
	orr	w8, w9, w8
Lloh12:
	adrp	x25, _USB_RECIP_DEVICE@GOTPAGE
Lloh13:
	ldr	x25, [x25, _USB_RECIP_DEVICE@GOTPAGEOFF]
	ldr	w9, [x25]
	orr	w3, w8, w9
	ldr	w5, [x20, #24]
Lloh14:
	adrp	x26, _HZ@GOTPAGE
Lloh15:
	ldr	x26, [x26, _HZ@GOTPAGEOFF]
	ldr	w8, [x26]
	str	w8, [sp]
	mov	x0, x19
	mov	x1, x21
	mov	x6, x23
	mov	w7, #4
	bl	___usb_control_msg
	ldr	w8, [x20, #12]
	and	w8, w8, #0xffff
	mov	w9, #66
	orr	w4, w8, w9
	str	w4, [x20, #12]
	cmp	w22, #9
	b.lo	LBB0_14
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	add	x23, x23, #16
	ldp	w8, w2, [x20, #4]
	ldr	w9, [x24]
	orr	w8, w9, w8
	ldr	w9, [x25]
	orr	w3, w8, w9
	ldr	w5, [x20, #24]
	ldr	w8, [x26]
	str	w8, [sp]
	mov	x0, x19
	mov	x1, x21
	mov	x6, x23
	mov	w7, #4
	bl	___usb_control_msg
	ldr	w4, [x20, #12]
	sub	w22, w22, #4
	cmp	w22, #8
	b.gt	LBB0_13
LBB0_14:
	sub	w7, w22, #4
	mov	w8, #65469
	and	w8, w4, w8
	orr	w4, w8, #0x40
	str	w4, [x20, #12]
	add	x6, x23, #16
	ldp	w8, w2, [x20, #4]
	ldr	w9, [x24]
	orr	w8, w9, w8
	ldr	w9, [x25]
	orr	w3, w8, w9
	ldr	w5, [x20, #24]
	ldr	w8, [x26]
	str	w8, [sp]
	mov	x0, x19
	mov	x1, x21
	b	LBB0_16
LBB0_15:
	ldr	w8, [x20, #4]
Lloh16:
	adrp	x9, _USB_TYPE_VENDOR@GOTPAGE
Lloh17:
	ldr	x9, [x9, _USB_TYPE_VENDOR@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh19:
	adrp	x9, _USB_RECIP_DEVICE@GOTPAGE
Lloh20:
	ldr	x9, [x9, _USB_RECIP_DEVICE@GOTPAGEOFF]
Lloh21:
	ldr	w9, [x9]
	orr	w3, w8, w9
	ldr	w4, [x20, #12]
	ldr	w5, [x20, #24]
	ldr	x6, [x20, #16]
Lloh22:
	adrp	x8, _HZ@GOTPAGE
Lloh23:
	ldr	x8, [x8, _HZ@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	str	w8, [sp]
	mov	x0, x19
	mov	x1, x21
	mov	x7, x22
LBB0_16:
	bl	___usb_control_msg
	b	LBB0_5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_DEV_DISCONNECTED,4,2           ; @DEV_DISCONNECTED
	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_URB_MAX_CTRL_SIZE,4,2          ; @URB_MAX_CTRL_SIZE
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_USB_TYPE_VENDOR,4,2            ; @USB_TYPE_VENDOR
	.comm	_USB_RECIP_DEVICE,4,2           ; @USB_RECIP_DEVICE
	.comm	_HZ,4,2                         ; @HZ
.subsections_via_symbols
