	.file	"extr_coresight-etm4x.c_etm4_get_ns_access_type.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	etm4_get_ns_access_type, @function
etm4_get_ns_access_type:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbx
	.cfi_def_cfa_offset 16
	.cfi_offset 3, -16
	xor	eax, eax
	mov	rbx, rdi
	call	is_kernel_in_hyp_mode@PLT
	test	eax, eax
	jne	.L2
	mov	eax, DWORD PTR ETM_EXLEVEL_NS_HYP[rip]
	mov	edx, DWORD PTR [rbx]
	test	DWORD PTR ETM_MODE_EXCL_KERN[rip], edx
	jne	.L15
.L3:
	test	DWORD PTR ETM_MODE_EXCL_USER[rip], edx
	je	.L1
	or	eax, DWORD PTR ETM_EXLEVEL_NS_APP[rip]
.L1:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L2:
	.cfi_restore_state
	mov	edx, DWORD PTR [rbx]
	mov	eax, edx
	and	eax, DWORD PTR ETM_MODE_EXCL_KERN[rip]
	cmovne	eax, DWORD PTR ETM_EXLEVEL_NS_HYP[rip]
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L15:
	or	eax, DWORD PTR ETM_EXLEVEL_NS_OS[rip]
	jmp	.L3
	.cfi_endproc
.LFE0:
	.size	etm4_get_ns_access_type, .-etm4_get_ns_access_type
	.comm	ETM_MODE_EXCL_USER,4,4
	.comm	ETM_MODE_EXCL_KERN,4,4
	.comm	ETM_EXLEVEL_NS_OS,4,4
	.comm	ETM_EXLEVEL_NS_HYP,4,4
	.comm	ETM_EXLEVEL_NS_APP,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_coresight-etm4x.c_etm4_get_ns_access_type.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	etm4_get_ns_access_type, %function
etm4_get_ns_access_type:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, lr}
	mov	r4, r0
	bl	is_kernel_in_hyp_mode
	cmp	r0, #0
	ldr	r2, .L16
	ldr	r3, [r4]
	bne	.L2
	ldr	r1, [r2]
	ldr	r2, .L16+4
	tst	r3, r1
	ldr	r0, [r2]
	ldrne	r2, .L16+8
	ldrne	r2, [r2]
	orrne	r0, r0, r2
.L3:
	ldr	r2, .L16+12
	ldr	r2, [r2]
	tst	r3, r2
	ldrne	r3, .L16+16
	ldrne	r3, [r3]
	orrne	r0, r0, r3
	pop	{r4, pc}
.L2:
	ldr	r0, [r2]
	ands	r0, r3, r0
	ldrne	r2, .L16+4
	ldrne	r0, [r2]
	b	.L3
.L17:
	.align	2
.L16:
	.word	ETM_MODE_EXCL_KERN
	.word	ETM_EXLEVEL_NS_HYP
	.word	ETM_EXLEVEL_NS_OS
	.word	ETM_MODE_EXCL_USER
	.word	ETM_EXLEVEL_NS_APP
	.size	etm4_get_ns_access_type, .-etm4_get_ns_access_type
	.comm	ETM_MODE_EXCL_USER,4,4
	.comm	ETM_MODE_EXCL_KERN,4,4
	.comm	ETM_EXLEVEL_NS_OS,4,4
	.comm	ETM_EXLEVEL_NS_HYP,4,4
	.comm	ETM_EXLEVEL_NS_APP,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
