	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bcm2835_pctl_dt_node_to_map
_bcm2835_pctl_dt_node_to_map:           ## @bcm2835_pctl_dt_node_to_map
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r12
	movq	%rdx, %r13
	movq	%rsi, %r15
	movq	%rdi, %r14
	callq	_pinctrl_dev_get_drvdata
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%r13, %rdx
	movq	%r12, %rcx
	callq	_pinconf_generic_dt_node_to_map_all
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_21
## %bb.1:
	xorl	%ebx, %ebx
	cmpl	$0, (%r12)
	jne	LBB0_21
## %bb.2:
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_of_find_property
	testq	%rax, %rax
	je	LBB0_8
## %bb.3:
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	leaq	L_.str.2(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_of_find_property
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	leaq	L_.str.3(%rip), %rsi
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_of_find_property
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	movq	%rdx, %rcx
	orq	%rax, %rcx
	je	LBB0_9
## %bb.4:
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movl	(%rcx), %edi
	leal	3(%rdi), %ecx
	testl	%edi, %edi
	cmovnsl	%edi, %ecx
	testq	%rdx, %rdx
	je	LBB0_6
## %bb.5:
	movl	(%rdx), %edx
	leal	3(%rdx), %ebx
	testl	%edx, %edx
	cmovnsl	%edx, %ebx
	sarl	$2, %ebx
LBB0_6:
	testq	%rax, %rax
	je	LBB0_11
## %bb.7:
	movl	(%rax), %eax
	leal	3(%rax), %esi
	testl	%eax, %eax
	cmovnsl	%eax, %esi
	sarl	$2, %esi
	jmp	LBB0_12
LBB0_8:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_10
LBB0_9:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	leaq	L_.str.4(%rip), %rsi
LBB0_10:
	movq	%r15, %rdx
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_19
LBB0_11:
	xorl	%esi, %esi
LBB0_12:
	sarl	$2, %ecx
	cmpl	$2, %ebx
	jl	LBB0_15
## %bb.13:
	cmpl	%ecx, %ebx
	je	LBB0_15
## %bb.14:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	leaq	L_.str.5(%rip), %rsi
	jmp	LBB0_18
LBB0_15:
	cmpl	$2, %esi
	jl	LBB0_22
## %bb.16:
	cmpl	%ecx, %esi
	je	LBB0_22
## %bb.17:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	leaq	L_.str.6(%rip), %rsi
LBB0_18:
	xorl	%ebx, %ebx
	movq	%r15, %rdx
	xorl	%eax, %eax
	callq	_dev_err
LBB0_19:
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_20:
	subl	(%rax), %ebx
LBB0_21:
	movl	%ebx, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_22:
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	xorl	%eax, %eax
	xorl	%edx, %edx
	testl	%ebx, %ebx
	sete	%al
	setne	%dl
	movl	$2, %edi
	subl	%eax, %edi
	movl	%esi, -88(%rbp)                 ## 4-byte Spill
	testl	%esi, %esi
	cmovel	%edx, %edi
	movl	%ecx, -84(%rbp)                 ## 4-byte Spill
	imull	%ecx, %edi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%edi, -68(%rbp)                 ## 4-byte Spill
	movl	$4, %esi
	callq	_kcalloc
	movq	%rax, -112(%rbp)
	testq	%rax, %rax
	je	LBB0_35
## %bb.23:
	movq	%rax, -104(%rbp)                ## 8-byte Spill
	cmpl	$4, -56(%rbp)                   ## 4-byte Folded Reload
	jl	LBB0_36
## %bb.24:
	xorl	%edx, %edx
	jmp	LBB0_26
LBB0_25:                                ##   in Loop: Header=BB0_26 Depth=1
	movl	-56(%rbp), %edx                 ## 4-byte Reload
	incl	%edx
	cmpl	%edx, -84(%rbp)                 ## 4-byte Folded Reload
	je	LBB0_36
LBB0_26:                                ## =>This Inner Loop Header: Depth=1
	movq	%r15, %rdi
	leaq	L_.str(%rip), %rsi
	movl	%edx, -56(%rbp)                 ## 4-byte Spill
	leaq	-44(%rbp), %rcx
	callq	_of_property_read_u32_index
	testl	%eax, %eax
	jne	LBB0_41
## %bb.27:                              ##   in Loop: Header=BB0_26 Depth=1
	movl	-44(%rbp), %eax
	movl	%eax, -80(%rbp)                 ## 4-byte Spill
	movq	_bcm2835_gpio_pins@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_ARRAY_SIZE
	cmpl	%eax, -80(%rbp)                 ## 4-byte Folded Reload
	jge	LBB0_38
## %bb.28:                              ##   in Loop: Header=BB0_26 Depth=1
	testl	%ebx, %ebx
	je	LBB0_31
## %bb.29:                              ##   in Loop: Header=BB0_26 Depth=1
	cmpl	$2, %ebx
	movl	$0, %edx
	cmovgel	-56(%rbp), %edx                 ## 4-byte Folded Reload
	movq	%r15, %rdi
	leaq	L_.str.2(%rip), %rsi
	leaq	-96(%rbp), %rcx
	callq	_of_property_read_u32_index
	testl	%eax, %eax
	jne	LBB0_41
## %bb.30:                              ##   in Loop: Header=BB0_26 Depth=1
	movl	-44(%rbp), %edx
	movl	-96(%rbp), %ecx
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	%r15, %rsi
	leaq	-112(%rbp), %r8
	callq	_bcm2835_pctl_dt_node_to_map_func
	testl	%eax, %eax
	jne	LBB0_41
LBB0_31:                                ##   in Loop: Header=BB0_26 Depth=1
	movl	-88(%rbp), %eax                 ## 4-byte Reload
	testl	%eax, %eax
	je	LBB0_25
## %bb.32:                              ##   in Loop: Header=BB0_26 Depth=1
	cmpl	$2, %eax
	movl	$0, %edx
	cmovgel	-56(%rbp), %edx                 ## 4-byte Folded Reload
	movq	%r15, %rdi
	leaq	L_.str.3(%rip), %rsi
	leaq	-92(%rbp), %rcx
	callq	_of_property_read_u32_index
	testl	%eax, %eax
	jne	LBB0_41
## %bb.33:                              ##   in Loop: Header=BB0_26 Depth=1
	movl	-44(%rbp), %edx
	movl	-92(%rbp), %ecx
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	%r15, %rsi
	leaq	-112(%rbp), %r8
	callq	_bcm2835_pctl_dt_node_to_map_pull
	testl	%eax, %eax
	je	LBB0_25
LBB0_41:
	movl	%eax, %ebx
	jmp	LBB0_42
LBB0_35:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	jmp	LBB0_20
LBB0_36:
	movq	-104(%rbp), %rax                ## 8-byte Reload
	movq	%rax, (%r13)
	movl	-68(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, (%r12)
	xorl	%ebx, %ebx
	jmp	LBB0_21
LBB0_38:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	movl	-44(%rbp), %ecx
	leaq	L_.str.7(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r15, %rdx
	xorl	%eax, %eax
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
LBB0_42:
	movq	%r14, %rdi
	movq	-104(%rbp), %rsi                ## 8-byte Reload
	movl	-68(%rbp), %edx                 ## 4-byte Reload
	callq	_bcm2835_pctl_dt_free_map
	jmp	LBB0_21
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"brcm,pins"

L_.str.1:                               ## @.str.1
	.asciz	"%pOF: missing brcm,pins property\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.2:                               ## @.str.2
	.asciz	"brcm,function"

L_.str.3:                               ## @.str.3
	.asciz	"brcm,pull"

L_.str.4:                               ## @.str.4
	.asciz	"%pOF: neither brcm,function nor brcm,pull specified\n"

L_.str.5:                               ## @.str.5
	.asciz	"%pOF: brcm,function must have 1 or %d entries\n"

L_.str.6:                               ## @.str.6
	.asciz	"%pOF: brcm,pull must have 1 or %d entries\n"

	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_bcm2835_gpio_pins,4,2          ## @bcm2835_gpio_pins
L_.str.7:                               ## @.str.7
	.asciz	"%pOF: invalid brcm,pins value %d\n"

	.no_dead_strip	_bcm2835_pctl_dt_node_to_map
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bcm2835_pctl_dt_node_to_map
_bcm2835_pctl_dt_node_to_map:           ; @bcm2835_pctl_dt_node_to_map
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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, x3
	mov	x22, x2
	mov	x20, x1
	mov	x19, x0
	bl	_pinctrl_dev_get_drvdata
	mov	x23, x0
	mov	x0, x19
	mov	x1, x20
	mov	x2, x22
	mov	x3, x21
	bl	_pinconf_generic_dt_node_to_map_all
	mov	x28, x0
	cbnz	w0, LBB0_20
; %bb.1:
	ldr	w8, [x21]
	cbz	w8, LBB0_3
; %bb.2:
	mov	w28, #0
	b	LBB0_20
LBB0_3:
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	mov	x2, #0
	bl	_of_find_property
	cbz	x0, LBB0_8
; %bb.4:
	mov	x24, x0
Lloh2:
	adrp	x1, l_.str.2@PAGE
Lloh3:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	mov	x2, #0
	bl	_of_find_property
	mov	x25, x0
Lloh4:
	adrp	x1, l_.str.3@PAGE
Lloh5:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x20
	mov	x2, #0
	bl	_of_find_property
	orr	x8, x25, x0
	cbz	x8, LBB0_9
; %bb.5:
	ldr	w26, [x24]
	add	w8, w26, #3
	cmp	w26, #0
	csel	w8, w8, w26, lt
	cbz	x25, LBB0_10
; %bb.6:
	ldr	w9, [x25]
	add	w10, w9, #3
	cmp	w9, #0
	csel	w9, w10, w9, lt
	asr	w27, w9, #2
	cbz	x0, LBB0_11
LBB0_7:
	ldr	w9, [x0]
	add	w10, w9, #3
	cmp	w9, #0
	csel	w9, w10, w9, lt
	asr	w25, w9, #2
	b	LBB0_12
LBB0_8:
	ldr	w0, [x23]
Lloh6:
	adrp	x1, l_.str.1@PAGE
Lloh7:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_18
LBB0_9:
	ldr	w0, [x23]
Lloh8:
	adrp	x1, l_.str.4@PAGE
Lloh9:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_18
LBB0_10:
	mov	w27, #0
	cbnz	x0, LBB0_7
LBB0_11:
	mov	w25, #0
LBB0_12:
	asr	w24, w8, #2
	cmp	w27, #2
	b.lt	LBB0_15
; %bb.13:
	cmp	w27, w24
	b.eq	LBB0_15
; %bb.14:
	ldr	w0, [x23]
	str	x24, [sp]
Lloh10:
	adrp	x1, l_.str.5@PAGE
Lloh11:
	add	x1, x1, l_.str.5@PAGEOFF
	b	LBB0_18
LBB0_15:
	cmp	w25, #2
	b.lt	LBB0_21
; %bb.16:
	cmp	w25, w24
	b.eq	LBB0_21
; %bb.17:
	ldr	w0, [x23]
                                        ; kill: def $w24 killed $w24 killed $x24 def $x24
	str	x24, [sp]
Lloh12:
	adrp	x1, l_.str.6@PAGE
Lloh13:
	add	x1, x1, l_.str.6@PAGEOFF
LBB0_18:
	mov	x2, x20
	bl	_dev_err
Lloh14:
	adrp	x8, _EINVAL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_19:
	ldr	w8, [x8]
	neg	w28, w8
LBB0_20:
	mov	x0, x28
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
LBB0_21:
	cmp	w27, #0
	cset	w8, ne
	mov	w9, #1
	cinc	w9, w9, ne
	cmp	w25, #0
	csel	w8, w8, w9, eq
	mul	w28, w8, w24
Lloh16:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh17:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh18:
	ldr	w2, [x8]
	mov	x0, x28
	mov	w1, #4
	bl	_kcalloc
	str	x0, [sp, #40]
	cbz	x0, LBB0_34
; %bb.22:
	str	x0, [sp, #16]                   ; 8-byte Folded Spill
	str	w28, [sp, #24]                  ; 4-byte Folded Spill
	cmp	w26, #4
	b.lt	LBB0_35
; %bb.23:
	mov	w26, #0
	b	LBB0_25
LBB0_24:                                ;   in Loop: Header=BB0_25 Depth=1
	add	w26, w26, #1
	cmp	w24, w26
	b.eq	LBB0_35
LBB0_25:                                ; =>This Inner Loop Header: Depth=1
	add	x3, sp, #36
	mov	x0, x20
Lloh19:
	adrp	x1, l_.str@PAGE
Lloh20:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x26
	bl	_of_property_read_u32_index
	cbnz	w0, LBB0_33
; %bb.26:                               ;   in Loop: Header=BB0_25 Depth=1
	ldr	w28, [sp, #36]
Lloh21:
	adrp	x8, _bcm2835_gpio_pins@GOTPAGE
Lloh22:
	ldr	x8, [x8, _bcm2835_gpio_pins@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	bl	_ARRAY_SIZE
	cmp	w28, w0
	b.ge	LBB0_36
; %bb.27:                               ;   in Loop: Header=BB0_25 Depth=1
	cbz	w27, LBB0_30
; %bb.28:                               ;   in Loop: Header=BB0_25 Depth=1
	cmp	w27, #1
	csel	w2, w26, wzr, gt
	add	x3, sp, #32
	mov	x0, x20
Lloh24:
	adrp	x1, l_.str.2@PAGE
Lloh25:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_of_property_read_u32_index
	cbnz	w0, LBB0_33
; %bb.29:                               ;   in Loop: Header=BB0_25 Depth=1
	ldp	w3, w2, [sp, #32]
	add	x4, sp, #40
	mov	x0, x23
	mov	x1, x20
	bl	_bcm2835_pctl_dt_node_to_map_func
	cbnz	w0, LBB0_33
LBB0_30:                                ;   in Loop: Header=BB0_25 Depth=1
	cbz	w25, LBB0_24
; %bb.31:                               ;   in Loop: Header=BB0_25 Depth=1
	cmp	w25, #1
	csel	w2, w26, wzr, gt
	add	x3, sp, #28
	mov	x0, x20
Lloh26:
	adrp	x1, l_.str.3@PAGE
Lloh27:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_of_property_read_u32_index
	cbnz	w0, LBB0_33
; %bb.32:                               ;   in Loop: Header=BB0_25 Depth=1
	ldr	w2, [sp, #36]
	ldr	w3, [sp, #28]
	add	x4, sp, #40
	mov	x0, x23
	mov	x1, x20
	bl	_bcm2835_pctl_dt_node_to_map_pull
	cbz	w0, LBB0_24
LBB0_33:
	mov	x28, x0
	b	LBB0_37
LBB0_34:
Lloh28:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh29:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_19
LBB0_35:
	mov	w28, #0
	ldr	x8, [sp, #16]                   ; 8-byte Folded Reload
	str	x8, [x22]
	ldr	w8, [sp, #24]                   ; 4-byte Folded Reload
	str	w8, [x21]
	b	LBB0_20
LBB0_36:
	ldr	w0, [x23]
	ldr	w8, [sp, #36]
	str	x8, [sp]
Lloh30:
	adrp	x1, l_.str.7@PAGE
Lloh31:
	add	x1, x1, l_.str.7@PAGEOFF
	mov	x2, x20
	bl	_dev_err
Lloh32:
	adrp	x8, _EINVAL@GOTPAGE
Lloh33:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh34:
	ldr	w8, [x8]
	neg	w28, w8
LBB0_37:
	mov	x0, x19
	ldr	x1, [sp, #16]                   ; 8-byte Folded Reload
	ldr	w2, [sp, #24]                   ; 4-byte Folded Reload
	bl	_bcm2835_pctl_dt_free_map
	b	LBB0_20
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh30, Lloh31
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"brcm,pins"

l_.str.1:                               ; @.str.1
	.asciz	"%pOF: missing brcm,pins property\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.2:                               ; @.str.2
	.asciz	"brcm,function"

l_.str.3:                               ; @.str.3
	.asciz	"brcm,pull"

l_.str.4:                               ; @.str.4
	.asciz	"%pOF: neither brcm,function nor brcm,pull specified\n"

l_.str.5:                               ; @.str.5
	.asciz	"%pOF: brcm,function must have 1 or %d entries\n"

l_.str.6:                               ; @.str.6
	.asciz	"%pOF: brcm,pull must have 1 or %d entries\n"

	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_bcm2835_gpio_pins,4,2          ; @bcm2835_gpio_pins
l_.str.7:                               ; @.str.7
	.asciz	"%pOF: invalid brcm,pins value %d\n"

	.no_dead_strip	_bcm2835_pctl_dt_node_to_map
.subsections_via_symbols
