	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function su3000_i2c_transfer
_su3000_i2c_transfer:                   ## @su3000_i2c_transfer
	.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
	movl	%edx, %ebx
	movq	%rsi, %r12
	callq	_i2c_get_adapdata
	testq	%rax, %rax
	je	LBB0_8
## %bb.1:
	movq	%rax, %r15
	movq	8(%rax), %r13
	movq	%rax, %rdi
	callq	_mutex_lock_interruptible
	testq	%rax, %rax
	js	LBB0_11
## %bb.2:
	movq	%r15, %r14
	addq	$4, %r14
	movq	%r14, %rdi
	callq	_mutex_lock_interruptible
	testq	%rax, %rax
	js	LBB0_10
## %bb.3:
	cmpl	$2, %ebx
	je	LBB0_13
## %bb.4:
	cmpl	$1, %ebx
	jne	LBB0_17
## %bb.5:
	movl	(%r12), %eax
	cmpl	$129, %eax
	je	LBB0_18
## %bb.6:
	cmpl	$128, %eax
	jne	LBB0_21
## %bb.7:
	movq	8(%r12), %rax
	movl	(%rax), %eax
	addl	$54, %eax
	movq	(%r13), %rcx
	movl	%eax, (%rcx)
	movq	$3, 4(%rcx)
	movq	%r15, %rdi
	movq	%rcx, %rsi
	movl	$3, %edx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_dvb_usb_generic_rw
	movl	$1, %ebx
	testl	%eax, %eax
	jns	LBB0_28
	jmp	LBB0_27
LBB0_8:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	jmp	LBB0_12
LBB0_10:
	movq	%r15, %rdi
	callq	_mutex_unlock
LBB0_11:
	movq	_EAGAIN@GOTPCREL(%rip), %rax
LBB0_12:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_29
LBB0_13:
	movl	16(%r12), %esi
	leal	-5(%rsi), %eax
	cmpl	$-10, %eax
	jbe	LBB0_15
## %bb.14:
	movl	40(%r12), %esi
	leal	-8(%rsi), %eax
	cmpl	$-10, %eax
	ja	LBB0_23
LBB0_15:
	leaq	L_.str.2(%rip), %rdi
LBB0_16:
	xorl	%ebx, %ebx
                                        ## kill: def $esi killed $esi killed $rsi
	xorl	%eax, %eax
	callq	_warn
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_28
LBB0_17:
	leaq	L_.str.3(%rip), %rdi
	xorl	%eax, %eax
	callq	_warn
	jmp	LBB0_28
LBB0_18:
	movq	(%r13), %rcx
	movl	$16, (%rcx)
	movl	$1, %ebx
	movq	%r15, %rdi
	movq	%rcx, %rsi
	movl	$1, %edx
	movl	$2, %r8d
	xorl	%r9d, %r9d
	callq	_dvb_usb_generic_rw
	testl	%eax, %eax
	jns	LBB0_20
## %bb.19:
	leaq	L_.str(%rip), %rdi
	callq	_err
LBB0_20:
	movq	(%r13), %rax
	movl	(%rax), %ecx
	movq	8(%r12), %rdx
	movl	%ecx, 4(%rdx)
	movl	4(%rax), %eax
	movl	%eax, (%rdx)
	jmp	LBB0_28
LBB0_21:
	movl	16(%r12), %esi
	leal	-6(%rsi), %eax
	cmpl	$-10, %eax
	ja	LBB0_26
## %bb.22:
	leaq	L_.str.1(%rip), %rdi
	jmp	LBB0_16
LBB0_23:
	movq	(%r13), %rdi
	movl	$9, (%rdi)
	movl	16(%r12), %eax
	movl	%eax, 4(%rdi)
	movl	40(%r12), %eax
	movl	%eax, 8(%rdi)
	movl	(%r12), %eax
	movl	%eax, 12(%rdi)
	addq	$16, %rdi
	movq	8(%r12), %rsi
	movl	16(%r12), %edx
	callq	_memcpy
	movq	(%r13), %rcx
	movl	16(%r12), %edx
	movl	40(%r12), %r8d
	addl	$4, %edx
	incl	%r8d
	movq	%r15, %rdi
	movq	%rcx, %rsi
	xorl	%r9d, %r9d
	callq	_dvb_usb_generic_rw
	testl	%eax, %eax
	jns	LBB0_25
