	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bd2802_enable
_bd2802_enable:                         ## @bd2802_enable
	.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, %ebx
	movq	%rdi, %r14
	movq	_LED1@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	cmpl	%ebx, %esi
	jne	LBB0_2
## %bb.1:
	movq	_LED2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
LBB0_2:
	movq	%r14, %rdi
	callq	_bd2802_is_led_off
	xorl	%esi, %esi
	testl	%eax, %eax
	sete	%sil
	cmpl	%ebx, (%r15)
	jne	LBB0_4
## %bb.3:
	movl	%esi, %edi
	movl	$1, %esi
	jmp	LBB0_5
LBB0_4:
	movl	$1, %edi
LBB0_5:
	callq	_LED_CTL
	movl	(%r14), %edi
	movq	_BD2802_REG_CONTROL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	%eax, %edx
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_bd2802_write_byte              ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_LED1,4,2                       ## @LED1
	.comm	_LED2,4,2                       ## @LED2
	.comm	_BD2802_REG_CONTROL,4,2         ## @BD2802_REG_CONTROL
	.no_dead_strip	_bd2802_enable
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bd2802_enable
_bd2802_enable:                         ; @bd2802_enable
	.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
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x21, _LED1@GOTPAGE
Lloh1:
	ldr	x21, [x21, _LED1@GOTPAGEOFF]
	ldr	w8, [x21]
Lloh2:
	adrp	x9, _LED2@GOTPAGE
Lloh3:
	ldr	x9, [x9, _LED2@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	cmp	w8, w1
	csel	w1, w9, w8, eq
	bl	_bd2802_is_led_off
	cmp	w0, #0
	cset	w1, eq
	ldr	w8, [x21]
	cmp	w8, w20
	b.ne	LBB0_2
; %bb.1:
	mov	x0, x1
	mov	w1, #1
	b	LBB0_3
LBB0_2:
	mov	w0, #1
LBB0_3:
	bl	_LED_CTL
	mov	x2, x0
	ldr	w0, [x19]
Lloh5:
	adrp	x8, _BD2802_REG_CONTROL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _BD2802_REG_CONTROL@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	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
	b	_bd2802_write_byte
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_LED1,4,2                       ; @LED1
	.comm	_LED2,4,2                       ; @LED2
	.comm	_BD2802_REG_CONTROL,4,2         ; @BD2802_REG_CONTROL
	.no_dead_strip	_bd2802_enable
.subsections_via_symbols
