You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2022/04/08 11:48:56 UTC
[GitHub] [incubator-nuttx] Ouss4 commented on a diff in pull request #5985: RISC-V: Combine 3 variables that depend on CPU amount into one
Ouss4 commented on code in PR #5985:
URL: https://github.com/apache/incubator-nuttx/pull/5985#discussion_r846031942
##########
arch/risc-v/src/mpfs/chip.h:
##########
@@ -29,4 +29,33 @@
#include "mpfs_memorymap.h"
+#include "riscv_percpu.h"
+
+/****************************************************************************
+ * Macro Definitions
+ ****************************************************************************/
+
+#ifdef __ASSEMBLY__
+
+/****************************************************************************
+ * Name: setintstack
+ *
+ * Description:
+ * Set the current stack pointer to the "top" the correct interrupt stack
+ * for the current CPU.
+ *
+ ****************************************************************************/
+
+#if CONFIG_ARCH_INTERRUPTSTACK > 15
+.macro setintstack tmp0, tmp1
+#ifndef CONFIG_ARCH_USE_S_MODE
Review Comment:
Looks like the definition of the macro needs to be inside the second `#ifdef`, otherwise we are ending up with two definitions.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org