	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nvram_release
_nvram_release:                         ## @nvram_release
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rsi, %rbx
	movq	_nvram_state_lock@GOTPCREL(%rip), %rdi
	callq	_spin_lock
	movq	_nvram_open_cnt@GOTPCREL(%rip), %rax
	decl	(%rax)
	movq	_nvram_open_mode@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_NVRAM_EXCL@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	testl	%ecx, %edx
	je	LBB0_2
## %bb.1:
	notl	%edx
	andl	%edx, %ecx
	movl	%ecx, (%rax)
LBB0_2:
	movq	_FMODE_WRITE@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	testl	%edx, (%rbx)
	je	LBB0_4
## %bb.3:
	movq	_NVRAM_WRITE@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	notl	%edx
	andl	%edx, %ecx
	movl	%ecx, (%rax)
LBB0_4:
	movq	_nvram_state_lock@GOTPCREL(%rip), %rdi
	callq	_spin_unlock
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_nvram_state_lock,4,2           ## @nvram_state_lock
	.comm	_nvram_open_cnt,4,2             ## @nvram_open_cnt
	.comm	_nvram_open_mode,4,2            ## @nvram_open_mode
	.comm	_NVRAM_EXCL,4,2                 ## @NVRAM_EXCL
	.comm	_FMODE_WRITE,4,2                ## @FMODE_WRITE
	.comm	_NVRAM_WRITE,4,2                ## @NVRAM_WRITE
	.no_dead_strip	_nvram_release
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nvram_release
_nvram_release:                         ; @nvram_release
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x1
Lloh0:
	adrp	x0, _nvram_state_lock@GOTPAGE
Lloh1:
	ldr	x0, [x0, _nvram_state_lock@GOTPAGEOFF]
	bl	_spin_lock
Lloh2:
	adrp	x9, _nvram_open_cnt@GOTPAGE
Lloh3:
	ldr	x9, [x9, _nvram_open_cnt@GOTPAGEOFF]
	ldr	w8, [x9]
	sub	w10, w8, #1
Lloh4:
	adrp	x8, _nvram_open_mode@GOTPAGE
Lloh5:
	ldr	x8, [x8, _nvram_open_mode@GOTPAGEOFF]
	str	w10, [x9]
	ldr	w9, [x8]
Lloh6:
	adrp	x10, _NVRAM_EXCL@GOTPAGE
Lloh7:
	ldr	x10, [x10, _NVRAM_EXCL@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_2
; %bb.1:
	bic	w9, w9, w10
	str	w9, [x8]
LBB0_2:
	ldr	w10, [x19]
Lloh9:
	adrp	x11, _FMODE_WRITE@GOTPAGE
Lloh10:
	ldr	x11, [x11, _FMODE_WRITE@GOTPAGEOFF]
Lloh11:
	ldr	w11, [x11]
	tst	w11, w10
	b.eq	LBB0_4
; %bb.3:
Lloh12:
	adrp	x10, _NVRAM_WRITE@GOTPAGE
Lloh13:
	ldr	x10, [x10, _NVRAM_WRITE@GOTPAGEOFF]
Lloh14:
	ldr	w10, [x10]
	bic	w9, w9, w10
	str	w9, [x8]
LBB0_4:
Lloh15:
	adrp	x0, _nvram_state_lock@GOTPAGE
Lloh16:
	ldr	x0, [x0, _nvram_state_lock@GOTPAGEOFF]
	bl	_spin_unlock
	mov	w0, #0
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_nvram_state_lock,4,2           ; @nvram_state_lock
	.comm	_nvram_open_cnt,4,2             ; @nvram_open_cnt
	.comm	_nvram_open_mode,4,2            ; @nvram_open_mode
	.comm	_NVRAM_EXCL,4,2                 ; @NVRAM_EXCL
	.comm	_FMODE_WRITE,4,2                ; @FMODE_WRITE
	.comm	_NVRAM_WRITE,4,2                ; @NVRAM_WRITE
	.no_dead_strip	_nvram_release
.subsections_via_symbols
