	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function st21nfca_hci_platform_init
_st21nfca_hci_platform_init:            ## @st21nfca_hci_platform_init
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	%rsp, %r13
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movl	l___const.st21nfca_hci_platform_init.wait_reboot+8(%rip), %eax
	movl	%eax, -56(%rbp)
	movq	l___const.st21nfca_hci_platform_init.wait_reboot(%rip), %rax
	movq	%rax, -64(%rbp)
	movb	$126, -68(%rbp)
	movl	$-163027330, -72(%rbp)          ## imm = 0xF648667E
	movq	_ST21NFCA_HCI_LLC_MAX_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	shlq	$3, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, -88(%rbp)                 ## 8-byte Spill
	leaq	-64(%rbp), %rdi
	callq	_ARRAY_SIZE
	movl	$-1, %r15d
	testl	%eax, %eax
	jle	LBB0_18
## %bb.1:
	movq	%r13, -80(%rbp)                 ## 8-byte Spill
	movl	$1, %r12d
	leaq	-64(%rbp), %r13
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r14), %edi
	leaq	-72(%rbp), %rsi
	movl	$5, %edx
	callq	_i2c_master_send
	movl	%eax, %ebx
	testl	%eax, %eax
	jns	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	-68(%rbp,%r12,4), %edi
	callq	_msleep
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	%r13, %rdi
	callq	_ARRAY_SIZE
	cltq
	cmpq	%rax, %r12
	jge	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	incq	%r12
	testl	%ebx, %ebx
	js	LBB0_2
LBB0_6:
	testl	%ebx, %ebx
	js	LBB0_7
## %bb.8:
	movl	$20, %edi
	callq	_msleep
	leaq	-64(%rbp), %rdi
	callq	_ARRAY_SIZE
	testl	%eax, %eax
	movq	-80(%rbp), %r13                 ## 8-byte Reload
	jle	LBB0_18
## %bb.9:
	movl	$1, %ebx
	leaq	-64(%rbp), %r12
	.p2align	4, 0x90
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r14), %edi
	movq	_ST21NFCA_HCI_LLC_MAX_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	-88(%rbp), %rsi                 ## 8-byte Reload
	callq	_i2c_master_recv
	movl	%eax, %r15d
	testl	%eax, %eax
	jns	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=1
	movl	-68(%rbp,%rbx,4), %edi
	callq	_msleep
LBB0_12:                                ##   in Loop: Header=BB0_10 Depth=1
	movq	%r12, %rdi
	callq	_ARRAY_SIZE
	cltq
	cmpq	%rax, %rbx
	jge	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_10 Depth=1
	incq	%rbx
	testl	%r15d, %r15d
	js	LBB0_10
LBB0_14:
	testl	%r15d, %r15d
	js	LBB0_18
## %bb.15:
	movq	_ST21NFCA_HCI_LLC_MAX_SIZE@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r15d
	jne	LBB0_16
## %bb.17:
	movl	$1000, %edi                     ## imm = 0x3E8
	movl	$1500, %esi                     ## imm = 0x5DC
	callq	_usleep_range
	xorl	%r15d, %r15d
	jmp	LBB0_18
LBB0_7:
	movl	%ebx, %r15d
	movq	-80(%rbp), %r13                 ## 8-byte Reload
	jmp	LBB0_18
LBB0_16:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
LBB0_18:
	movq	%r13, %rsp
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_20
## %bb.19:
	movl	%r15d, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_20:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__const
	.p2align	2                               ## @__const.st21nfca_hci_platform_init.wait_reboot
l___const.st21nfca_hci_platform_init.wait_reboot:
	.long	50                              ## 0x32
	.long	300                             ## 0x12c
	.long	1000                            ## 0x3e8

l___const.st21nfca_hci_platform_init.reboot_cmd: ## @__const.st21nfca_hci_platform_init.reboot_cmd
	.ascii	"~fH\366~"

	.comm	_ST21NFCA_HCI_LLC_MAX_SIZE,4,2  ## @ST21NFCA_HCI_LLC_MAX_SIZE
	.comm	_ST21NFCA_SOF_EOF,8,3           ## @ST21NFCA_SOF_EOF
	.comm	_ENODEV,4,2                     ## @ENODEV
	.no_dead_strip	_st21nfca_hci_platform_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function st21nfca_hci_platform_init
