	.file	"extr_bta_dm_act.c_btm_dm_ble_multi_adv_disable.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	btm_dm_ble_multi_adv_disable
	.type	btm_dm_ble_multi_adv_disable, @function
btm_dm_ble_multi_adv_disable:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	xor	eax, eax
	push	rbx
	.cfi_def_cfa_offset 24
	.cfi_offset 3, -24
	mov	rbx, rdi
	sub	rsp, 8
	.cfi_def_cfa_offset 32
	call	BTM_BleMaxMultiAdvInstanceCount@PLT
	test	rax, rax
	jle	.L4
	mov	rbp, QWORD PTR [rbx]
	test	rbp, rbp
	jg	.L8
.L4:
	xor	eax, eax
.L3:
	cmp	QWORD PTR BTM_CMD_STARTED[rip], rax
	jne	.L9
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L8:
	.cfi_restore_state
	xor	eax, eax
	call	BTM_BleMaxMultiAdvInstanceCount@PLT
	cmp	rbp, rax
	jge	.L4
	mov	rdi, QWORD PTR [rbx]
	call	BTM_BleDisableAdvInstance@PLT
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L9:
	mov	rdi, QWORD PTR [rbx]
	call	btm_ble_multi_adv_get_ref@PLT
	mov	rsi, QWORD PTR [rbx]
	mov	ecx, DWORD PTR BTA_FAILURE[rip]
	mov	edi, DWORD PTR BTA_BLE_MULTI_ADV_DISABLE_EVT[rip]
	add	rsp, 8
	.cfi_def_cfa_offset 24
	mov	rdx, rax
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	jmp	[QWORD PTR bta_dm_cb[rip]]
	.cfi_endproc
.LFE0:
	.size	btm_dm_ble_multi_adv_disable, .-btm_dm_ble_multi_adv_disable
	.comm	bta_dm_cb,8,8
	.comm	BTM_CMD_STARTED,8,8
	.comm	BTA_FAILURE,4,4
	.comm	BTA_BLE_MULTI_ADV_DISABLE_EVT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_bta_dm_act.c_btm_dm_ble_multi_adv_disable.c"
	.text
	.align	2
	.global	btm_dm_ble_multi_adv_disable
	.syntax unified
	.arm
	.fpu softvfp
	.type	btm_dm_ble_multi_adv_disable, %function
btm_dm_ble_multi_adv_disable:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	mov	r4, r0
	bl	BTM_BleMaxMultiAdvInstanceCount
	cmp	r0, #0
	ble	.L4
	ldr	r5, [r4]
	cmp	r5, #0
	bgt	.L8
.L4:
	mov	r0, #0
.L3:
	ldr	r3, .L9
	ldr	r3, [r3]
	cmp	r3, r0
	popeq	{r4, r5, r6, pc}
	ldr	r0, [r4]
	bl	btm_ble_multi_adv_get_ref
	ldr	lr, .L9+4
	ldr	ip, .L9+8
	mov	r2, r0
	ldr	r3, .L9+12
	ldr	r0, [lr]
	ldr	lr, [ip]
	ldr	r1, [r4]
	mov	ip, lr
	pop	{r4, r5, r6, lr}
	ldr	r3, [r3]
	bx	ip
.L8:
	bl	BTM_BleMaxMultiAdvInstanceCount
	cmp	r5, r0
	bge	.L4
	ldr	r0, [r4]
	bl	BTM_BleDisableAdvInstance
	b	.L3
.L10:
	.align	2
.L9:
	.word	BTM_CMD_STARTED
	.word	BTA_BLE_MULTI_ADV_DISABLE_EVT
	.word	bta_dm_cb
	.word	BTA_FAILURE
	.size	btm_dm_ble_multi_adv_disable, .-btm_dm_ble_multi_adv_disable
	.comm	bta_dm_cb,4,4
	.comm	BTM_CMD_STARTED,4,4
	.comm	BTA_FAILURE,4,4
	.comm	BTA_BLE_MULTI_ADV_DISABLE_EVT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
