	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function msi2500_isoc_init
_msi2500_isoc_init:                     ## @msi2500_isoc_init
	.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, %rbx
	movl	8(%rdi), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	$0, 16(%rbx)
	movl	12(%rbx), %edi
	xorl	%esi, %esi
	movl	$1, %edx
	callq	_usb_set_interface
	movl	%eax, %r15d
	testl	%eax, %eax
	je	LBB0_1
LBB0_17:
	movl	%r15d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	_MAX_ISO_BUFS@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	movl	$0, %r15d
	jle	LBB0_17
## %bb.2:
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movq	_ISO_FRAMES_PER_DESC@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	movq	_ISO_BUFFER_SIZE@GOTPCREL(%rip), %r12
	movq	_ISO_MAX_FRAME_SIZE@GOTPCREL(%rip), %r13
	xorl	%eax, %eax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_3 Depth=1
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	incq	%rdx
	movq	_MAX_ISO_BUFS@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	movq	%rdx, %rcx
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	cmpq	%rax, %rdx
	jge	LBB0_5
LBB0_3:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_11 Depth 2
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_usb_alloc_urb
	testq	%rax, %rax
	je	LBB0_4
## %bb.7:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	%rax, %rbx
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movq	(%r14), %rax
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movq	%rbx, (%rax,%rcx,8)
	movl	8(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdx
	xorl	%eax, %eax
	callq	_dev_dbg
	movl	$1, (%rbx)
	movl	12(%r14), %edi
	movl	%edi, 64(%rbx)
	movl	$129, %esi
	callq	_usb_rcvisocpipe
	movl	%eax, 60(%rbx)
	movq	_URB_NO_TRANSFER_DMA_MAP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_URB_ISO_ASAP@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	%eax, 4(%rbx)
	movl	12(%r14), %edi
	movl	(%r12), %esi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rcx
	addq	$56, %rcx
	callq	_usb_alloc_coherent
	movq	%rax, 48(%rbx)
	testq	%rax, %rax
	je	LBB0_8
## %bb.9:                               ##   in Loop: Header=BB0_3 Depth=1
	movl	(%r12), %eax
	movl	%eax, 44(%rbx)
	movq	_msi2500_isoc_handler@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 40(%rbx)
	movq	%r14, 32(%rbx)
	movq	$0, 24(%rbx)
	movl	(%r15), %edi
	movl	%edi, 8(%rbx)
	testl	%edi, %edi
	jle	LBB0_12
## %bb.10:                              ##   in Loop: Header=BB0_3 Depth=1
	movq	16(%rbx), %rax
	xorl	%ecx, %ecx
	.p2align	4, 0x90
LBB0_11:                                ##   Parent Loop BB0_3 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r13), %edx
	imull	%ecx, %edx
	movl	%edx, (%rax,%rcx,8)
	movl	(%r13), %edx
	movl	%edx, 4(%rax,%rcx,8)
	incq	%rcx
	movslq	(%r15), %rdi
	cmpq	%rdi, %rcx
	jl	LBB0_11
	jmp	LBB0_12
LBB0_4:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_msi2500_isoc_cleanup
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	jmp	LBB0_17
LBB0_8:
	movl	8(%r14), %edi
	leaq	L_.str.2(%rip), %rsi
	xorl	%r15d, %r15d
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
                                        ## kill: def $edx killed $edx killed $rdx
	xorl	%eax, %eax
	callq	_dev_err
	movq	%r14, %rdi
	callq	_msi2500_isoc_cleanup
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	subl	(%rax), %r15d
	jmp	LBB0_17
LBB0_5:
	testl	%eax, %eax
	jle	LBB0_6
## %bb.13:
	xorl	%ebx, %ebx
	leaq	L_.str.4(%rip), %r12
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r14
	movq	-56(%rbp), %r13                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_14:                                ## =>This Inner Loop Header: Depth=1
	movq	(%r13), %rax
	movq	(%rax,%rbx,8), %rdi
	movl	(%r14), %esi
	callq	_usb_submit_urb
	testl	%eax, %eax
	jne	LBB0_15
## %bb.16:                              ##   in Loop: Header=BB0_14 Depth=1
	movl	8(%r13), %edi
	movq	(%r13), %rax
	movq	(%rax,%rbx,8), %rdx
	xorl	%r15d, %r15d
	movq	%r12, %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	incq	%rbx
	movq	_MAX_ISO_BUFS@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	cmpq	%rax, %rbx
	jl	LBB0_14
	jmp	LBB0_17
LBB0_6:
	xorl	%r15d, %r15d
	jmp	LBB0_17
LBB0_15:
	movl	%eax, %r15d
	movl	8(%r13), %edi
	leaq	L_.str.3(%rip), %rsi
	movl	%ebx, %edx
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_dev_err
	movq	%r13, %rdi
	callq	_msi2500_isoc_cleanup
	jmp	LBB0_17
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"\n"

	.comm	_MAX_ISO_BUFS,4,2               ## @MAX_ISO_BUFS
	.comm	_ISO_FRAMES_PER_DESC,4,2        ## @ISO_FRAMES_PER_DESC
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.1:                               ## @.str.1
	.asciz	"Allocated URB at 0x%p\n"

	.comm	_URB_ISO_ASAP,4,2               ## @URB_ISO_ASAP
	.comm	_URB_NO_TRANSFER_DMA_MAP,4,2    ## @URB_NO_TRANSFER_DMA_MAP
	.comm	_ISO_BUFFER_SIZE,4,2            ## @ISO_BUFFER_SIZE
L_.str.2:                               ## @.str.2
	.asciz	"Failed to allocate urb buffer %d\n"

	.comm	_msi2500_isoc_handler,4,2       ## @msi2500_isoc_handler
	.comm	_ISO_MAX_FRAME_SIZE,4,2         ## @ISO_MAX_FRAME_SIZE
L_.str.3:                               ## @.str.3
	.asciz	"usb_submit_urb %d failed with error %d\n"

L_.str.4:                               ## @.str.4
	.asciz	"URB 0x%p submitted.\n"

	.no_dead_strip	_msi2500_isoc_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function msi2500_isoc_init
_msi2500_isoc_init:                     ; @msi2500_isoc_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
	ldr	w0, [x0, #8]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_dbg
	str	xzr, [x19, #16]
	ldr	w0, [x19, #12]
	mov	w1, #0
	mov	w2, #1
	bl	_usb_set_interface
	mov	x20, x0
	cbnz	w0, LBB0_16
; %bb.1:
Lloh2:
	adrp	x23, _MAX_ISO_BUFS@GOTPAGE
Lloh3:
	ldr	x23, [x23, _MAX_ISO_BUFS@GOTPAGEOFF]
	ldr	w8, [x23]
	cmp	w8, #1
	b.lt	LBB0_15
; %bb.2:
	mov	x20, #0
Lloh4:
	adrp	x25, _ISO_FRAMES_PER_DESC@GOTPAGE
Lloh5:
	ldr	x25, [x25, _ISO_FRAMES_PER_DESC@GOTPAGEOFF]
Lloh6:
	adrp	x24, _GFP_KERNEL@GOTPAGE
Lloh7:
	ldr	x24, [x24, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w0, [x25]
Lloh8:
	adrp	x27, _URB_ISO_ASAP@GOTPAGE
Lloh9:
	ldr	x27, [x27, _URB_ISO_ASAP@GOTPAGEOFF]
Lloh10:
	adrp	x28, _URB_NO_TRANSFER_DMA_MAP@GOTPAGE
Lloh11:
	ldr	x28, [x28, _URB_NO_TRANSFER_DMA_MAP@GOTPAGEOFF]
Lloh12:
	adrp	x26, _ISO_BUFFER_SIZE@GOTPAGE
Lloh13:
	ldr	x26, [x26, _ISO_BUFFER_SIZE@GOTPAGEOFF]
Lloh14:
	adrp	x21, _ISO_MAX_FRAME_SIZE@GOTPAGE
Lloh15:
	ldr	x21, [x21, _ISO_MAX_FRAME_SIZE@GOTPAGEOFF]
	b	LBB0_4
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	add	x20, x20, #1
	ldrsw	x8, [x23]
	cmp	x20, x8
	b.ge	LBB0_11
LBB0_4:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_8 Depth 2
	ldr	w1, [x24]
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_usb_alloc_urb
	cbz	x0, LBB0_10
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x22, x0
	ldr	x8, [x19]
	str	x0, [x8, x20, lsl #3]
	ldr	w0, [x19, #8]
	str	x22, [sp]
Lloh16:
	adrp	x1, l_.str.1@PAGE
Lloh17:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_dbg
	mov	w8, #1
	str	w8, [x22]
	ldr	w0, [x19, #12]
	str	w0, [x22, #64]
	mov	w1, #129
	bl	_usb_rcvisocpipe
	str	w0, [x22, #60]
	ldr	w8, [x27]
	ldr	w9, [x28]
	orr	w8, w9, w8
	str	w8, [x22, #4]
	ldr	w0, [x19, #12]
	ldr	w1, [x26]
	ldr	w2, [x24]
	add	x3, x22, #56
	bl	_usb_alloc_coherent
	str	x0, [x22, #48]
	cbz	x0, LBB0_9
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w8, [x26]
Lloh18:
	adrp	x9, _msi2500_isoc_handler@GOTPAGE
Lloh19:
	ldr	x9, [x9, _msi2500_isoc_handler@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x9]
	stp	w9, w8, [x22, #40]
	stp	xzr, x19, [x22, #24]
	ldr	w0, [x25]
	str	w0, [x22, #8]
	cmp	w0, #1
	b.lt	LBB0_3
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x8, #0
	ldr	x9, [x22, #16]
	add	x9, x9, #4
LBB0_8:                                 ;   Parent Loop BB0_4 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w10, [x21]
	mul	w10, w10, w8
	stur	w10, [x9, #-4]
	ldr	w10, [x21]
	str	w10, [x9], #8
	add	x8, x8, #1
	ldrsw	x0, [x25]
	cmp	x8, x0
	b.lt	LBB0_8
	b	LBB0_3
LBB0_9:
	ldr	w0, [x19, #8]
Lloh21:
	adrp	x1, l_.str.2@PAGE
Lloh22:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x2, x20
	bl	_dev_err
LBB0_10:
	mov	x0, x19
	bl	_msi2500_isoc_cleanup
Lloh23:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh24:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh25:
	ldr	w8, [x8]
	neg	w20, w8
	b	LBB0_16
LBB0_11:
	cmp	w8, #1
	b.lt	LBB0_15
; %bb.12:
	mov	x21, #0
Lloh26:
	adrp	x22, l_.str.4@PAGE
Lloh27:
	add	x22, x22, l_.str.4@PAGEOFF
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19]
	ldr	x0, [x8, x21, lsl #3]
	ldr	w1, [x24]
	bl	_usb_submit_urb
	mov	x20, x0
	cbnz	w0, LBB0_17
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	w0, [x19, #8]
	ldr	x8, [x19]
	ldr	x8, [x8, x21, lsl #3]
	str	x8, [sp]
	mov	x1, x22
	bl	_dev_dbg
	add	x21, x21, #1
	ldrsw	x8, [x23]
	cmp	x21, x8
	b.lt	LBB0_13
	b	LBB0_16
LBB0_15:
	mov	w20, #0
LBB0_16:
	mov	x0, x20
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_17:
	ldr	w0, [x19, #8]
	str	x20, [sp]
Lloh28:
	adrp	x1, l_.str.3@PAGE
Lloh29:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x2, x21
	bl	_dev_err
	mov	x0, x19
	bl	_msi2500_isoc_cleanup
	b	LBB0_16
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpAdd	Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"\n"

	.comm	_MAX_ISO_BUFS,4,2               ; @MAX_ISO_BUFS
	.comm	_ISO_FRAMES_PER_DESC,4,2        ; @ISO_FRAMES_PER_DESC
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.1:                               ; @.str.1
	.asciz	"Allocated URB at 0x%p\n"

	.comm	_URB_ISO_ASAP,4,2               ; @URB_ISO_ASAP
	.comm	_URB_NO_TRANSFER_DMA_MAP,4,2    ; @URB_NO_TRANSFER_DMA_MAP
	.comm	_ISO_BUFFER_SIZE,4,2            ; @ISO_BUFFER_SIZE
l_.str.2:                               ; @.str.2
	.asciz	"Failed to allocate urb buffer %d\n"

	.comm	_msi2500_isoc_handler,4,2       ; @msi2500_isoc_handler
	.comm	_ISO_MAX_FRAME_SIZE,4,2         ; @ISO_MAX_FRAME_SIZE
l_.str.3:                               ; @.str.3
	.asciz	"usb_submit_urb %d failed with error %d\n"

l_.str.4:                               ; @.str.4
	.asciz	"URB 0x%p submitted.\n"

	.no_dead_strip	_msi2500_isoc_init
.subsections_via_symbols
