	.file	"extr_arm_spe_pmu.c_arm_spe_pmu_buf_get_fault_act.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"Unknown error code"
.LC1:
	.string	"Unexpected buffer fault"
.LC2:
	.string	"Unknown buffer status code"
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC3:
	.string	"%s on CPU %d [PMBSR=0x%016llx, PMBPTR=0x%016llx, PMBLIMITR=0x%016llx]\n"
	.text
	.p2align 4
	.type	arm_spe_pmu_buf_get_fault_act, @function
arm_spe_pmu_buf_get_fault_act:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	xor	eax, eax
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	call	psb_csync@PLT
	mov	edi, DWORD PTR nsh[rip]
	call	dsb@PLT
	xor	eax, eax
	call	isb@PLT
	mov	edi, DWORD PTR SYS_PMBSR_EL1[rip]
	call	read_sysreg_s@PLT
	mov	edi, DWORD PTR SYS_PMBSR_EL1_S_SHIFT[rip]
	mov	r12d, eax
	call	BIT@PLT
	test	eax, r12d
	jne	.L2
	mov	r12d, DWORD PTR SPE_PMU_BUF_FAULT_ACT_SPURIOUS[rip]
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	mov	eax, r12d
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L2:
	.cfi_restore_state
	mov	edi, DWORD PTR SYS_PMBSR_EL1_DL_SHIFT[rip]
	call	BIT@PLT
	test	eax, r12d
	jne	.L20
.L4:
	mov	edi, DWORD PTR SYS_PMBSR_EL1_COLL_SHIFT[rip]
	call	BIT@PLT
	test	eax, r12d
	jne	.L21
.L5:
	mov	ecx, DWORD PTR SYS_PMBSR_EL1_EC_SHIFT[rip]
	mov	eax, DWORD PTR SYS_PMBSR_EL1_EC_MASK[rip]
	sal	eax, cl
	and	eax, r12d
	cmp	eax, 129
	jg	.L6
	cmp	eax, 127
	lea	r13, .LC1[rip]
	lea	rsi, .LC0[rip]
	cmovle	r13, rsi
.L8:
	mov	edi, DWORD PTR SYS_PMBLIMITR_EL1[rip]
	call	read_sysreg_s@PLT
	mov	edi, DWORD PTR SYS_PMBPTR_EL1[rip]
	mov	r14d, eax
	call	read_sysreg_s@PLT
	mov	ebx, eax
	xor	eax, eax
	call	smp_processor_id@PLT
	mov	ecx, r12d
	mov	r9d, r14d
	mov	r8d, ebx
	mov	edx, eax
	mov	rsi, r13
	lea	rdi, .LC3[rip]
	call	pr_err_ratelimited@PLT
	mov	r12d, DWORD PTR SPE_PMU_BUF_FAULT_ACT_FATAL[rip]
.L9:
	mov	rdi, rbp
	call	arm_spe_perf_aux_output_end@PLT
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r12d
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L6:
	.cfi_restore_state
	cmp	eax, 130
	jne	.L10
	mov	ecx, DWORD PTR SYS_PMBSR_EL1_BUF_BSC_SHIFT[rip]
	mov	eax, DWORD PTR SYS_PMBSR_EL1_BUF_BSC_MASK[rip]
	lea	r13, .LC2[rip]
	sal	eax, cl
	and	eax, r12d
	cmp	eax, 131
	jne	.L8
	mov	r12d, DWORD PTR SPE_PMU_BUF_FAULT_ACT_OK[rip]
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L10:
	lea	r13, .LC0[rip]
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L21:
	mov	esi, DWORD PTR PERF_AUX_FLAG_COLLISION[rip]
	mov	rdi, rbp
	call	perf_aux_output_flag@PLT
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L20:
	mov	esi, DWORD PTR PERF_AUX_FLAG_TRUNCATED[rip]
	mov	rdi, rbp
	or	esi, DWORD PTR PERF_AUX_FLAG_PARTIAL[rip]
	call	perf_aux_output_flag@PLT
	jmp	.L4
	.cfi_endproc
.LFE0:
	.size	arm_spe_pmu_buf_get_fault_act, .-arm_spe_pmu_buf_get_fault_act
	.comm	nsh,4,4
	.comm	SYS_PMBSR_EL1_S_SHIFT,4,4
	.comm	SYS_PMBSR_EL1_EC_SHIFT,4,4
	.comm	SYS_PMBSR_EL1_EC_MASK,4,4
	.comm	SYS_PMBSR_EL1_DL_SHIFT,4,4
	.comm	SYS_PMBSR_EL1_COLL_SHIFT,4,4
	.comm	SYS_PMBSR_EL1_BUF_BSC_SHIFT,4,4
	.comm	SYS_PMBSR_EL1_BUF_BSC_MASK,4,4
	.comm	SYS_PMBSR_EL1,4,4
	.comm	SYS_PMBPTR_EL1,4,4
	.comm	SYS_PMBLIMITR_EL1,4,4
	.comm	SPE_PMU_BUF_FAULT_ACT_SPURIOUS,4,4
	.comm	SPE_PMU_BUF_FAULT_ACT_OK,4,4
	.comm	SPE_PMU_BUF_FAULT_ACT_FATAL,4,4
	.comm	PERF_AUX_FLAG_TRUNCATED,4,4
	.comm	PERF_AUX_FLAG_PARTIAL,4,4
	.comm	PERF_AUX_FLAG_COLLISION,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_arm_spe_pmu.c_arm_spe_pmu_buf_get_fault_act.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Unknown error code\000"
	.align	2
.LC1:
	.ascii	"Unexpected buffer fault\000"
	.align	2
.LC2:
	.ascii	"Unknown buffer status code\000"
	.align	2