## %bb.24:
	leaq	L_.str(%rip), %rdi
	callq	_err
LBB0_25:
	movq	32(%r12), %rdi
	movq	(%r13), %rsi
	addq	$4, %rsi
	movl	40(%r12), %edx
	callq	_memcpy
	movl	$2, %ebx
	jmp	LBB0_28
LBB0_26:
	movq	(%r13), %rdi
	movl	$8, (%rdi)
	movl	(%r12), %eax
	movl	%eax, 4(%rdi)
	movl	16(%r12), %eax
	movl	%eax, 8(%rdi)
	addq	$12, %rdi
	movq	8(%r12), %rsi
	movl	16(%r12), %edx
	callq	_memcpy
	movq	(%r13), %rcx
	movl	16(%r12), %edx
	addl	$3, %edx
	movl	$1, %ebx
	movq	%r15, %rdi
	movq	%rcx, %rsi
	movl	$1, %r8d
	xorl	%r9d, %r9d
	callq	_dvb_usb_generic_rw
	testl	%eax, %eax
	jns	LBB0_28
LBB0_27:
	leaq	L_.str(%rip), %rdi
	callq	_err
LBB0_28:
	movq	%r14, %rdi
	callq	_mutex_unlock
	movq	%r15, %rdi
	callq	_mutex_unlock
LBB0_29:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_EAGAIN,4,2                     ## @EAGAIN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"i2c transfer failed."

L_.str.1:                               ## @.str.1
	.asciz	"i2c wr: len=%d is too big!\n"

	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
L_.str.2:                               ## @.str.2
	.asciz	"i2c rd: len=%d is too big!\n"

L_.str.3:                               ## @.str.3
	.asciz	"more than 2 i2c messages at a time is not handled yet."

	.no_dead_strip	_su3000_i2c_transfer
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function su3000_i2c_transfer
lCPI0_0:
	.long	3                               ; 0x3
	.long	0                               ; 0x0
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_su3000_i2c_transfer:                   ; @su3000_i2c_transfer
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x22, x2
	mov	x21, x1
	bl	_i2c_get_adapdata
	cbz	x0, LBB0_8
