	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ab3100_mask_and_set_register_interruptible
_ab3100_mask_and_set_register_interruptible: ## @ab3100_mask_and_set_register_interruptible
	.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	%r12
	pushq	%rbx
	subq	$32, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %r12d
	movl	%edx, %r15d
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -40(%rbp)
	movl	%esi, -52(%rbp)
	movl	%esi, -48(%rbp)
	movl	$0, -44(%rbp)
	callq	_mutex_lock_interruptible
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_16
## %bb.1:
	movl	8(%r14), %edi
	leaq	-52(%rbp), %rsi
	movl	$1, %edx
	callq	_i2c_master_send
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_8
## %bb.2:
	cmpl	$1, %ebx
	jne	LBB0_9
## %bb.3:
	leaq	-44(%rbp), %rsi
	movl	8(%r14), %edi
	movl	$1, %edx
	callq	_i2c_master_recv
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_10
## %bb.4:
	cmpl	$1, %ebx
	jne	LBB0_12
## %bb.5:
	andl	-44(%rbp), %r15d
	orl	%r12d, %r15d
	movl	%r15d, -44(%rbp)
	movl	8(%r14), %edi
	leaq	-48(%rbp), %rsi
	movl	$2, %edx
	callq	_i2c_master_send
	movl	%eax, %r15d
	testl	%eax, %eax
	js	LBB0_18
## %bb.6:
	xorl	%ebx, %ebx
	cmpl	$2, %r15d
	je	LBB0_15
## %bb.7:
	movl	4(%r14), %edi
	leaq	L_.str.5(%rip), %rsi
	movl	%r15d, %edx
	jmp	LBB0_14
LBB0_8:
	movl	4(%r14), %edi
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_11
LBB0_9:
	movl	4(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_13
LBB0_10:
	movl	4(%r14), %edi
	leaq	L_.str.2(%rip), %rsi
LBB0_11:
	movl	%ebx, %edx
	callq	_dev_err
	jmp	LBB0_15
LBB0_12:
	movl	4(%r14), %edi
	leaq	L_.str.3(%rip), %rsi
LBB0_13:
	movl	%ebx, %edx
LBB0_14:
	callq	_dev_err
	movq	_EIO@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_15:
	movq	%r14, %rdi
	callq	_mutex_unlock
LBB0_16:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-40(%rbp), %rax
	jne	LBB0_19
## %bb.17:
	movl	%ebx, %eax
	addq	$32, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_18:
	movl	4(%r14), %edi
	leaq	L_.str.4(%rip), %rsi
	movl	%r15d, %edx
	callq	_dev_err
	movl	%r15d, %ebx
	jmp	LBB0_15
LBB0_19:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"write error (maskset send address): %d\n"

L_.str.1:                               ## @.str.1
	.asciz	"write error (maskset send address)\n  %d bytes transferred (expected 1)\n"

	.comm	_EIO,4,2                        ## @EIO
L_.str.2:                               ## @.str.2
	.asciz	"write error (maskset read register): %d\n"

L_.str.3:                               ## @.str.3
	.asciz	"write error (maskset read register)\n  %d bytes transferred (expected 1)\n"

L_.str.4:                               ## @.str.4
	.asciz	"write error (write register): %d\n"

L_.str.5:                               ## @.str.5
	.asciz	"write error (write register)\n  %d bytes transferred (expected 2)\n"

	.no_dead_strip	_ab3100_mask_and_set_register_interruptible
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ab3100_mask_and_set_register_interruptible
_ab3100_mask_and_set_register_interruptible: ; @ab3100_mask_and_set_register_interruptible
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x21, x3
	mov	x22, x2
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	stp	w1, w1, [sp, #12]
	str	wzr, [sp, #20]
	bl	_mutex_lock_interruptible
	mov	x20, x0
	cbnz	w0, LBB0_17
; %bb.1:
	ldr	w0, [x19, #8]
	add	x1, sp, #12
	mov	w2, #1
	bl	_i2c_master_send
	mov	x20, x0
	tbnz	w0, #31, LBB0_8
; %bb.2:
	cmp	w20, #1
	b.ne	LBB0_9
; %bb.3:
	add	x8, sp, #16
	add	x1, x8, #4
	ldr	w0, [x19, #8]
	mov	w2, #1
	bl	_i2c_master_recv
	mov	x20, x0
	tbnz	w0, #31, LBB0_10
; %bb.4:
	cmp	w20, #1
	b.ne	LBB0_11
; %bb.5:
	ldr	w8, [sp, #20]
	and	w8, w8, w22
	orr	w8, w8, w21
	str	w8, [sp, #20]
	ldr	w0, [x19, #8]
	add	x1, sp, #16
	mov	w2, #2
	bl	_i2c_master_send
	mov	x20, x0
	tbnz	w0, #31, LBB0_12
; %bb.6:
	cmp	w20, #2
	b.ne	LBB0_14
; %bb.7:
	mov	w20, #0
	b	LBB0_16
LBB0_8:
	ldr	w0, [x19, #4]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_13
LBB0_9:
	ldr	w0, [x19, #4]
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_15
LBB0_10:
	ldr	w0, [x19, #4]
Lloh7:
	adrp	x1, l_.str.2@PAGE
Lloh8:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_13
LBB0_11:
	ldr	w0, [x19, #4]
Lloh9:
	adrp	x1, l_.str.3@PAGE
Lloh10:
	add	x1, x1, l_.str.3@PAGEOFF
	b	LBB0_15
LBB0_12:
	ldr	w0, [x19, #4]
Lloh11:
	adrp	x1, l_.str.4@PAGE
Lloh12:
	add	x1, x1, l_.str.4@PAGEOFF
LBB0_13:
	mov	x2, x20
	bl	_dev_err
	b	LBB0_16
LBB0_14:
	ldr	w0, [x19, #4]
Lloh13:
	adrp	x1, l_.str.5@PAGE
Lloh14:
	add	x1, x1, l_.str.5@PAGEOFF
LBB0_15:
	mov	x2, x20
	bl	_dev_err
Lloh15:
	adrp	x8, _EIO@GOTPAGE
Lloh16:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_16:
	mov	x0, x19
	bl	_mutex_unlock
LBB0_17:
	ldr	x8, [sp, #24]
Lloh18:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh19:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh20:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_19
; %bb.18:
	mov	x0, x20
	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
	add	sp, sp, #80
	ret
LBB0_19:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"write error (maskset send address): %d\n"

l_.str.1:                               ; @.str.1
	.asciz	"write error (maskset send address)\n  %d bytes transferred (expected 1)\n"

	.comm	_EIO,4,2                        ; @EIO
l_.str.2:                               ; @.str.2
	.asciz	"write error (maskset read register): %d\n"

l_.str.3:                               ; @.str.3
	.asciz	"write error (maskset read register)\n  %d bytes transferred (expected 1)\n"

l_.str.4:                               ; @.str.4
	.asciz	"write error (write register): %d\n"

l_.str.5:                               ; @.str.5
	.asciz	"write error (write register)\n  %d bytes transferred (expected 2)\n"

	.no_dead_strip	_ab3100_mask_and_set_register_interruptible
.subsections_via_symbols
