	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function efx_mcdi_phy_get_module_eeprom
_efx_mcdi_phy_get_module_eeprom:        ## @efx_mcdi_phy_get_module_eeprom
	.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
	movq	%rdx, %r12
	movq	%rsi, %rbx
	movq	(%rsi), %r15
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	callq	_efx_mcdi_phy_module_type
	cmpl	$129, %eax
	je	LBB0_7
## %bb.1:
	cmpl	$128, %eax
	jne	LBB0_6
## %bb.2:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_efx_mcdi_phy_sff_8472_level
	testl	%eax, %eax
	jle	LBB0_3
## %bb.4:
	movq	_SFF_8472_NUM_PAGES@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_7:
	movq	_SFF_8436_NUM_PAGES@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movl	$-1, %ecx
	movb	$1, %al
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	jmp	LBB0_8
LBB0_6:
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_21
LBB0_3:
	movq	_SFF_8079_NUM_PAGES@GOTPCREL(%rip), %rax
LBB0_5:
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
	xorl	%ecx, %ecx
LBB0_8:
	movl	8(%rbx), %eax
	movq	_SFP_PAGE_SIZE@GOTPCREL(%rip), %rsi
	cltd
	idivl	(%rsi)
	movl	%eax, %ebx
	xorl	%eax, %eax
	testq	%r15, %r15
	je	LBB0_21
## %bb.9:
	addl	%ecx, %ebx
	cmpl	-48(%rbp), %ebx                 ## 4-byte Folded Reload
	jge	LBB0_21
## %bb.10:
	movl	%edx, %r13d
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	xorb	$1, %al
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	.p2align	4, 0x90
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	%ebx, %esi
	movq	%r12, %rdx
	movl	%r13d, %ecx
	movq	%r15, %r8
	callq	_efx_mcdi_phy_get_module_eeprom_page
	movl	%eax, %ecx
	testl	%eax, %eax
	jle	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=1
	movl	%ecx, %r14d
	subq	%r14, %r15
	jmp	LBB0_18
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_11 Depth=1
	xorl	%eax, %eax
	testl	%ecx, %ecx
	je	LBB0_21
## %bb.14:                              ##   in Loop: Header=BB0_11 Depth=1
	testl	%ebx, %ebx
	setle	%dl
	orb	-44(%rbp), %dl                  ## 1-byte Folded Reload
	jne	LBB0_15
## %bb.16:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	_SFP_PAGE_SIZE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	subl	%r13d, %edx
	movslq	%edx, %r14
	subq	%r14, %r15
	js	LBB0_21
## %bb.17:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_memset
LBB0_18:                                ##   in Loop: Header=BB0_11 Depth=1
	xorl	%r13d, %r13d
	testq	%r15, %r15
	je	LBB0_19
## %bb.20:                              ##   in Loop: Header=BB0_11 Depth=1
	leaq	(%r12,%r14,4), %r12
	incl	%ebx
	movl	$0, %eax
	cmpl	-48(%rbp), %ebx                 ## 4-byte Folded Reload
	jl	LBB0_11
	jmp	LBB0_21
LBB0_19:
	xorl	%eax, %eax
	jmp	LBB0_21
LBB0_15:
	movl	%ecx, %eax
LBB0_21:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SFF_8472_NUM_PAGES,4,2         ## @SFF_8472_NUM_PAGES
	.comm	_SFF_8079_NUM_PAGES,4,2         ## @SFF_8079_NUM_PAGES
	.comm	_SFF_8436_NUM_PAGES,4,2         ## @SFF_8436_NUM_PAGES
	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
	.comm	_SFP_PAGE_SIZE,4,2              ## @SFP_PAGE_SIZE
	.no_dead_strip	_efx_mcdi_phy_get_module_eeprom
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function efx_mcdi_phy_get_module_eeprom
_efx_mcdi_phy_get_module_eeprom:        ; @efx_mcdi_phy_get_module_eeprom
	.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, x2
	mov	x22, x1
	mov	x20, x0
	ldr	x21, [x1]
	bl	_efx_mcdi_phy_module_type
	cmp	w0, #129
	b.eq	LBB0_3