; %bb.1:
	mov	x19, x0
	ldr	x23, [x0, #8]
	bl	_mutex_lock_interruptible
	tbnz	x0, #63, LBB0_10
; %bb.2:
	add	x20, x19, #4
	mov	x0, x20
	bl	_mutex_lock_interruptible
	tbnz	x0, #63, LBB0_9
; %bb.3:
	cmp	w22, #2
	b.eq	LBB0_12
; %bb.4:
	cmp	w22, #1
	b.ne	LBB0_16
; %bb.5:
	ldr	w8, [x21]
	cmp	w8, #129
	b.eq	LBB0_17
; %bb.6:
	cmp	w8, #128
	b.ne	LBB0_20
; %bb.7:
	ldr	x8, [x21, #8]
	ldr	w8, [x8]
	add	w8, w8, #54
	ldr	x1, [x23]
	str	w8, [x1]
Lloh0:
	adrp	x8, lCPI0_0@PAGE
Lloh1:
	ldr	d0, [x8, lCPI0_0@PAGEOFF]
	stur	d0, [x1, #4]
	mov	x0, x19
	mov	w2, #3
	mov	x3, x1
	mov	w4, #0
	mov	w5, #0
	bl	_dvb_usb_generic_rw
	tbz	w0, #31, LBB0_27
	b	LBB0_26
LBB0_8:
Lloh2:
	adrp	x8, _ENODEV@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
	b	LBB0_11
LBB0_9:
	mov	x0, x19
	bl	_mutex_unlock
LBB0_10:
Lloh4:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
LBB0_11:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_29
LBB0_12:
	ldr	w8, [x21, #16]
	sub	w9, w8, #5
	cmn	w9, #10
	b.ls	LBB0_14
; %bb.13:
	ldr	w8, [x21, #40]
	sub	w9, w8, #8
	cmn	w9, #10
	b.hi	LBB0_22
LBB0_14:
	str	x8, [sp]
Lloh6:
	adrp	x0, l_.str.2@PAGE
Lloh7:
	add	x0, x0, l_.str.2@PAGEOFF
LBB0_15:
	bl	_warn
Lloh8:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_28
LBB0_16:
Lloh11:
	adrp	x0, l_.str.3@PAGE
Lloh12:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_warn
	b	LBB0_28
LBB0_17:
	ldr	x1, [x23]
	mov	w8, #16
	str	w8, [x1]
	mov	x0, x19
	mov	w2, #1
	mov	x3, x1
	mov	w4, #2
	mov	w5, #0
	bl	_dvb_usb_generic_rw
	tbz	w0, #31, LBB0_19
; %bb.18:
Lloh13:
	adrp	x0, l_.str@PAGE
Lloh14:
	add	x0, x0, l_.str@PAGEOFF
	bl	_err
LBB0_19:
	ldr	x8, [x23]
	ldr	w9, [x8]
	ldr	x10, [x21, #8]
	str	w9, [x10, #4]
	ldr	w8, [x8, #4]
	str	w8, [x10]
	b	LBB0_27
LBB0_20:
	ldr	w8, [x21, #16]
	sub	w9, w8, #6
	cmn	w9, #10
	b.hi	LBB0_25
; %bb.21:
	str	x8, [sp]
Lloh15:
	adrp	x0, l_.str.1@PAGE
Lloh16:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_15
LBB0_22:
	ldr	x8, [x23]
	mov	w9, #9
	str	w9, [x8]
	ldr	w9, [x21, #16]
	str	w9, [x8, #4]
	ldr	w9, [x21, #40]
	str	w9, [x8, #8]
	ldr	w9, [x21]
	str	w9, [x8, #12]
	add	x0, x8, #16
	ldr	x1, [x21, #8]
	ldr	w2, [x21, #16]
	bl	_memcpy
	ldr	x1, [x23]
	ldr	w8, [x21, #16]
	add	w2, w8, #4
	ldr	w8, [x21, #40]
	add	w4, w8, #1
	mov	x0, x19
	mov	x3, x1
	mov	w5, #0
	bl	_dvb_usb_generic_rw
	tbz	w0, #31, LBB0_24
; %bb.23:
Lloh17:
	adrp	x0, l_.str@PAGE
Lloh18:
	add	x0, x0, l_.str@PAGEOFF
	bl	_err
LBB0_24:
	ldr	x0, [x21, #32]
	ldr	x8, [x23]
	add	x1, x8, #4
	ldr	w2, [x21, #40]
	bl	_memcpy
	mov	w22, #2
	b	LBB0_28
LBB0_25:
	ldr	x8, [x23]
	mov	w9, #8
	str	w9, [x8]
	ldr	w9, [x21]
	str	w9, [x8, #4]
	ldr	w9, [x21, #16]
	str	w9, [x8, #8]
	add	x0, x8, #12
	ldr	x1, [x21, #8]
	ldr	w2, [x21, #16]
	bl	_memcpy
	ldr	x1, [x23]
	ldr	w8, [x21, #16]
	add	w2, w8, #3
	mov	w22, #1
	mov	x0, x19
	mov	x3, x1
	mov	w4, #1
	mov	w5, #0
	bl	_dvb_usb_generic_rw
	tbz	w0, #31, LBB0_28
LBB0_26:
Lloh19:
	adrp	x0, l_.str@PAGE
Lloh20:
	add	x0, x0, l_.str@PAGEOFF
	bl	_err
LBB0_27:
	mov	w22, #1
LBB0_28:
	mov	x0, x20
	bl	_mutex_unlock
	mov	x0, x19
	bl	_mutex_unlock
LBB0_29:
	mov	x0, x22
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdr	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_EAGAIN,4,2                     ; @EAGAIN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"i2c transfer failed."

l_.str.1:                               ; @.str.1
	.asciz	"i2c wr: len=%d is too big!\n"

	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
l_.str.2:                               ; @.str.2
	.asciz	"i2c rd: len=%d is too big!\n"

l_.str.3:                               ; @.str.3
	.asciz	"more than 2 i2c messages at a time is not handled yet."

	.no_dead_strip	_su3000_i2c_transfer
.subsections_via_symbols
