	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gmbus_xfer_read
_gmbus_xfer_read:                       ## @gmbus_xfer_read
	.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	%ecx, -48(%rbp)                 ## 4-byte Spill
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movq	%rsi, %r12
	movq	%rdi, %r13
	movq	8(%rsi), %rbx
	movl	(%rsi), %r14d
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r13, %rdi
	callq	_HAS_GMBUS_BURST_READ
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	_INTEL_GMBUS_BURST_READ_MAX_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	%r13, %rdi
	callq	_gmbus_max_xfer_size
	movl	%eax, %esi
LBB0_4:                                 ##   in Loop: Header=BB0_1 Depth=1
	movl	%r14d, %edi
	callq	_min
	movl	%eax, %r15d
	movl	4(%r12), %esi
	movq	%r13, %rdi
	movq	%rbx, %rdx
	movl	%eax, %ecx
	movl	-44(%rbp), %r8d                 ## 4-byte Reload
	movl	-48(%rbp), %r9d                 ## 4-byte Reload
	callq	_gmbus_xfer_read_chunk
	testl	%eax, %eax
	jne	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_1 Depth=1
	movl	%r15d, %ecx
	leaq	(%rbx,%rcx,4), %rbx
	subl	%r15d, %r14d
	jne	LBB0_1
LBB0_6:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_INTEL_GMBUS_BURST_READ_MAX_LEN,4,2 ## @INTEL_GMBUS_BURST_READ_MAX_LEN
	.no_dead_strip	_gmbus_xfer_read
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gmbus_xfer_read
_gmbus_xfer_read:                       ; @gmbus_xfer_read
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x3
	mov	x20, x2
	mov	x21, x1
	mov	x22, x0
	ldr	x23, [x1, #8]
	ldr	w24, [x1]
Lloh0:
	adrp	x26, _INTEL_GMBUS_BURST_READ_MAX_LEN@GOTPAGE
Lloh1:
	ldr	x26, [x26, _INTEL_GMBUS_BURST_READ_MAX_LEN@GOTPAGEOFF]
	b	LBB0_3
LBB0_1:                                 ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x22
	bl	_gmbus_max_xfer_size
	mov	x1, x0
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x24
	bl	_min
	mov	x25, x0
	ldr	w1, [x21, #4]
	mov	x0, x22
	mov	x2, x23
	mov	x3, x25
	mov	x4, x20
	mov	x5, x19
	bl	_gmbus_xfer_read_chunk
	sub	w24, w24, w25
	add	x23, x23, w25, uxtw #2
	cmp	w0, #0
	ccmp	w24, #0, #4, eq
	b.eq	LBB0_5
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x22
	bl	_HAS_GMBUS_BURST_READ
	cbz	x0, LBB0_1
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w1, [x26]
	b	LBB0_2
LBB0_5:
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_INTEL_GMBUS_BURST_READ_MAX_LEN,4,2 ; @INTEL_GMBUS_BURST_READ_MAX_LEN
	.no_dead_strip	_gmbus_xfer_read
.subsections_via_symbols
