	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function process_link_key_notification_event
_process_link_key_notification_event:   ## @process_link_key_notification_event
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	_LOG_DEBUG@GOTPCREL(%rip), %r13
	movl	(%r13), %ebx
	movl	(%rsi), %r12d
	leaq	4(%rdx), %r15
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_bt_ntoa
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edi
	movl	%r12d, %edx
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_syslog
	movq	%r15, %rdi
	movl	$1, %esi
	callq	_get_key
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	movl	(%r13), %r12d
	movq	%rax, %rdi
	addq	$16, %rdi
	xorl	%r15d, %r15d
	xorl	%esi, %esi
	callq	_bt_ntoa
	movq	(%rbx), %rdx
	testq	%rdx, %rdx
	leaq	L_.str.3(%rip), %rcx
	cmovneq	%rdx, %rcx
	cmpq	$0, 8(%rbx)
	leaq	L_.str.5(%rip), %rdx
	leaq	L_.str.4(%rip), %r8
	cmoveq	%rdx, %r8
	leaq	L_.str.2(%rip), %rsi
	movl	%r12d, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_syslog
	movq	8(%rbx), %rdi
	testq	%rdi, %rdi
	jne	LBB0_4
## %bb.3:
	movq	_NG_HCI_KEY_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_malloc
	movq	%rax, %rdi
	movq	%rax, 8(%rbx)
	testq	%rax, %rax
	je	LBB0_6
LBB0_4:
	movq	_NG_HCI_KEY_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rsi
	callq	_memcpy
	jmp	LBB0_5
LBB0_1:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_bt_ntoa
	leaq	L_.str.1(%rip), %rsi
	movl	%ebx, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_syslog
	movl	$-1, %r15d
LBB0_5:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.6(%rip), %rsi
	xorl	%eax, %eax
	callq	_syslog
	movl	$1, %edi
	callq	_exit
	.cfi_endproc
                                        ## -- End function
	.comm	_LOG_DEBUG,4,2                  ## @LOG_DEBUG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Got Link_Key_Notification event from '%s', remote bdaddr %s"

	.comm	_LOG_ERR,4,2                    ## @LOG_ERR
L_.str.1:                               ## @.str.1
	.asciz	"Could not find entry for remote bdaddr %s"

L_.str.2:                               ## @.str.2
	.asciz	"Updating link key for the entry, remote bdaddr %s, name '%s', link key %s"

L_.str.3:                               ## @.str.3
	.asciz	"No name"

L_.str.4:                               ## @.str.4
	.asciz	"exists"

L_.str.5:                               ## @.str.5
	.asciz	"doesn't exist"

	.comm	_NG_HCI_KEY_SIZE,4,2            ## @NG_HCI_KEY_SIZE
L_.str.6:                               ## @.str.6
	.asciz	"Could not allocate link key"

	.no_dead_strip	_process_link_key_notification_event
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function process_link_key_notification_event
_process_link_key_notification_event:   ; @process_link_key_notification_event
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	mov	x19, x2
Lloh0:
	adrp	x22, _LOG_DEBUG@GOTPAGE
Lloh1:
	ldr	x22, [x22, _LOG_DEBUG@GOTPAGEOFF]
	ldr	w20, [x22]
	add	x21, x2, #4
	ldr	w23, [x1]
	mov	x0, x21
	mov	x1, #0
	bl	_bt_ntoa
                                        ; kill: def $w0 killed $w0 def $x0
	stp	x23, x0, [sp]
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_syslog
	mov	x0, x21
	mov	w1, #1
	bl	_get_key
	cbz	x0, LBB0_4
; %bb.1:
	mov	x20, x0
	ldr	w21, [x22]
	add	x0, x0, #16
	mov	x1, #0
	bl	_bt_ntoa
                                        ; kill: def $w0 killed $w0 def $x0
Lloh4:
	adrp	x8, l_.str.3@PAGE
Lloh5:
	add	x8, x8, l_.str.3@PAGEOFF
	ldp	x9, x10, [x20]
	cmp	x9, #0
	csel	x8, x8, x9, eq
Lloh6:
	adrp	x9, l_.str.4@PAGE
Lloh7:
	add	x9, x9, l_.str.4@PAGEOFF
Lloh8:
	adrp	x11, l_.str.5@PAGE
Lloh9:
	add	x11, x11, l_.str.5@PAGEOFF
	cmp	x10, #0
	csel	x9, x11, x9, eq
	stp	x8, x9, [sp, #8]
	str	x0, [sp]
Lloh10:
	adrp	x1, l_.str.2@PAGE
Lloh11:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x21
	bl	_syslog
	ldr	x0, [x20, #8]
Lloh12:
	adrp	x21, _NG_HCI_KEY_SIZE@GOTPAGE
Lloh13:
	ldr	x21, [x21, _NG_HCI_KEY_SIZE@GOTPAGEOFF]
	cbnz	x0, LBB0_3
; %bb.2:
	ldr	w0, [x21]
	bl	_malloc
	str	x0, [x20, #8]
	cbz	x0, LBB0_6
LBB0_3:
	ldr	w2, [x21]
	mov	x1, x19
	bl	_memcpy
	mov	w0, #0
	b	LBB0_5
LBB0_4:
Lloh14:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh15:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh16:
	ldr	w19, [x8]
	mov	x0, x21
	mov	x1, #0
	bl	_bt_ntoa
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh17:
	adrp	x1, l_.str.1@PAGE
Lloh18:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_syslog
	mov	w0, #-1
LBB0_5:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_6:
Lloh19:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh20:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh21:
	ldr	w0, [x8]
Lloh22:
	adrp	x1, l_.str.6@PAGE
Lloh23:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_syslog
	mov	w0, #1
	bl	_exit
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.comm	_LOG_DEBUG,4,2                  ; @LOG_DEBUG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Got Link_Key_Notification event from '%s', remote bdaddr %s"

	.comm	_LOG_ERR,4,2                    ; @LOG_ERR
l_.str.1:                               ; @.str.1
	.asciz	"Could not find entry for remote bdaddr %s"

l_.str.2:                               ; @.str.2
	.asciz	"Updating link key for the entry, remote bdaddr %s, name '%s', link key %s"

l_.str.3:                               ; @.str.3
	.asciz	"No name"

l_.str.4:                               ; @.str.4
	.asciz	"exists"

l_.str.5:                               ; @.str.5
	.asciz	"doesn't exist"

	.comm	_NG_HCI_KEY_SIZE,4,2            ; @NG_HCI_KEY_SIZE
l_.str.6:                               ; @.str.6
	.asciz	"Could not allocate link key"

	.no_dead_strip	_process_link_key_notification_event
.subsections_via_symbols
