	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tc90522_master_xfer
_tc90522_master_xfer:                   ## @tc90522_master_xfer
	.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	$1080, %rsp                     ## imm = 0x438
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	testl	%edx, %edx
	jle	LBB0_10
## %bb.1:
	movl	%edx, %ebx
	movq	%rdi, %r12
	movq	_I2C_M_RD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%edx, %r14d
	cmpl	$9, %edx
	jae	LBB0_3
## %bb.2:
	xorl	%ecx, %ecx
	xorl	%edi, %edi
	jmp	LBB0_6
LBB0_10:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_11
LBB0_3:
	movl	%r14d, %ecx
	andl	$7, %ecx
	testq	%rcx, %rcx
	movl	$8, %edx
	cmovneq	%rcx, %rdx
	movq	%r14, %rcx
	subq	%rdx, %rcx
	movd	%eax, %xmm0
	pshufd	$0, %xmm0, %xmm0                ## xmm0 = xmm0[0,0,0,0]
	pxor	%xmm2, %xmm2
	pcmpeqd	%xmm3, %xmm3
	movq	%rcx, %rdx
	movq	%rsi, %rdi
	pxor	%xmm4, %xmm4
	pxor	%xmm1, %xmm1
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movd	(%rdi), %xmm5                   ## xmm5 = mem[0],zero,zero,zero
	pinsrd	$1, 24(%rdi), %xmm5
	pinsrd	$2, 48(%rdi), %xmm5
	pinsrd	$3, 72(%rdi), %xmm5
	movd	96(%rdi), %xmm6                 ## xmm6 = mem[0],zero,zero,zero
	pinsrd	$1, 120(%rdi), %xmm6
	pinsrd	$2, 144(%rdi), %xmm6
	pinsrd	$3, 168(%rdi), %xmm6
	pand	%xmm0, %xmm5
	pand	%xmm0, %xmm6
	pcmpeqd	%xmm2, %xmm5
	paddd	%xmm5, %xmm4
	pcmpeqd	%xmm2, %xmm6
	paddd	%xmm6, %xmm1
	psubd	%xmm3, %xmm4
	psubd	%xmm3, %xmm1
	addq	$192, %rdi
	addq	$-8, %rdx
	jne	LBB0_4
## %bb.5:
	paddd	%xmm4, %xmm1
	pshufd	$238, %xmm1, %xmm0              ## xmm0 = xmm1[2,3,2,3]
	paddd	%xmm1, %xmm0
	pshufd	$85, %xmm0, %xmm1               ## xmm1 = xmm0[1,1,1,1]
	paddd	%xmm0, %xmm1
	movd	%xmm1, %edi
LBB0_6:
	leaq	(%rcx,%rcx,2), %rdx
	movq	%rsi, -1096(%rbp)               ## 8-byte Spill
	leaq	(%rsi,%rdx,8), %rdx
	movq	%r14, %rsi
	subq	%rcx, %rsi
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%rdx), %ecx
	andl	%eax, %ecx
	cmpl	$1, %ecx
	sbbl	$-1, %edi
	addq	$24, %rdx
	decq	%rsi
	jne	LBB0_7
## %bb.8:
	addl	%ebx, %edi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	$24, %esi
	callq	_kmalloc_array
	testq	%rax, %rax
	je	LBB0_9
## %bb.12:
	movq	%rax, -1080(%rbp)               ## 8-byte Spill
	movq	%r12, %rdi
	callq	_i2c_get_adapdata
	movl	%ebx, -1084(%rbp)               ## 4-byte Spill
	testl	%ebx, %ebx
	jle	LBB0_13
## %bb.14:
	leaq	3024(%rbp), %r10
	leaq	-1072(%rbp), %r12
	shlq	$3, %r14
	leaq	(%r14,%r14,2), %r11
	xorl	%r14d, %r14d
	xorl	%r13d, %r13d
	movq	-1096(%rbp), %rbx               ## 8-byte Reload
	movq	_I2C_M_RD@GOTPCREL(%rip), %r8
	movq	-1080(%rbp), %rsi               ## 8-byte Reload
	movq	%rax, -1112(%rbp)               ## 8-byte Spill
	movq	%r11, -1104(%rbp)               ## 8-byte Spill
	jmp	LBB0_15
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_15 Depth=1
	movslq	16(%rbx,%r14), %rcx
	leaq	(%r12,%rcx,4), %rcx
	addq	$8, %rcx
	cmpq	%r10, %rcx
	ja	LBB0_25
