	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_st21nfca_hci_enable_se         ## -- Begin function st21nfca_hci_enable_se
	.p2align	4, 0x90
_st21nfca_hci_enable_se:                ## @st21nfca_hci_enable_se
	.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, %r15d
	movq	%rdi, %r14
	movq	_ST21NFCA_SE_MODE_ON@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_st21nfca_hci_control_se
	movl	%eax, %ebx
	movq	_ST21NFCA_ESE_HOST_ID@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_3
## %bb.1:
	movq	%r14, %rdi
	callq	_st21nfca_se_get_atr
	movq	_ST21NFCA_APDU_READER_GATE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_ST21NFCA_EVT_SE_SOFT_RESET@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	callq	_nfc_hci_send_event
	testl	%eax, %eax
	jns	LBB0_5
## %bb.2:
	movl	%eax, %ebx
	jmp	LBB0_6
LBB0_3:
	testl	%ebx, %ebx
	js	LBB0_4
LBB0_5:
	xorl	%ebx, %ebx
	jmp	LBB0_6
LBB0_4:
	movl	(%r14), %edi
	movl	%r15d, %esi
	callq	_nfc_remove_se
LBB0_6:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ST21NFCA_SE_MODE_ON,4,2        ## @ST21NFCA_SE_MODE_ON
	.comm	_ST21NFCA_ESE_HOST_ID,4,2       ## @ST21NFCA_ESE_HOST_ID
	.comm	_ST21NFCA_APDU_READER_GATE,4,2  ## @ST21NFCA_APDU_READER_GATE
	.comm	_ST21NFCA_EVT_SE_SOFT_RESET,4,2 ## @ST21NFCA_EVT_SE_SOFT_RESET
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_st21nfca_hci_enable_se         ; -- Begin function st21nfca_hci_enable_se
	.p2align	2
_st21nfca_hci_enable_se:                ; @st21nfca_hci_enable_se
	.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	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _ST21NFCA_SE_MODE_ON@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ST21NFCA_SE_MODE_ON@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	bl	_st21nfca_hci_control_se
Lloh3:
	adrp	x8, _ST21NFCA_ESE_HOST_ID@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ST21NFCA_ESE_HOST_ID@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_3
; %bb.1:
	mov	x0, x19
	bl	_st21nfca_se_get_atr
Lloh6:
	adrp	x8, _ST21NFCA_APDU_READER_GATE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ST21NFCA_APDU_READER_GATE@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
Lloh9:
	adrp	x8, _ST21NFCA_EVT_SE_SOFT_RESET@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ST21NFCA_EVT_SE_SOFT_RESET@GOTPAGEOFF]
Lloh11:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x3, #0
	mov	w4, #0
	bl	_nfc_hci_send_event
	tbz	w0, #31, LBB0_4
; %bb.2:
	mov	x20, x0
	b	LBB0_6
LBB0_3:
	mov	x20, x0
	tbnz	w0, #31, LBB0_5
LBB0_4:
	mov	w20, #0
	b	LBB0_6
LBB0_5:
	ldr	w0, [x19]
	mov	x1, x21
	bl	_nfc_remove_se
LBB0_6:
	mov	x0, x20
	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 AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_ST21NFCA_SE_MODE_ON,4,2        ; @ST21NFCA_SE_MODE_ON
	.comm	_ST21NFCA_ESE_HOST_ID,4,2       ; @ST21NFCA_ESE_HOST_ID
	.comm	_ST21NFCA_APDU_READER_GATE,4,2  ; @ST21NFCA_APDU_READER_GATE
	.comm	_ST21NFCA_EVT_SE_SOFT_RESET,4,2 ; @ST21NFCA_EVT_SE_SOFT_RESET
.subsections_via_symbols