.LC3:
	.ascii	"%s on CPU %d [PMBSR=0x%016llx, PMBPTR=0x%016llx, PM"
	.ascii	"BLIMITR=0x%016llx]\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	arm_spe_pmu_buf_get_fault_act, %function
arm_spe_pmu_buf_get_fault_act:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	sub	sp, sp, #8
	mov	r6, r0
	bl	psb_csync
	ldr	r3, .L22
	ldr	r0, [r3]
	bl	dsb
	bl	isb
	ldr	r3, .L22+4
	ldr	r0, [r3]
	bl	read_sysreg_s
	ldr	r3, .L22+8
	mov	r4, r0
	ldr	r0, [r3]
	bl	BIT
	tst	r0, r4
	bne	.L2
	ldr	r3, .L22+12
	ldr	r4, [r3]
	mov	r0, r4
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, pc}
.L2:
	ldr	r3, .L22+16
	ldr	r0, [r3]
	bl	BIT
	tst	r0, r4
	bne	.L20
.L4:
	ldr	r3, .L22+20
	ldr	r0, [r3]
	bl	BIT
	tst	r0, r4
	bne	.L21
.L5:
	ldr	r3, .L22+24
	ldr	r2, .L22+28
	ldr	r3, [r3]
	ldr	r1, [r2]
	and	r3, r4, r3, lsl r1
	cmp	r3, #129
	bgt	.L6
	ldr	r1, .L22+32
	cmp	r3, #127
	ldr	r5, .L22+36
	movle	r5, r1
.L8:
	bl	smp_processor_id
	ldr	r3, .L22+40
	mov	r7, r0
	ldr	r0, [r3]
	bl	read_sysreg_s
	ldr	r3, .L22+44
	mov	r8, r0
	ldr	r0, [r3]
	bl	read_sysreg_s
	mov	r3, r4
	str	r0, [sp, #4]
	mov	r2, r7
	mov	r1, r5
	ldr	r0, .L22+48
	str	r8, [sp]
	bl	pr_err_ratelimited
	ldr	r3, .L22+52
	ldr	r4, [r3]
.L9:
	mov	r0, r6
	bl	arm_spe_perf_aux_output_end
	mov	r0, r4
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, pc}
.L6:
	cmp	r3, #130
	bne	.L10
	ldr	r3, .L22+56
	ldr	r2, .L22+60
	ldr	r3, [r3]
	ldr	r2, [r2]
	and	r3, r4, r3, lsl r2
	cmp	r3, #131
	ldrne	r5, .L22+64
	bne	.L8
	ldr	r3, .L22+68
	ldr	r4, [r3]
	b	.L9
.L10:
	ldr	r5, .L22+32
	b	.L8
.L21:
	ldr	r3, .L22+72
	mov	r0, r6
	ldr	r1, [r3]
	bl	perf_aux_output_flag
	b	.L5
.L20:
	ldr	r2, .L22+76
	ldr	r3, .L22+80
	ldr	r1, [r2]
	ldr	r3, [r3]
	mov	r0, r6
	orr	r1, r1, r3
	bl	perf_aux_output_flag
	b	.L4
.L23:
	.align	2
.L22:
	.word	nsh
	.word	SYS_PMBSR_EL1
	.word	SYS_PMBSR_EL1_S_SHIFT
	.word	SPE_PMU_BUF_FAULT_ACT_SPURIOUS
	.word	SYS_PMBSR_EL1_DL_SHIFT
	.word	SYS_PMBSR_EL1_COLL_SHIFT
	.word	SYS_PMBSR_EL1_EC_MASK
	.word	SYS_PMBSR_EL1_EC_SHIFT
	.word	.LC0
	.word	.LC1
	.word	SYS_PMBPTR_EL1
	.word	SYS_PMBLIMITR_EL1
	.word	.LC3
	.word	SPE_PMU_BUF_FAULT_ACT_FATAL
	.word	SYS_PMBSR_EL1_BUF_BSC_MASK
	.word	SYS_PMBSR_EL1_BUF_BSC_SHIFT
	.word	.LC2
	.word	SPE_PMU_BUF_FAULT_ACT_OK
	.word	PERF_AUX_FLAG_COLLISION
	.word	PERF_AUX_FLAG_TRUNCATED
	.word	PERF_AUX_FLAG_PARTIAL
	.size	arm_spe_pmu_buf_get_fault_act, .-arm_spe_pmu_buf_get_fault_act
	.comm	nsh,4,4
	.comm	SYS_PMBSR_EL1_S_SHIFT,4,4
	.comm	SYS_PMBSR_EL1_EC_SHIFT,4,4
	.comm	SYS_PMBSR_EL1_EC_MASK,4,4
	.comm	SYS_PMBSR_EL1_DL_SHIFT,4,4
	.comm	SYS_PMBSR_EL1_COLL_SHIFT,4,4
	.comm	SYS_PMBSR_EL1_BUF_BSC_SHIFT,4,4
	.comm	SYS_PMBSR_EL1_BUF_BSC_MASK,4,4
	.comm	SYS_PMBSR_EL1,4,4
	.comm	SYS_PMBPTR_EL1,4,4
	.comm	SYS_PMBLIMITR_EL1,4,4
	.comm	SPE_PMU_BUF_FAULT_ACT_SPURIOUS,4,4
	.comm	SPE_PMU_BUF_FAULT_ACT_OK,4,4
	.comm	SPE_PMU_BUF_FAULT_ACT_FATAL,4,4
	.comm	PERF_AUX_FLAG_TRUNCATED,4,4
	.comm	PERF_AUX_FLAG_PARTIAL,4,4
	.comm	PERF_AUX_FLAG_COLLISION,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
