	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function max6875_update_slice
_max6875_update_slice:                  ## @max6875_update_slice
	.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
	movl	%esi, %ebx
	movq	%rdi, %r12
	callq	_i2c_get_clientdata
	movq	%rax, %r15
	movq	_USER_EEPROM_SLICES@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	jle	LBB0_12
## %bb.1:
	movq	%r15, %rdi
	addq	$12, %rdi
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	callq	_mutex_lock
	movq	_SLICE_BITS@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	movl	%ebx, %eax
	shll	%cl, %eax
	movslq	%eax, %r13
	shlq	$2, %r13
	movl	$1, %eax
	movl	%ebx, %ecx
	shll	%cl, %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	8(%r15), %eax
	addq	(%r15), %r13
	btl	%ebx, %eax
	jae	LBB0_3
## %bb.2:
	movq	_jiffies@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	16(%r15), %rax
	movslq	%ebx, %rcx
	movl	(%rax,%rcx,4), %esi
	callq	_time_after
	testq	%rax, %rax
	je	LBB0_11
LBB0_3:
	leaq	4(%r12), %r14
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_dev_dbg
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	notl	%eax
	andl	%eax, 8(%r15)
	movq	_USER_EEPROM_BASE@GOTPCREL(%rip), %rax
	movq	_SLICE_BITS@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	movl	%ebx, %esi
	shll	%cl, %esi
	addl	(%rax), %esi
	movzbl	%sil, %edx
	sarl	$8, %esi
	movq	%r12, %rdi
	callq	_i2c_smbus_write_byte_data
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	callq	_dev_err
	jmp	LBB0_11
LBB0_12:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movl	(%r12), %edi
	movq	_I2C_FUNC_SMBUS_READ_I2C_BLOCK@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_i2c_check_functionality
	testq	%rax, %rax
	je	LBB0_6
## %bb.13:
	movq	_MAX6875_CMD_BLK_READ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_SLICE_SIZE@GOTPCREL(%rip), %r14
	movl	(%r14), %edx
	movq	%r12, %rdi
	movq	%r13, %rcx
	callq	_i2c_smbus_read_i2c_block_data
	cmpl	(%r14), %eax
	je	LBB0_10
	jmp	LBB0_11
LBB0_6:
	movq	_SLICE_SIZE@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	jle	LBB0_10
## %bb.7:
	xorl	%r14d, %r14d
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r12, %rdi
	callq	_i2c_smbus_read_byte
	testl	%eax, %eax
	js	LBB0_11
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	movl	%eax, (%r13,%r14,4)
	incq	%r14
	movq	_SLICE_SIZE@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	cmpq	%rax, %r14
	jl	LBB0_8
LBB0_10:
	movq	_jiffies@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	16(%r15), %rcx
	movslq	%ebx, %rdx
	movl	%eax, (%rcx,%rdx,4)
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	orl	%eax, 8(%r15)
LBB0_11:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_mutex_unlock                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_USER_EEPROM_SLICES,4,2         ## @USER_EEPROM_SLICES
	.comm	_SLICE_BITS,4,2                 ## @SLICE_BITS
	.comm	_jiffies,4,2                    ## @jiffies
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Starting update of slice %u\n"

	.comm	_USER_EEPROM_BASE,4,2           ## @USER_EEPROM_BASE
L_.str.1:                               ## @.str.1
	.asciz	"address set failed\n"

	.comm	_I2C_FUNC_SMBUS_READ_I2C_BLOCK,4,2 ## @I2C_FUNC_SMBUS_READ_I2C_BLOCK
	.comm	_MAX6875_CMD_BLK_READ,4,2       ## @MAX6875_CMD_BLK_READ
	.comm	_SLICE_SIZE,4,2                 ## @SLICE_SIZE
	.no_dead_strip	_max6875_update_slice
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function max6875_update_slice
_max6875_update_slice:                  ; @max6875_update_slice
	.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
	mov	x20, x1
	mov	x22, x0
	bl	_i2c_get_clientdata
Lloh0:
	adrp	x8, _USER_EEPROM_SLICES@GOTPAGE
