	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_gpio_output_pin
_set_gpio_output_pin:                   ## @set_gpio_output_pin
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	movl	%ebx, %eax
	andb	$-2, %al
	cmpb	$48, %al
	jne	LBB0_1
## %bb.2:
	movl	%edi, %r14d
	movq	_tb0219_lock@GOTPCREL(%rip), %r15
	movq	%r15, %rdi
	callq	_spin_lock_irqsave
	movq	_TB0219_GPIO_OUTPUT@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	callq	_tb0219_read
	movl	%eax, %esi
	btrl	%r14d, %esi
	btsl	%r14d, %eax
	cmpb	$48, %bl
	cmovnel	%eax, %esi
	movl	(%r12), %edi
	callq	_tb0219_write
	movq	%r15, %rdi
	callq	_spin_unlock_irqrestore
	xorl	%eax, %eax
	jmp	LBB0_3
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_3:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_tb0219_lock,4,2                ## @tb0219_lock
	.comm	_TB0219_GPIO_OUTPUT,4,2         ## @TB0219_GPIO_OUTPUT
	.no_dead_strip	_set_gpio_output_pin
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_gpio_output_pin
_set_gpio_output_pin:                   ; @set_gpio_output_pin
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	and	w8, w1, #0xfe
	cmp	w8, #48
	b.ne	LBB0_2
; %bb.1:
	mov	x19, x0
	and	w21, w1, #0xff
Lloh0:
	adrp	x20, _tb0219_lock@GOTPAGE
Lloh1:
	ldr	x20, [x20, _tb0219_lock@GOTPAGEOFF]
	mov	x0, x20
	bl	_spin_lock_irqsave
Lloh2:
	adrp	x22, _TB0219_GPIO_OUTPUT@GOTPAGE
Lloh3:
	ldr	x22, [x22, _TB0219_GPIO_OUTPUT@GOTPAGEOFF]
	ldr	w0, [x22]
	bl	_tb0219_read
	mov	w8, #1
	lsl	w8, w8, w19
	bic	w9, w0, w8
	orr	w8, w0, w8
	cmp	w21, #48
	csel	w1, w9, w8, eq
	ldr	w0, [x22]
	bl	_tb0219_write
	mov	x0, x20
	bl	_spin_unlock_irqrestore
	mov	w0, #0
	b	LBB0_3
LBB0_2:
Lloh4:
	adrp	x8, _EINVAL@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_3:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_tb0219_lock,4,2                ; @tb0219_lock
	.comm	_TB0219_GPIO_OUTPUT,4,2         ; @TB0219_GPIO_OUTPUT
	.no_dead_strip	_set_gpio_output_pin
.subsections_via_symbols
