	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tps68470_gpio_get_direction
_tps68470_gpio_get_direction:           ## @tps68470_gpio_get_direction
	.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
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	callq	_gpiochip_get_data
	movq	%rax, %r15
	movq	_TPS68470_N_REGULAR_GPIO@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	cmpl	%r14d, (%rax)
	jbe	LBB0_4
## %bb.1:
	movq	8(%r15), %rbx
	movl	%r14d, %edi
	callq	_TPS68470_GPIO_CTL_REG_A
	leaq	-28(%rbp), %rdx
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_regmap_read
	testl	%eax, %eax
	je	LBB0_3
## %bb.2:
	movl	%eax, %ebx
	movl	(%r15), %r15d
	movl	%r14d, %edi
	callq	_TPS68470_GPIO_CTL_REG_A
	leaq	L_.str(%rip), %rsi
	movl	%r15d, %edi
	movl	%eax, %edx
	callq	_dev_err
	jmp	LBB0_4
LBB0_3:
	movq	_TPS68470_GPIO_MODE_MASK@GOTPCREL(%rip), %rax
	movl	-28(%rbp), %ecx
	andl	(%rax), %ecx
	movq	_TPS68470_GPIO_MODE_OUT_CMOS@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	cmpl	(%rax), %ecx
	setl	%bl
LBB0_4:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_TPS68470_N_REGULAR_GPIO,4,2    ## @TPS68470_N_REGULAR_GPIO
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"reg 0x%x read failed\n"

	.comm	_TPS68470_GPIO_MODE_MASK,4,2    ## @TPS68470_GPIO_MODE_MASK
	.comm	_TPS68470_GPIO_MODE_OUT_CMOS,4,2 ## @TPS68470_GPIO_MODE_OUT_CMOS
	.no_dead_strip	_tps68470_gpio_get_direction
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tps68470_gpio_get_direction
_tps68470_gpio_get_direction:           ; @tps68470_gpio_get_direction
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x1
	bl	_gpiochip_get_data
Lloh0:
	adrp	x8, _TPS68470_N_REGULAR_GPIO@GOTPAGE
Lloh1:
	ldr	x8, [x8, _TPS68470_N_REGULAR_GPIO@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w19
	b.ls	LBB0_3
; %bb.1:
	mov	x21, x0
	ldr	x20, [x0, #8]
	mov	x0, x19
	bl	_TPS68470_GPIO_CTL_REG_A
	mov	x1, x0
	add	x2, sp, #12
	mov	x0, x20
	bl	_regmap_read
	cbz	w0, LBB0_4
; %bb.2:
	mov	x20, x0
	ldr	w21, [x21]
	mov	x0, x19
	bl	_TPS68470_GPIO_CTL_REG_A
	mov	x2, x0
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x21
	bl	_dev_err
	b	LBB0_5
LBB0_3:
	mov	w20, #0
	b	LBB0_5
LBB0_4:
Lloh5:
	adrp	x8, _TPS68470_GPIO_MODE_MASK@GOTPAGE
Lloh6:
	ldr	x8, [x8, _TPS68470_GPIO_MODE_MASK@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	ldr	w9, [sp, #12]
	and	w8, w9, w8
Lloh8:
	adrp	x9, _TPS68470_GPIO_MODE_OUT_CMOS@GOTPAGE
Lloh9:
	ldr	x9, [x9, _TPS68470_GPIO_MODE_OUT_CMOS@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	cmp	w8, w9
	cset	w20, lt
LBB0_5:
	mov	x0, x20
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_TPS68470_N_REGULAR_GPIO,4,2    ; @TPS68470_N_REGULAR_GPIO
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"reg 0x%x read failed\n"

	.comm	_TPS68470_GPIO_MODE_MASK,4,2    ; @TPS68470_GPIO_MODE_MASK
	.comm	_TPS68470_GPIO_MODE_OUT_CMOS,4,2 ; @TPS68470_GPIO_MODE_OUT_CMOS
	.no_dead_strip	_tps68470_gpio_get_direction
.subsections_via_symbols
