	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cyttsp_i2c_write_block_data    ## -- Begin function cyttsp_i2c_write_block_data
	.p2align	4, 0x90
_cyttsp_i2c_write_block_data:           ## @cyttsp_i2c_write_block_data
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r8, %r14
	movl	%ecx, %r15d
	movl	%edx, %r12d
	movq	%rsi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	callq	_to_i2c_client
	movq	%rax, %r13
	movl	%r12d, %eax
	shrl	$8, %eax
	andl	$1, %eax
	orl	(%r13), %eax
	movzbl	%r12b, %ecx
	movl	%eax, -80(%rbp)
	movq	%rbx, -72(%rbp)
	leal	1(%r15), %eax
	movl	%eax, -64(%rbp)
	movl	$0, -60(%rbp)
	movl	%ecx, (%rbx)
	addq	$4, %rbx
	movq	%rbx, %rdi
	movq	%r14, %rsi
	movl	%r15d, %edx
	callq	_memcpy
	movl	4(%r13), %ebx
	leaq	-80(%rbp), %r14
	movq	%r14, %rdi
	callq	_ARRAY_SIZE
	movl	%ebx, %edi
	movq	%r14, %rsi
	movl	%eax, %edx
	callq	_i2c_transfer
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_2
## %bb.1:
	leaq	-80(%rbp), %rdi
	callq	_ARRAY_SIZE
	movq	_EIO@GOTPCREL(%rip), %rcx
	xorl	%edx, %edx
	subl	(%rcx), %edx
	xorl	%ecx, %ecx
	cmpl	%eax, %ebx
	cmovel	%ecx, %edx
	movl	%edx, %ebx
LBB0_2:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_4
## %bb.3:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_EIO,4,2                        ## @EIO
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cyttsp_i2c_write_block_data    ; -- Begin function cyttsp_i2c_write_block_data
	.p2align	2
_cyttsp_i2c_write_block_data:           ; @cyttsp_i2c_write_block_data
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x19, x4
	mov	x20, x3
	mov	x21, x2
	mov	x22, x1
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	bl	_to_i2c_client
	mov	x23, x0
	ldr	w8, [x0]
	ubfx	w9, w21, #8, #1
	orr	w8, w8, w9
	and	w9, w21, #0xff
	str	w8, [sp]
	str	x22, [sp, #8]
	add	w8, w20, #1
	stp	w8, wzr, [sp, #16]
	str	w9, [x22], #4
	mov	x0, x22
	mov	x1, x19
	mov	x2, x20
	bl	_memcpy
	ldr	w19, [x23, #4]
	mov	x0, sp
	bl	_ARRAY_SIZE
	mov	x2, x0
	mov	x1, sp
	mov	x0, x19
	bl	_i2c_transfer
	mov	x19, x0
	tbnz	w0, #31, LBB0_2
; %bb.1:
	mov	x0, sp
	bl	_ARRAY_SIZE
Lloh3:
	adrp	x8, _EIO@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	w19, w0
	csneg	w19, wzr, w8, eq
LBB0_2:
	ldr	x8, [sp, #24]
Lloh6:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh7:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_4
; %bb.3:
	mov	x0, x19
	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
	add	sp, sp, #96
	ret
LBB0_4:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_EIO,4,2                        ; @EIO
.subsections_via_symbols