Lloh1:
	ldr	x8, [x8, _USER_EEPROM_SLICES@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w20
	b.le	LBB0_5
; %bb.1:
	mov	x21, x0
	add	x19, x0, #12
	mov	x0, x19
	bl	_mutex_lock
Lloh3:
	adrp	x27, _SLICE_BITS@GOTPAGE
Lloh4:
	ldr	x27, [x27, _SLICE_BITS@GOTPAGEOFF]
	ldr	x25, [x21]
	ldr	w26, [x27]
	ldr	w8, [x21, #8]
	mov	w9, #1
	lsl	w24, w9, w20
	tst	w8, w24
	b.eq	LBB0_3
; %bb.2:
Lloh5:
	adrp	x8, _jiffies@GOTPAGE
Lloh6:
	ldr	x8, [x8, _jiffies@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
	ldr	x8, [x21, #16]
	ldr	w1, [x8, w20, sxtw #2]
	bl	_time_after
	cbz	x0, LBB0_13
LBB0_3:
	add	x23, x22, #4
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x23
	mov	x2, x20
	bl	_dev_dbg
	ldr	w8, [x21, #8]
	bic	w8, w8, w24
	str	w8, [x21, #8]
Lloh10:
	adrp	x8, _USER_EEPROM_BASE@GOTPAGE
Lloh11:
	ldr	x8, [x8, _USER_EEPROM_BASE@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	ldr	w9, [x27]
	lsl	w9, w20, w9
	add	w8, w9, w8
	asr	w1, w8, #8
	and	w2, w8, #0xff
	mov	x0, x22
	bl	_i2c_smbus_write_byte_data
	cbz	x0, LBB0_6
; %bb.4:
Lloh13:
	adrp	x1, l_.str.1@PAGE
Lloh14:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x23
	bl	_dev_err
	b	LBB0_13
LBB0_5:
	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_6:
	lsl	w8, w20, w26
	add	x23, x25, w8, sxtw #2
	ldr	w0, [x22]
Lloh15:
	adrp	x8, _I2C_FUNC_SMBUS_READ_I2C_BLOCK@GOTPAGE
Lloh16:
	ldr	x8, [x8, _I2C_FUNC_SMBUS_READ_I2C_BLOCK@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	bl	_i2c_check_functionality
	cbz	x0, LBB0_8
; %bb.7:
Lloh18:
	adrp	x8, _MAX6875_CMD_BLK_READ@GOTPAGE
Lloh19:
	ldr	x8, [x8, _MAX6875_CMD_BLK_READ@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
Lloh21:
	adrp	x25, _SLICE_SIZE@GOTPAGE
Lloh22:
	ldr	x25, [x25, _SLICE_SIZE@GOTPAGEOFF]
	ldr	w2, [x25]
	mov	x0, x22
	mov	x3, x23
	bl	_i2c_smbus_read_i2c_block_data
	ldr	w8, [x25]
	cmp	w0, w8
	b.eq	LBB0_12
	b	LBB0_13
LBB0_8:
Lloh23:
	adrp	x25, _SLICE_SIZE@GOTPAGE
Lloh24:
	ldr	x25, [x25, _SLICE_SIZE@GOTPAGEOFF]
	ldr	w8, [x25]
	cmp	w8, #1
	b.lt	LBB0_12
; %bb.9:
	mov	x26, #0
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x22
	bl	_i2c_smbus_read_byte
	tbnz	w0, #31, LBB0_13
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=1
	str	w0, [x23, x26, lsl #2]
	add	x26, x26, #1
	ldrsw	x8, [x25]
	cmp	x26, x8
	b.lt	LBB0_10
LBB0_12:
Lloh25:
	adrp	x8, _jiffies@GOTPAGE
Lloh26:
	ldr	x8, [x8, _jiffies@GOTPAGEOFF]
Lloh27:
	ldr	w8, [x8]
	ldr	x9, [x21, #16]
	str	w8, [x9, w20, sxtw #2]
	ldr	w8, [x21, #8]
	orr	w8, w8, w24
	str	w8, [x21, #8]
LBB0_13:
	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
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_mutex_unlock
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_USER_EEPROM_SLICES,4,2         ; @USER_EEPROM_SLICES
	.comm	_SLICE_BITS,4,2                 ; @SLICE_BITS
	.comm	_jiffies,4,2                    ; @jiffies
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Starting update of slice %u\n"

	.comm	_USER_EEPROM_BASE,4,2           ; @USER_EEPROM_BASE
l_.str.1:                               ; @.str.1
	.asciz	"address set failed\n"

	.comm	_I2C_FUNC_SMBUS_READ_I2C_BLOCK,4,2 ; @I2C_FUNC_SMBUS_READ_I2C_BLOCK
	.comm	_MAX6875_CMD_BLK_READ,4,2       ; @MAX6875_CMD_BLK_READ
	.comm	_SLICE_SIZE,4,2                 ; @SLICE_SIZE
	.no_dead_strip	_max6875_update_slice
.subsections_via_symbols
