	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function igc_set_eeprom
_igc_set_eeprom:                        ## @igc_set_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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, %r12
	callq	_netdev_priv
	cmpl	$0, 8(%r12)
	je	LBB0_1
## %bb.3:
	movq	%rax, %r13
	movq	40(%rax), %rax
	movq	_igc_i225@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jl	LBB0_5
## %bb.4:
	movq	%r13, %rdi
	callq	_igc_get_flash_presence_i225
	testl	%eax, %eax
	je	LBB0_1
LBB0_5:
	movl	4(%r13), %eax
	shll	$16, %eax
	orl	(%r13), %eax
	cmpl	%eax, (%r12)
	jne	LBB0_6
## %bb.7:
	movl	8(%r13), %edi
	addl	%edi, %edi
	movl	4(%r12), %ebx
	movl	8(%r12), %eax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_kmalloc
	testq	%rax, %rax
	je	LBB0_8
## %bb.9:
	movq	%rax, %r15
	movq	%r14, -72(%rbp)                 ## 8-byte Spill
	movl	%ebx, %eax
	sarl	%ebx
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	leal	(%rax,%rcx), %r14d
	decl	%r14d
	movl	4(%r12), %eax
	testb	$1, %al
	jne	LBB0_11
## %bb.10:
	movb	$1, %cl
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	jmp	LBB0_12
LBB0_1:
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_6:
	movq	_EFAULT@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_8:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_25:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	movq	%r13, %rdi
	movl	%ebx, %esi
	movl	$1, %edx
	movq	%r15, %rcx
	callq	*16(%r13)
	leaq	1(%r15), %rcx
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	testl	%eax, %eax
	sete	%cl
	movl	4(%r12), %eax
LBB0_12:
	sarl	%r14d
	addl	8(%r12), %eax
	testb	$1, %al
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	je	LBB0_14
## %bb.13:
	testb	%cl, %cl
	je	LBB0_14
## %bb.15:
	movl	%r14d, %ebx
	subl	-44(%rbp), %ebx                 ## 4-byte Folded Reload
	movslq	%ebx, %rax
	leaq	(%r15,%rax,4), %rcx
	movq	%r13, %rdi
	movl	%r14d, %esi
	movl	$1, %edx
	callq	*16(%r13)
	movl	%ebx, %eax
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	jmp	LBB0_16
LBB0_14:
	movl	%r14d, %eax
	subl	%ebx, %eax
LBB0_16:
	testl	%eax, %eax
	movl	%eax, -64(%rbp)                 ## 4-byte Spill
	js	LBB0_17
## %bb.18:
	movq	%r13, -80(%rbp)                 ## 8-byte Spill
	subl	%ebx, %r14d
	incl	%r14d
	movq	%r14, %rbx
	movq	%r15, %r13
	.p2align	4, 0x90
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movq	%r13, %rdi
	callq	_le16_to_cpus
	addq	$4, %r13
	decq	%rbx
	jne	LBB0_19
## %bb.20:
	movl	8(%r12), %edx
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	callq	_memcpy
	xorl	%ebx, %ebx
	movq	-80(%rbp), %r13                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_21:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r15,%rbx,4), %edi
	callq	_cpu_to_le16
	movl	%eax, (%r15,%rbx,4)
	incq	%rbx
	cmpq	%rbx, %r14
	jne	LBB0_21
	jmp	LBB0_22
LBB0_17:
	movl	8(%r12), %edx
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	callq	_memcpy
LBB0_22:
	movl	-64(%rbp), %edx                 ## 4-byte Reload
	incl	%edx
	movq	%r13, %rdi
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	movq	%r15, %rcx
	callq	*24(%r13)
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_24
## %bb.23:
	movq	%r13, %rdi
	callq	*32(%r13)
