Thread (53 messages) 53 messages, 4 authors, 2018-06-20

[PATCHv3 10/19] arm64: convert native/compat syscall entry to C

From: Dave.Martin@arm.com (Dave Martin)
Date: 2018-06-20 09:21:11
Also in: linux-fsdevel

On Tue, Jun 19, 2018 at 02:15:24PM +0100, Mark Rutland wrote:
On Tue, Jun 19, 2018 at 01:18:17PM +0100, Dave Martin wrote:
quoted
On Mon, Jun 18, 2018 at 01:03:01PM +0100, Mark Rutland wrote:
quoted
+static inline void sve_user_reset(void)
+{
Can we call this "sve_user_discard" please?

"Reset" is a reasonable name for the concept, but the "discard"
terminology has been used elsewhere.
Sure; done.
quoted
quoted
+	if (!system_supports_sve())
+		return;
+
+	/*
+	 * task_fpsimd_load() won't be called to update CPACR_EL1 in
+	 * ret_to_user unless TIF_FOREIGN_FPSTATE is still set, which only
+	 * happens if a context switch or kernel_neon_begin() or context
+	 * modification (sigreturn, ptrace) intervenes.
+	 * So, ensure that CPACR_EL1 is already correct for the fast-path case.
+	 */
This comment should go after clear_thead_flag(), since it describes not
the purpose of this function but the presence of sve_user_disable().
quoted
+	clear_thread_flag(TIF_SVE);
+	sve_user_disable();
+}
Good point. I've moved the clear_thread_flag(TIF_SVE) above the comment
(with a blank line before the comment).
Thanks -- with those changes:

Reviewed-by: Dave Martin <Dave.Martin@arm.com> (for the SVE parts)

Cheers
---Dave
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help