	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dln2_gpio_request
_dln2_gpio_request:                     ## @dln2_gpio_request
	.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	$40, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	callq	_gpiochip_get_data
	movq	%rax, %r15
	movl	%r14d, %edi
	callq	_cpu_to_le16
	movq	%rax, -40(%rbp)
	movl	$16, -28(%rbp)
	movq	_DLN2_GPIO_PIN_ENABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_dln2_gpio_pin_cmd
	testl	%eax, %eax
	js	LBB0_9
## %bb.1:
	movl	4(%r15), %edi
	movq	_DLN2_GPIO_PIN_GET_DIRECTION@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-40(%rbp), %rdx
	leaq	-56(%rbp), %r8
	leaq	-28(%rbp), %r9
	movl	$8, %ecx
	callq	_dln2_transfer
	testl	%eax, %eax
	js	LBB0_9
## %bb.2:
	cmpl	$16, -28(%rbp)
	jb	LBB0_8
## %bb.3:
	movq	-40(%rbp), %rax
	cmpq	-56(%rbp), %rax
	jne	LBB0_8
## %bb.4:
	movl	-48(%rbp), %eax
	cmpl	$128, %eax
	je	LBB0_11
## %bb.5:
	cmpl	$129, %eax
	jne	LBB0_8
## %bb.6:
	movl	(%r15), %esi
	movl	%r14d, %edi
	callq	_clear_bit
	xorl	%ebx, %ebx
	jmp	LBB0_10
LBB0_9:
	movl	%eax, %ebx
	jmp	LBB0_10
LBB0_8:
	movq	_EPROTO@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	movq	_DLN2_GPIO_PIN_DISABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_dln2_gpio_pin_cmd
LBB0_10:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	movl	(%r15), %esi
	movl	%r14d, %edi
	callq	_set_bit
	xorl	%ebx, %ebx
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_DLN2_GPIO_PIN_ENABLE,4,2       ## @DLN2_GPIO_PIN_ENABLE
	.comm	_DLN2_GPIO_PIN_GET_DIRECTION,4,2 ## @DLN2_GPIO_PIN_GET_DIRECTION
	.comm	_EPROTO,4,2                     ## @EPROTO
	.comm	_DLN2_GPIO_PIN_DISABLE,4,2      ## @DLN2_GPIO_PIN_DISABLE
	.no_dead_strip	_dln2_gpio_request
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dln2_gpio_request
_dln2_gpio_request:                     ; @dln2_gpio_request
	.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	x19, x1
	bl	_gpiochip_get_data
	mov	x20, x0
	mov	x0, x19
	bl	_cpu_to_le16
	str	x0, [sp, #24]
	mov	w8, #16
	str	w8, [sp, #4]
Lloh0:
	adrp	x8, _DLN2_GPIO_PIN_ENABLE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DLN2_GPIO_PIN_ENABLE@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x20
	mov	x2, x19
	bl	_dln2_gpio_pin_cmd
	tbnz	w0, #31, LBB0_7
; %bb.1:
	ldr	w0, [x20, #4]
Lloh3:
	adrp	x8, _DLN2_GPIO_PIN_GET_DIRECTION@GOTPAGE
Lloh4:
	ldr	x8, [x8, _DLN2_GPIO_PIN_GET_DIRECTION@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	add	x2, sp, #24
	add	x4, sp, #8
	add	x5, sp, #4
	mov	w3, #8
	bl	_dln2_transfer
	tbnz	w0, #31, LBB0_7
; %bb.2:
	ldr	w8, [sp, #4]
	cmp	w8, #16
	b.lo	LBB0_8
; %bb.3:
	ldr	x8, [sp, #24]
	ldr	x9, [sp, #8]
	cmp	x8, x9
	b.ne	LBB0_8
; %bb.4:
	ldr	w8, [sp, #16]
	cmp	w8, #128
	b.eq	LBB0_10
; %bb.5:
	cmp	w8, #129
	b.ne	LBB0_8
; %bb.6:
	ldr	w1, [x20]
	mov	x0, x19
	bl	_clear_bit
	mov	w21, #0
	b	LBB0_9
LBB0_7:
	mov	x21, x0
	b	LBB0_9
LBB0_8:
Lloh6:
	adrp	x8, _EPROTO@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EPROTO@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w21, w8
Lloh9:
	adrp	x8, _DLN2_GPIO_PIN_DISABLE@GOTPAGE
Lloh10:
	ldr	x8, [x8, _DLN2_GPIO_PIN_DISABLE@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	x0, x20
	mov	x2, x19
	bl	_dln2_gpio_pin_cmd
LBB0_9:
	mov	x0, x21
	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
LBB0_10:
	ldr	w1, [x20]
	mov	x0, x19
	bl	_set_bit
	mov	w21, #0
	b	LBB0_9
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_DLN2_GPIO_PIN_ENABLE,4,2       ; @DLN2_GPIO_PIN_ENABLE
	.comm	_DLN2_GPIO_PIN_GET_DIRECTION,4,2 ; @DLN2_GPIO_PIN_GET_DIRECTION
	.comm	_EPROTO,4,2                     ; @EPROTO
	.comm	_DLN2_GPIO_PIN_DISABLE,4,2      ; @DLN2_GPIO_PIN_DISABLE
	.no_dead_strip	_dln2_gpio_request
.subsections_via_symbols