LBB0_24:
	movq	%r15, %rdi
	callq	_kfree
	jmp	LBB0_25
	.cfi_endproc
                                        ## -- End function
	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
	.comm	_igc_i225,8,3                   ## @igc_i225
	.comm	_EFAULT,4,2                     ## @EFAULT
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_igc_set_eeprom
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function igc_set_eeprom
_igc_set_eeprom:                        ; @igc_set_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	x21, x2
	mov	x22, x1
	bl	_netdev_priv
	ldr	w8, [x22, #8]
	cbz	w8, LBB0_7
; %bb.1:
	mov	x19, x0
	ldr	x8, [x0, #40]
Lloh0:
	adrp	x9, _igc_i225@GOTPAGE
Lloh1:
	ldr	x9, [x9, _igc_i225@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.lt	LBB0_3
; %bb.2:
	mov	x0, x19
	bl	_igc_get_flash_presence_i225
	cbz	w0, LBB0_7
LBB0_3:
	ldr	w8, [x22]
	ldp	w9, w10, [x19]
	orr	w9, w9, w10, lsl #16
	cmp	w8, w9
	b.ne	LBB0_8
; %bb.4:
	ldr	w8, [x19, #8]
	lsl	w0, w8, #1
	ldp	w24, w25, [x22, #4]
Lloh3:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	bl	_kmalloc
	cbz	x0, LBB0_9
; %bb.5:
	mov	x20, x0
	asr	w23, w24, #1
	add	w8, w24, w25
	sub	w25, w8, #1
	ldr	w9, [x22, #4]
	tbnz	w9, #0, LBB0_12
; %bb.6:
	mov	w8, #1
	mov	x24, x20
	b	LBB0_13
LBB0_7:
Lloh6:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
	b	LBB0_10
LBB0_8:
Lloh8:
	adrp	x8, _EFAULT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EFAULT@GOTPAGEOFF]
	b	LBB0_10
LBB0_9:
Lloh10:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_10:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_11:
	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
LBB0_12:
	ldr	x8, [x19, #16]
	mov	x0, x19
	mov	x1, x23
	mov	w2, #1
	mov	x3, x20
	blr	x8
	add	x24, x20, #1
	cmp	w0, #0
	cset	w8, eq
	ldr	w9, [x22, #4]
LBB0_13:
	asr	w25, w25, #1
	ldr	w10, [x22, #8]
	add	w9, w10, w9
	tbz	w9, #0, LBB0_20
; %bb.14:
	tbz	w8, #0, LBB0_20
; %bb.15:
	ldr	x8, [x19, #16]
	sub	w26, w25, w23
	add	x3, x20, w26, sxtw #2
	mov	x0, x19
	mov	x1, x25
	mov	w2, #1
	blr	x8
	tbnz	w26, #31, LBB0_21
LBB0_16:
	sub	w8, w25, w23
	add	w27, w8, #1
	mov	x28, x27
	mov	x25, x20
LBB0_17:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x25
	bl	_le16_to_cpus
	add	x25, x25, #4
	subs	x28, x28, #1
	b.ne	LBB0_17
; %bb.18:
	ldr	w2, [x22, #8]
	mov	x0, x24
	mov	x1, x21
	bl	_memcpy
	mov	x21, x20
LBB0_19:                                ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x21]
	bl	_cpu_to_le16
	str	w0, [x21], #4
	subs	x27, x27, #1
	b.ne	LBB0_19
	b	LBB0_22
LBB0_20:
	sub	w26, w25, w23
	tbz	w26, #31, LBB0_16
LBB0_21:
	ldr	w2, [x22, #8]
	mov	x0, x24
	mov	x1, x21
	bl	_memcpy
LBB0_22:
	add	w2, w26, #1
	ldr	x8, [x19, #24]
	mov	x0, x19
	mov	x1, x23
	mov	x3, x20
	blr	x8
	mov	x21, x0
	cbnz	w0, LBB0_24
; %bb.23:
	ldr	x8, [x19, #32]
	mov	x0, x19
	blr	x8
LBB0_24:
	mov	x0, x20
	bl	_kfree
	b	LBB0_11
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
	.comm	_igc_i225,8,3                   ; @igc_i225
	.comm	_EFAULT,4,2                     ; @EFAULT
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_igc_set_eeprom
.subsections_via_symbols
