	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function eeprom_ptov
_eeprom_ptov:                           ## @eeprom_ptov
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
                                        ## kill: def $edx killed $edx def $rdx
	movl	%edi, %eax
	cmpl	$1023, %edi                     ## imm = 0x3FF
	ja	LBB0_2
## %bb.1:
	addl	$31744, %eax                    ## imm = 0x7C00
	popq	%rbp
	retq
LBB0_2:
	imull	%esi, %edx
	leal	1024(%rdx), %ecx
	cmpl	%eax, %ecx
	jbe	LBB0_4
## %bb.3:
	subl	%edx, %eax
	addl	$30720, %eax                    ## imm = 0x7800
	popq	%rbp
	retq
LBB0_4:
	movq	_EEPROMSIZE@GOTPCREL(%rip), %rcx
	cmpl	%eax, (%rcx)
	jbe	LBB0_6
## %bb.5:
	subl	%edx, %eax
	addl	$-1024, %eax                    ## imm = 0xFC00
	popq	%rbp
	retq
LBB0_6:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EEPROMSIZE,4,2                 ## @EEPROMSIZE
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_eeprom_ptov
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function eeprom_ptov
_eeprom_ptov:                           ; @eeprom_ptov
	.cfi_startproc
; %bb.0:
	cmp	w0, #1023
	b.hi	LBB0_2
; %bb.1:
	mov	w8, #31744
	add	w0, w0, w8
	ret
LBB0_2:
	mul	w8, w2, w1
	add	w9, w8, #1024
	cmp	w9, w0
	b.ls	LBB0_4
; %bb.3:
	mov	w9, #30720
	sub	w8, w0, w8
	add	w0, w8, w9
	ret
LBB0_4:
Lloh0:
	adrp	x9, _EEPROMSIZE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _EEPROMSIZE@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	cmp	w9, w0
	b.ls	LBB0_6
; %bb.5:
	sub	w8, w0, w8
	sub	w0, w8, #1024
	ret
LBB0_6:
Lloh3:
	adrp	x8, _EINVAL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w0, w8
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_EEPROMSIZE,4,2                 ; @EEPROMSIZE
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_eeprom_ptov
.subsections_via_symbols