## %bb.19:                              ##   in Loop: Header=BB0_15 Depth=1
	leaq	8(%r12), %rdi
	movq	_TC90522_I2C_THRU_REG@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, (%r12)
	movl	4(%rbx,%r14), %ecx
	addl	%ecx, %ecx
	movl	%ecx, 4(%r12)
	movq	8(%rbx,%r14), %rsi
	movl	16(%rbx,%r14), %edx
	movq	%r10, %rbx
	callq	_memcpy
	movq	-1104(%rbp), %r11               ## 8-byte Reload
	movq	%rbx, %r10
	movq	-1112(%rbp), %rax               ## 8-byte Reload
	movq	-1080(%rbp), %rsi               ## 8-byte Reload
	movq	_I2C_M_RD@GOTPCREL(%rip), %r8
	movq	-1096(%rbp), %rbx               ## 8-byte Reload
	movq	%r12, 8(%rsi,%r15,8)
	movslq	16(%rbx,%r14), %rdx
	leaq	2(%rdx), %rcx
	movl	%ecx, 16(%rsi,%r15,8)
	leaq	(%r12,%rdx,4), %rdi
	addq	$8, %rdi
LBB0_20:                                ##   in Loop: Header=BB0_15 Depth=1
	incl	%r13d
	addq	$24, %r14
	movq	%rdi, %r12
	cmpq	%r14, %r11
	je	LBB0_21
LBB0_15:                                ## =>This Inner Loop Header: Depth=1
	movq	(%rax), %rcx
	movl	(%rcx), %edi
	movslq	%r13d, %rdx
	leaq	(%rdx,%rdx,2), %r15
	movl	%edi, 4(%rsi,%r15,8)
	movl	(%rbx,%r14), %edi
	movl	%edi, (%rsi,%r15,8)
	movl	(%r8), %edx
	testl	%edx, (%rbx,%r14)
	je	LBB0_18
## %bb.16:                              ##   in Loop: Header=BB0_15 Depth=1
	leaq	(%rsi,%r15,8), %r9
	notl	%edx
	andl	%edx, %edi
	movl	%edi, (%r9)
	leaq	8(%r12), %rdi
	cmpq	%r10, %rdi
	ja	LBB0_25
## %bb.17:                              ##   in Loop: Header=BB0_15 Depth=1
	movq	_TC90522_I2C_THRU_REG@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	movl	%edx, (%r12)
	movl	4(%rbx,%r14), %edx
	addl	%edx, %edx
	incl	%edx
	movl	%edx, 4(%r12)
	movq	%r12, 8(%rsi,%r15,8)
	movl	$2, 16(%rsi,%r15,8)
	incl	%r13d
	movl	(%rcx), %ecx
	movslq	%r13d, %rdx
	leaq	(%rdx,%rdx,2), %rdx
	movl	%ecx, 4(%rsi,%rdx,8)
	movl	(%rbx,%r14), %ecx
	movl	%ecx, (%rsi,%rdx,8)
	movq	8(%rbx,%r14), %rcx
	movq	%rcx, 8(%rsi,%rdx,8)
	movl	16(%rbx,%r14), %ecx
	movl	%ecx, 16(%rsi,%rdx,8)
	jmp	LBB0_20
LBB0_9:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_11:
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	jmp	LBB0_23
LBB0_13:
	xorl	%r13d, %r13d
	movq	-1080(%rbp), %rsi               ## 8-byte Reload
LBB0_21:
	movq	(%rax), %rax
	movl	4(%rax), %edi
	movl	%r13d, %edx
	callq	_i2c_transfer
	movq	-1080(%rbp), %rsi               ## 8-byte Reload
	jmp	LBB0_22
LBB0_25:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_22:
	movq	_EIO@GOTPCREL(%rip), %rcx
	xorl	%r15d, %r15d
	subl	(%rcx), %r15d
	cmpl	%r13d, %eax
	cmovgel	%eax, %r15d
	testl	%eax, %eax
	cmovsl	%eax, %r15d
	movq	%rsi, %rdi
	callq	_kfree
	cmpl	%r13d, %r15d
	cmovel	-1084(%rbp), %r15d              ## 4-byte Folded Reload