_st21nfca_hci_platform_init:            ; @st21nfca_hci_platform_init
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	sub	sp, sp, #32
	mov	x19, x0
	mov	x22, sp
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
Lloh3:
	adrp	x9, l___const.st21nfca_hci_platform_init.wait_reboot@PAGE
Lloh4:
	add	x9, x9, l___const.st21nfca_hci_platform_init.wait_reboot@PAGEOFF
	stur	x8, [x29, #-72]
	ldr	x8, [x9]
	stur	x8, [x29, #-88]
	ldr	w8, [x9, #8]
	stur	w8, [x29, #-80]
	mov	w8, #126
	sturb	w8, [x29, #-92]
	mov	w8, #26238
	movk	w8, #63048, lsl #16
	stur	w8, [x29, #-96]
Lloh5:
	adrp	x23, _ST21NFCA_HCI_LLC_MAX_SIZE@GOTPAGE
Lloh6:
	ldr	x23, [x23, _ST21NFCA_HCI_LLC_MAX_SIZE@GOTPAGEOFF]
	ldr	w8, [x23]
	lsl	x8, x8, #3
	mov	x9, x8
Lloh7:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh8:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0xffffffff0
	sub	x20, x9, x8
	mov	sp, x20
	sub	x24, x29, #88
	sub	x0, x29, #88
	bl	_ARRAY_SIZE
	cmp	w0, #1
	b.lt	LBB0_16
; %bb.1:
	mov	x25, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x19]
	sub	x1, x29, #96
	mov	w2, #5
	bl	_i2c_master_send
	mov	x21, x0
	tbz	w0, #31, LBB0_4
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	w0, [x24, x25, lsl #2]
	bl	_msleep
LBB0_4:                                 ;   in Loop: Header=BB0_2 Depth=1
	add	x25, x25, #1
	sub	x0, x29, #88
	bl	_ARRAY_SIZE
	cmp	x25, w0, sxtw
	b.ge	LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_2 Depth=1
	tbnz	w21, #31, LBB0_2
LBB0_6:
	tbnz	w21, #31, LBB0_17
; %bb.7:
	mov	w0, #20
	bl	_msleep
	sub	x24, x29, #88
	sub	x0, x29, #88
	bl	_ARRAY_SIZE
	cmp	w0, #1
	b.lt	LBB0_16
; %bb.8:
	mov	x25, #0
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x19]
	ldr	w2, [x23]
	mov	x1, x20
	bl	_i2c_master_recv
	mov	x21, x0
	tbz	w0, #31, LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w0, [x24, x25, lsl #2]
	bl	_msleep
LBB0_11:                                ;   in Loop: Header=BB0_9 Depth=1
	add	x25, x25, #1
	sub	x0, x29, #88
	bl	_ARRAY_SIZE
	cmp	x25, w0, sxtw
	b.ge	LBB0_13
; %bb.12:                               ;   in Loop: Header=BB0_9 Depth=1
	tbnz	w21, #31, LBB0_9
LBB0_13:
	tbnz	w21, #31, LBB0_17
; %bb.14:
	ldr	w8, [x23]
	cmp	w21, w8
	b.ne	LBB0_19
; %bb.15:
	mov	w0, #1000
	mov	w1, #1500
	bl	_usleep_range
	mov	w21, #0
	b	LBB0_17
LBB0_16:
	mov	w21, #-1
LBB0_17:
	mov	sp, x22
	ldur	x8, [x29, #-72]
Lloh9:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh10:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_20
; %bb.18:
	mov	x0, x21
	sub	sp, x29, #64
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_19:
Lloh12:
	adrp	x8, _ENODEV@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_17
LBB0_20:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__const
	.p2align	2                               ; @__const.st21nfca_hci_platform_init.wait_reboot
l___const.st21nfca_hci_platform_init.wait_reboot:
	.long	50                              ; 0x32
	.long	300                             ; 0x12c
	.long	1000                            ; 0x3e8

l___const.st21nfca_hci_platform_init.reboot_cmd: ; @__const.st21nfca_hci_platform_init.reboot_cmd
	.ascii	"~fH\366~"

	.comm	_ST21NFCA_HCI_LLC_MAX_SIZE,4,2  ; @ST21NFCA_HCI_LLC_MAX_SIZE
	.comm	_ST21NFCA_SOF_EOF,8,3           ; @ST21NFCA_SOF_EOF
	.comm	_ENODEV,4,2                     ; @ENODEV
	.no_dead_strip	_st21nfca_hci_platform_init
.subsections_via_symbols
