	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fw_cfg_read_blob
_fw_cfg_read_blob:                      ## @fw_cfg_read_blob
	.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
	movq	%rcx, %r15
	movl	%edx, %ebx
	movq	%rsi, %r14
	movl	%edi, %r12d
	movl	$-1, -44(%rbp)
	movq	_ACPI_WAIT_FOREVER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-44(%rbp), %rsi
	callq	_acpi_acquire_global_lock
	movq	%rax, %r13
	movq	%rax, %rdi
	callq	_ACPI_FAILURE
	testq	%rax, %rax
	je	LBB0_3
## %bb.1:
	movq	_AE_NOT_CONFIGURED@GOTPCREL(%rip), %rax
	cmpq	(%rax), %r13
	je	LBB0_3
## %bb.2:
	leaq	L_.str(%rip), %rsi
	movl	$1, %edi
	callq	_WARN
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	xorl	%esi, %esi
	movq	%r15, %rdx
	callq	_memset
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subq	(%rax), %rbx
	movq	%rbx, %r15
	jmp	LBB0_7
LBB0_3:
	movq	_fw_cfg_dev_lock@GOTPCREL(%rip), %rdi
	callq	_mutex_lock
	movl	%r12d, %edi
	callq	_fw_cfg_sel_endianness
	testl	%ebx, %ebx
	jle	LBB0_6
## %bb.4:
	incl	%ebx
	movq	_fw_cfg_reg_data@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %edi
	callq	_ioread8
	decl	%ebx
	cmpl	$1, %ebx
	ja	LBB0_5
LBB0_6:
	movq	_fw_cfg_reg_data@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r14, %rsi
	movq	%r15, %rdx
	callq	_ioread8_rep
	movq	_fw_cfg_dev_lock@GOTPCREL(%rip), %rdi
	callq	_mutex_unlock
	movl	-44(%rbp), %edi
	callq	_acpi_release_global_lock
LBB0_7:
	movq	%r15, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ACPI_WAIT_FOREVER,4,2          ## @ACPI_WAIT_FOREVER
	.comm	_AE_NOT_CONFIGURED,8,3          ## @AE_NOT_CONFIGURED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"fw_cfg_read_blob: Failed to lock ACPI!\n"

	.comm	_EINVAL,8,3                     ## @EINVAL
	.comm	_fw_cfg_dev_lock,4,2            ## @fw_cfg_dev_lock
	.comm	_fw_cfg_reg_data,4,2            ## @fw_cfg_reg_data
	.no_dead_strip	_fw_cfg_read_blob
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fw_cfg_read_blob
_fw_cfg_read_blob:                      ; @fw_cfg_read_blob
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.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
	mov	x19, x3
	mov	x21, x2
	mov	x20, x1
	mov	x22, x0
	mov	w8, #-1
	str	w8, [sp, #12]
Lloh0:
	adrp	x8, _ACPI_WAIT_FOREVER@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ACPI_WAIT_FOREVER@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	add	x1, sp, #12
	bl	_acpi_acquire_global_lock
	mov	x23, x0
	bl	_ACPI_FAILURE
Lloh3:
	adrp	x8, _AE_NOT_CONFIGURED@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AE_NOT_CONFIGURED@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cmp	x0, #0
	ccmp	x23, x8, #4, ne
	b.ne	LBB0_5
; %bb.1:
Lloh6:
	adrp	x0, _fw_cfg_dev_lock@GOTPAGE
Lloh7:
	ldr	x0, [x0, _fw_cfg_dev_lock@GOTPAGEOFF]
	bl	_mutex_lock
	mov	x0, x22
	bl	_fw_cfg_sel_endianness
Lloh8:
	adrp	x22, _fw_cfg_reg_data@GOTPAGE
Lloh9:
	ldr	x22, [x22, _fw_cfg_reg_data@GOTPAGEOFF]
	cmp	w21, #1
	b.lt	LBB0_4
; %bb.2:
	add	w21, w21, #1
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x22]
	bl	_ioread8
	sub	w21, w21, #1
	cmp	w21, #1
	b.hi	LBB0_3
LBB0_4:
	ldr	w0, [x22]
	mov	x1, x20
	mov	x2, x19
	bl	_ioread8_rep
Lloh10:
	adrp	x0, _fw_cfg_dev_lock@GOTPAGE
Lloh11:
	ldr	x0, [x0, _fw_cfg_dev_lock@GOTPAGEOFF]
	bl	_mutex_unlock
	ldr	w0, [sp, #12]
	bl	_acpi_release_global_lock
	b	LBB0_6
LBB0_5:
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #1
	bl	_WARN
	mov	x0, x20
	mov	w1, #0
	mov	x2, x19
	bl	_memset
Lloh14:
	adrp	x8, _EINVAL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	neg	x19, x8
LBB0_6:
	mov	x0, x19
	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
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_ACPI_WAIT_FOREVER,4,2          ; @ACPI_WAIT_FOREVER
	.comm	_AE_NOT_CONFIGURED,8,3          ; @AE_NOT_CONFIGURED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"fw_cfg_read_blob: Failed to lock ACPI!\n"

	.comm	_EINVAL,8,3                     ; @EINVAL
	.comm	_fw_cfg_dev_lock,4,2            ; @fw_cfg_dev_lock
	.comm	_fw_cfg_reg_data,4,2            ; @fw_cfg_reg_data
	.no_dead_strip	_fw_cfg_read_blob
.subsections_via_symbols
