	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ingenic_pinconf_get
_ingenic_pinconf_get:                   ## @ingenic_pinconf_get
	.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	%rdx, %r14
	movl	%esi, %r15d
	callq	_pinctrl_dev_get_drvdata
	movq	%rax, %rbx
	movq	(%r14), %rdi
	callq	_pinconf_to_config_param
	movl	%eax, %r12d
	movq	_PINS_PER_GPIO_CHIP@GOTPCREL(%rip), %rcx
	movl	%r15d, %eax
	xorl	%edx, %edx
	divl	(%rcx)
	movl	%eax, %r13d
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movq	(%rbx), %rax
	movq	_ID_JZ4760@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jge	LBB0_1
## %bb.2:
	movq	_JZ4740_GPIO_PULL_DIS@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_1:
	movq	_JZ4760_GPIO_PEN@GOTPCREL(%rip), %rax
LBB0_3:
	movl	(%rax), %edx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	callq	_ingenic_get_pin_config
	cmpl	$128, %r12d
	je	LBB0_9
## %bb.4:
	cmpl	$129, %r12d
	je	LBB0_14
## %bb.5:
	cmpl	$130, %r12d
	jne	LBB0_16
## %bb.6:
	testl	%eax, %eax
	jne	LBB0_12
	jmp	LBB0_7
LBB0_9:
	testl	%eax, %eax
	jne	LBB0_7
## %bb.10:
	movq	8(%rbx), %rax
	movq	(%rax), %rax
	jmp	LBB0_11
LBB0_14:
	testl	%eax, %eax
	jne	LBB0_7
## %bb.15:
	movq	8(%rbx), %rax
	movq	8(%rax), %rax
LBB0_11:
	movl	%r13d, %ecx
	movl	(%rax,%rcx,4), %ebx
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	callq	_BIT
	testl	%ebx, %eax
	je	LBB0_7
LBB0_12:
	movl	%r12d, %edi
	movl	$1, %esi
	callq	_pinconf_to_config_packed
	movq	%rax, (%r14)
	xorl	%eax, %eax
	jmp	LBB0_13
LBB0_7:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	jmp	LBB0_8
LBB0_16:
	movq	_ENOTSUPP@GOTPCREL(%rip), %rcx
LBB0_8:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_13:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PINS_PER_GPIO_CHIP,4,2         ## @PINS_PER_GPIO_CHIP
	.comm	_ID_JZ4760,8,3                  ## @ID_JZ4760
	.comm	_JZ4760_GPIO_PEN,4,2            ## @JZ4760_GPIO_PEN
	.comm	_JZ4740_GPIO_PULL_DIS,4,2       ## @JZ4740_GPIO_PULL_DIS
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ENOTSUPP,4,2                   ## @ENOTSUPP
	.no_dead_strip	_ingenic_pinconf_get
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ingenic_pinconf_get
_ingenic_pinconf_get:                   ; @ingenic_pinconf_get
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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, x2
	mov	x23, x1
	bl	_pinctrl_dev_get_drvdata
	mov	x21, x0
	ldr	x0, [x19]
	bl	_pinconf_to_config_param
	mov	x20, x0
Lloh0:
	adrp	x8, _PINS_PER_GPIO_CHIP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PINS_PER_GPIO_CHIP@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	udiv	w24, w23, w8
	msub	w22, w24, w8, w23
	ldr	x8, [x21]
Lloh3:
	adrp	x9, _ID_JZ4760@GOTPAGE
Lloh4:
	ldr	x9, [x9, _ID_JZ4760@GOTPAGEOFF]
Lloh5:
	adrp	x10, _JZ4740_GPIO_PULL_DIS@GOTPAGE
Lloh6:
	ldr	x10, [x10, _JZ4740_GPIO_PULL_DIS@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
Lloh8:
	adrp	x11, _JZ4760_GPIO_PEN@GOTPAGE
Lloh9:
	ldr	x11, [x11, _JZ4760_GPIO_PEN@GOTPAGEOFF]
	cmp	x8, x9
	csel	x8, x10, x11, lt
	ldr	w2, [x8]
	mov	x0, x21
	mov	x1, x23
	bl	_ingenic_get_pin_config
	cmp	w20, #128
	b.eq	LBB0_4
; %bb.1:
	cmp	w20, #129
	b.eq	LBB0_6
; %bb.2:
	cmp	w20, #130
	b.ne	LBB0_11
; %bb.3:
	cbnz	w0, LBB0_9
	b	LBB0_10
LBB0_4:
	cbnz	w0, LBB0_10
; %bb.5:
	ldr	x8, [x21, #8]
	ldr	x8, [x8]
	b	LBB0_8
LBB0_6:
	cbnz	w0, LBB0_10
; %bb.7:
	ldr	x8, [x21, #8]
	ldr	x8, [x8, #8]
LBB0_8:
	ldr	w21, [x8, w24, uxtw #2]
	mov	x0, x22
	bl	_BIT
	tst	w0, w21
	b.eq	LBB0_10
LBB0_9:
	mov	x0, x20
	mov	w1, #1
	bl	_pinconf_to_config_packed
	mov	x8, x0
	mov	w0, #0
	str	x8, [x19]
	b	LBB0_13
LBB0_10:
Lloh10:
	adrp	x8, _EINVAL@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_12
LBB0_11:
Lloh12:
	adrp	x8, _ENOTSUPP@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ENOTSUPP@GOTPAGEOFF]
LBB0_12:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_13:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_PINS_PER_GPIO_CHIP,4,2         ; @PINS_PER_GPIO_CHIP
	.comm	_ID_JZ4760,8,3                  ; @ID_JZ4760
	.comm	_JZ4760_GPIO_PEN,4,2            ; @JZ4760_GPIO_PEN
	.comm	_JZ4740_GPIO_PULL_DIS,4,2       ; @JZ4740_GPIO_PULL_DIS
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ENOTSUPP,4,2                   ; @ENOTSUPP
	.no_dead_strip	_ingenic_pinconf_get
.subsections_via_symbols