LBB0_23:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_26
## %bb.24:
	movl	%r15d, %eax
	addq	$1080, %rsp                     ## imm = 0x438
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_26:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_I2C_M_RD,4,2                   ## @I2C_M_RD
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_TC90522_I2C_THRU_REG,4,2       ## @TC90522_I2C_THRU_REG
	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_tc90522_master_xfer
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tc90522_master_xfer
_tc90522_master_xfer:                   ; @tc90522_master_xfer
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	sub	sp, sp, #1056
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-96]
	cmp	w2, #1
	b.lt	LBB0_3
; %bb.1:
	mov	x19, x2
	mov	x20, x1
	mov	x22, x0
Lloh3:
	adrp	x8, _I2C_M_RD@GOTPAGE
Lloh4:
	ldr	x8, [x8, _I2C_M_RD@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	mov	w25, w2
	cmp	w2, #17
	b.hs	LBB0_4
; %bb.2:
	mov	x9, #0
	mov	w10, #0
	b	LBB0_7
LBB0_3:
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_20
LBB0_4:
	ands	x9, x25, #0xf
	mov	w10, #16
	csel	x9, x10, x9, eq
	sub	x9, x25, x9
	dup.4s	v0, w8
	add	x10, x20, #192
	movi.2d	v1, #0000000000000000
	mov	x11, x9
	movi.2d	v2, #0000000000000000
	movi.2d	v3, #0000000000000000
	movi.2d	v4, #0000000000000000
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldp	q6, q5, [x10, #-144]
	ldur	q7, [x10, #-192]
	ldp	q17, q16, [x10, #-48]
	ldur	q18, [x10, #-96]
	ldp	q20, q19, [x10, #48]
	ldr	q21, [x10]
	sub	x12, x10, #168
	ld1.s	{ v7 }[1], [x12]
	uzp1.4s	v6, v6, v6
	trn1.4s	v5, v6, v5
	mov.d	v7[1], v5[1]
	sub	x12, x10, #72
	ld1.s	{ v18 }[1], [x12]
	ldp	q6, q5, [x10, #144]
	uzp1.4s	v17, v17, v17
	trn1.4s	v16, v17, v16
	mov.d	v18[1], v16[1]
	add	x12, x10, #24
	ld1.s	{ v21 }[1], [x12]
	uzp1.4s	v16, v20, v20
	trn1.4s	v16, v16, v19
	mov.d	v21[1], v16[1]
	ldr	q16, [x10, #96]
	add	x12, x10, #120
	ld1.s	{ v16 }[1], [x12]
	uzp1.4s	v6, v6, v6
	trn1.4s	v5, v6, v5
	mov.d	v16[1], v5[1]
	cmtst.4s	v5, v0, v7
	cmtst.4s	v6, v0, v18
	cmtst.4s	v7, v0, v21
	cmtst.4s	v16, v0, v16
	sub.4s	v1, v1, v5
	sub.4s	v2, v2, v6
	sub.4s	v3, v3, v7
	sub.4s	v4, v4, v16
	add	x10, x10, #384
	subs	x11, x11, #16
	b.ne	LBB0_5
; %bb.6:
	add.4s	v0, v2, v1
	add.4s	v0, v3, v0
	add.4s	v0, v4, v0
	addv.4s	s0, v0
	fmov	w10, s0
LBB0_7:
	mov	w11, #24
	madd	x11, x9, x11, x20
	sub	x9, x25, x9
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w12, [x11], #24
	tst	w8, w12
	cinc	w10, w10, ne
	subs	x9, x9, #1
	b.ne	LBB0_8
; %bb.9:
	add	w0, w10, w19
Lloh8:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
	mov	w1, #24
	bl	_kmalloc_array
	cbz	x0, LBB0_19
; %bb.10:
	mov	x21, x0
	mov	x0, x22
	bl	_i2c_get_adapdata
	mov	x23, x0
	cmp	w19, #1
	str	w19, [sp, #12]                  ; 4-byte Folded Spill
	mov	w22, #0
	b.lt	LBB0_18
; %bb.11:
	add	x8, sp, #16
	add	x26, x8, #1, lsl #12            ; =4096
	add	x24, sp, #16
	add	x20, x20, #16
	mov	w27, #24
Lloh11:
	adrp	x28, _TC90522_I2C_THRU_REG@GOTPAGE
Lloh12:
	ldr	x28, [x28, _TC90522_I2C_THRU_REG@GOTPAGEOFF]
Lloh13:
	adrp	x13, _I2C_M_RD@GOTPAGE
Lloh14:
	ldr	x13, [x13, _I2C_M_RD@GOTPAGEOFF]
	b	LBB0_15
LBB0_12:                                ;   in Loop: Header=BB0_15 Depth=1
	ldrsw	x8, [x20]
	add	x0, x24, #8
	add	x8, x0, x8, lsl #2
	cmp	x8, x26
	b.hi	LBB0_21
; %bb.13:                               ;   in Loop: Header=BB0_15 Depth=1
	ldr	w8, [x28]
	ldur	w9, [x20, #-12]
	lsl	w9, w9, #1
	stp	w8, w9, [x24]
	ldur	x1, [x20, #-8]
	ldr	w2, [x20]
	bl	_memcpy
Lloh15:
	adrp	x13, _I2C_M_RD@GOTPAGE
Lloh16:
	ldr	x13, [x13, _I2C_M_RD@GOTPAGEOFF]
	madd	x8, x19, x27, x21
	str	x24, [x8, #8]
	ldrsw	x9, [x20]
	add	x9, x9, #2
	str	w9, [x8, #16]
	add	x24, x24, x9, lsl #2
LBB0_14:                                ;   in Loop: Header=BB0_15 Depth=1
	add	w22, w22, #1
	add	x20, x20, #24
	subs	x25, x25, #1
	b.eq	LBB0_18
LBB0_15:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x23]
	ldr	w10, [x8]
	sxtw	x19, w22
	smaddl	x9, w22, w27, x21
	str	w10, [x9, #4]
	ldur	w10, [x20, #-16]
	str	w10, [x9]
	ldur	w12, [x20, #-16]
	ldr	w11, [x13]
	tst	w11, w12
	b.eq	LBB0_12
; %bb.16:                               ;   in Loop: Header=BB0_15 Depth=1
	bic	w10, w10, w11
	str	w10, [x9]
	add	x9, x24, #8
	cmp	x9, x26
	b.hi	LBB0_21
; %bb.17:                               ;   in Loop: Header=BB0_15 Depth=1
	ldur	w10, [x20, #-12]
	mov	w11, #1
	bfi	w11, w10, #1, #31
	ldr	w10, [x28]
	stp	w10, w11, [x24]
	madd	x10, x19, x27, x21
	str	x24, [x10, #8]
	mov	w11, #2
	str	w11, [x10, #16]
	add	w22, w19, #1
	ldr	w8, [x8]
	str	w8, [x10, #28]
	ldur	w8, [x20, #-16]
	str	w8, [x10, #24]
	ldur	x8, [x20, #-8]
	str	x8, [x10, #32]
	ldr	w8, [x20]
	str	w8, [x10, #40]
	mov	x24, x9
	b	LBB0_14
LBB0_18:
	ldr	x8, [x23]
	ldr	w0, [x8, #4]
	mov	x1, x21
	mov	x2, x22
	bl	_i2c_transfer
	b	LBB0_22
LBB0_19:
Lloh17:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_20:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_23
LBB0_21:
Lloh19:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh20:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh21:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_22:
	cmp	w0, w22
	mov	w8, #-1
	ccmp	w0, w8, #4, lt
Lloh22:
	adrp	x8, _EIO@GOTPAGE
Lloh23:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	csneg	w19, w0, w8, le
	mov	x0, x21
	bl	_kfree
	cmp	w19, w22
	ldr	w8, [sp, #12]                   ; 4-byte Folded Reload
	csel	w0, w8, w19, eq
LBB0_23:
	ldur	x8, [x29, #-96]
Lloh25:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh26:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh27:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_25
; %bb.24:
	add	sp, sp, #1056
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_25:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_I2C_M_RD,4,2                   ; @I2C_M_RD
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_TC90522_I2C_THRU_REG,4,2       ; @TC90522_I2C_THRU_REG
	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_tc90522_master_xfer
.subsections_via_symbols
