	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function rsb_start
_rsb_start:                             ## @rsb_start
	.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	%edi, -44(%rbp)                 ## 4-byte Spill
	callq	_device_get_softc
	movq	%rax, %r13
	movq	%rax, %rdi
	callq	_RSB_ASSERT_LOCKED
	movq	_RSB_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_GLOBAL_INT_ENB@GOTPCREL(%rip), %rax
	movq	_START_TRANS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	orl	(%rax), %edx
	movq	%r13, %rdi
	callq	_RSB_WRITE
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	_RSB_I2C_TIMEOUT@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	testl	%ebx, %ebx
	jle	LBB0_4
## %bb.1:
	incl	%ebx
	movq	_RSB_INTS@GOTPCREL(%rip), %r14
	movq	_INT_TRANS_OVER@GOTPCREL(%rip), %r15
	movq	_hz@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r14), %esi
	movq	%r13, %rdi
	callq	_RSB_READ
	orl	(%r13), %eax
	movl	%eax, (%r13)
	movl	(%r15), %ecx
	testl	%eax, %ecx
	jne	LBB0_6
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	imull	$1000, (%r12), %eax             ## imm = 0x3E8
	cltd
	movq	_RSB_I2C_TIMEOUT@GOTPCREL(%rip), %rcx
	idivl	(%rcx)
	movl	%eax, %edi
	callq	_DELAY
	decl	%ebx
	cmpl	$1, %ebx
	jg	LBB0_2
LBB0_4:
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	testl	%edx, %edx
	jne	LBB0_8
## %bb.5:
	movl	(%r13), %eax
	movq	_INT_TRANS_OVER@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
LBB0_6:
	xorl	%edx, %edx
	testl	%eax, %ecx
	jne	LBB0_8
## %bb.7:
	leaq	L_.str(%rip), %rsi
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	movl	%eax, %edx
	callq	_device_printf
	movq	_EIO@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
LBB0_8:
	movl	%edx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_RSB_CTRL,4,2                   ## @RSB_CTRL
	.comm	_GLOBAL_INT_ENB,4,2             ## @GLOBAL_INT_ENB
	.comm	_START_TRANS,4,2                ## @START_TRANS
	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
	.comm	_RSB_I2C_TIMEOUT,4,2            ## @RSB_I2C_TIMEOUT
	.comm	_RSB_INTS,4,2                   ## @RSB_INTS
	.comm	_INT_TRANS_OVER,4,2             ## @INT_TRANS_OVER
	.comm	_hz,4,2                         ## @hz
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"transfer error, status 0x%08x\n"

	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_rsb_start
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function rsb_start
_rsb_start:                             ; @rsb_start
	.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	x19, x0
	bl	_device_get_softc
	mov	x20, x0
	bl	_RSB_ASSERT_LOCKED
Lloh0:
	adrp	x8, _RSB_CTRL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RSB_CTRL@GOTPAGEOFF]
Lloh2:
	adrp	x9, _GLOBAL_INT_ENB@GOTPAGE
Lloh3:
	ldr	x9, [x9, _GLOBAL_INT_ENB@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	ldr	w8, [x9]
Lloh6:
	adrp	x9, _START_TRANS@GOTPAGE
Lloh7:
	ldr	x9, [x9, _START_TRANS@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	orr	w2, w9, w8
	mov	x0, x20
	bl	_RSB_WRITE
Lloh9:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
Lloh11:
	ldr	w21, [x8]
Lloh12:
	adrp	x22, _RSB_I2C_TIMEOUT@GOTPAGE
Lloh13:
	ldr	x22, [x22, _RSB_I2C_TIMEOUT@GOTPAGEOFF]
	ldr	w8, [x22]
	cmp	w8, #1
	b.lt	LBB0_4
; %bb.1:
Lloh14:
	adrp	x23, _RSB_INTS@GOTPAGE
Lloh15:
	ldr	x23, [x23, _RSB_INTS@GOTPAGEOFF]
	add	w24, w8, #1
Lloh16:
	adrp	x25, _INT_TRANS_OVER@GOTPAGE
Lloh17:
	ldr	x25, [x25, _INT_TRANS_OVER@GOTPAGEOFF]
	mov	w26, #1000
Lloh18:
	adrp	x27, _hz@GOTPAGE
Lloh19:
	ldr	x27, [x27, _hz@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x23]
	mov	x0, x20
	bl	_RSB_READ
	ldr	w8, [x20]
	orr	w2, w8, w0
	str	w2, [x20]
	ldr	w8, [x25]
	tst	w8, w2
	b.ne	LBB0_6
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	w8, [x27]
	mul	w8, w8, w26
	ldr	w9, [x22]
	sdiv	w0, w8, w9
	bl	_DELAY
	sub	w24, w24, #1
	cmp	w24, #1
	b.gt	LBB0_2
LBB0_4:
	cbnz	w21, LBB0_9
; %bb.5:
	ldr	w2, [x20]
Lloh20:
	adrp	x8, _INT_TRANS_OVER@GOTPAGE
Lloh21:
	ldr	x8, [x8, _INT_TRANS_OVER@GOTPAGEOFF]
Lloh22:
	ldr	w8, [x8]
LBB0_6:
	tst	w8, w2
	b.eq	LBB0_8
; %bb.7:
	mov	w21, #0
	b	LBB0_9
LBB0_8:
Lloh23:
	adrp	x1, l_.str@PAGE
Lloh24:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_device_printf
Lloh25:
	adrp	x8, _EIO@GOTPAGE
Lloh26:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh27:
	ldr	w21, [x8]
LBB0_9:
	mov	x0, x21
	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
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh4
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpAdd	Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_RSB_CTRL,4,2                   ; @RSB_CTRL
	.comm	_GLOBAL_INT_ENB,4,2             ; @GLOBAL_INT_ENB
	.comm	_START_TRANS,4,2                ; @START_TRANS
	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
	.comm	_RSB_I2C_TIMEOUT,4,2            ; @RSB_I2C_TIMEOUT
	.comm	_RSB_INTS,4,2                   ; @RSB_INTS
	.comm	_INT_TRANS_OVER,4,2             ; @INT_TRANS_OVER
	.comm	_hz,4,2                         ; @hz
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"transfer error, status 0x%08x\n"

	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_rsb_start
.subsections_via_symbols
