	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function alloc_resource_for_node
_alloc_resource_for_node:               ## @alloc_resource_for_node
	.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	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movq	%rsi, %r14
	movl	%edi, %ebx
	callq	_OF_parent
	leaq	-40(%rbp), %rdx
	leaq	-48(%rbp), %rcx
	movl	%eax, %edi
	xorl	%esi, %esi
	callq	_fdt_get_range
	testl	%eax, %eax
	jne	LBB0_3
## %bb.1:
	leaq	-32(%rbp), %rsi
	movl	%ebx, %edi
	movq	%r15, %rdx
	callq	_fdt_regsize
	testl	%eax, %eax
	jne	LBB0_3
## %bb.2:
	movq	-40(%rbp), %rax
	addq	%rax, -32(%rbp)
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	$8, %edx
	callq	_memset
	movq	_fdtbus_bs_tag@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%edi, 4(%r14)
	movq	-32(%rbp), %rsi
	movq	(%r15), %rdx
	xorl	%ecx, %ecx
	movq	%r14, %r8
	callq	_bus_space_map
LBB0_3:
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_fdtbus_bs_tag,4,2              ## @fdtbus_bs_tag
	.no_dead_strip	_alloc_resource_for_node
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function alloc_resource_for_node
_alloc_resource_for_node:               ; @alloc_resource_for_node
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x20, x2
	mov	x19, x1
	mov	x21, x0
	bl	_OF_parent
	add	x2, sp, #24
	add	x3, sp, #16
	mov	w1, #0
	bl	_fdt_get_range
	cbnz	w0, LBB0_3
; %bb.1:
	add	x1, sp, #8
	mov	x0, x21
	mov	x2, x20
	bl	_fdt_regsize
	cbnz	w0, LBB0_3
; %bb.2:
	ldr	x8, [sp, #24]
	ldr	x9, [sp, #8]
	add	x8, x9, x8
	str	x8, [sp, #8]
	mov	x0, x19
	mov	w1, #0
	mov	w2, #8
	bl	_memset
Lloh0:
	adrp	x8, _fdtbus_bs_tag@GOTPAGE
Lloh1:
	ldr	x8, [x8, _fdtbus_bs_tag@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	str	w0, [x19, #4]
	ldr	x1, [sp, #8]
	ldr	x2, [x20]
	mov	w3, #0
	mov	x4, x19
	bl	_bus_space_map
LBB0_3:
	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
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_fdtbus_bs_tag,4,2              ; @fdtbus_bs_tag
	.no_dead_strip	_alloc_resource_for_node
.subsections_via_symbols