; %bb.1:
	cmp	w0, #128
	b.ne	LBB0_13
; %bb.2:
	mov	x0, x20
	bl	_efx_mcdi_phy_sff_8472_level
	mov	w8, #0
	mov	w9, #0
Lloh0:
	adrp	x10, _SFF_8472_NUM_PAGES@GOTPAGE
Lloh1:
	ldr	x10, [x10, _SFF_8472_NUM_PAGES@GOTPAGEOFF]
Lloh2:
	adrp	x11, _SFF_8079_NUM_PAGES@GOTPAGE
Lloh3:
	ldr	x11, [x11, _SFF_8079_NUM_PAGES@GOTPAGEOFF]
	cmp	w0, #0
	csel	x10, x10, x11, gt
	ldr	w25, [x10]
	mov	w0, #0
	cbnz	x21, LBB0_4
	b	LBB0_14
LBB0_3:
Lloh4:
	adrp	x8, _SFF_8436_NUM_PAGES@GOTPAGE
Lloh5:
	ldr	x8, [x8, _SFF_8436_NUM_PAGES@GOTPAGEOFF]
Lloh6:
	ldr	w25, [x8]
	mov	w9, #-1
	mov	w8, #1
	mov	w0, #0
	cbz	x21, LBB0_14
LBB0_4:
	ldr	w10, [x22, #8]
Lloh7:
	adrp	x26, _SFP_PAGE_SIZE@GOTPAGE
Lloh8:
	ldr	x26, [x26, _SFP_PAGE_SIZE@GOTPAGEOFF]
	ldr	w11, [x26]
	sdiv	w12, w10, w11
	add	w22, w12, w9
	cmp	w22, w25
	b.ge	LBB0_14
; %bb.5:
	msub	w23, w12, w11, w10
	eor	w27, w8, #0x1
	b	LBB0_8
LBB0_6:                                 ;   in Loop: Header=BB0_8 Depth=1
	mov	w24, w0
	sub	x21, x21, x24
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=1
	mov	w23, #0
	mov	w0, #0
	add	x19, x19, x24, lsl #2
	add	w22, w22, #1
	cmp	x21, #0
	ccmp	w22, w25, #0, ne
	b.ge	LBB0_14
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	mov	x1, x22
	mov	x2, x19
	mov	x3, x23
	mov	x4, x21
	bl	_efx_mcdi_phy_get_module_eeprom_page
	cmp	w0, #1
	b.ge	LBB0_6
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	cbz	w0, LBB0_14
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=1
	cmp	w22, #1
	cset	w8, lt
	orr	w8, w27, w8
	tbnz	w8, #0, LBB0_14
; %bb.11:                               ;   in Loop: Header=BB0_8 Depth=1
	ldr	w8, [x26]
	sub	w8, w8, w23
	sxtw	x24, w8
	subs	x21, x21, x24
	b.mi	LBB0_15
; %bb.12:                               ;   in Loop: Header=BB0_8 Depth=1
	mov	x0, x19
	mov	w1, #0
	mov	x2, x24
	bl	_memset
	b	LBB0_7
LBB0_13:
Lloh9:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_14:
	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_15:
	mov	w0, #0
	b	LBB0_14
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_SFF_8472_NUM_PAGES,4,2         ; @SFF_8472_NUM_PAGES
	.comm	_SFF_8079_NUM_PAGES,4,2         ; @SFF_8079_NUM_PAGES
	.comm	_SFF_8436_NUM_PAGES,4,2         ; @SFF_8436_NUM_PAGES
	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
	.comm	_SFP_PAGE_SIZE,4,2              ; @SFP_PAGE_SIZE
	.no_dead_strip	_efx_mcdi_phy_get_module_eeprom
.subsections_via_symbols
