qemu-ppc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 4/7] target/ppc: turned SPR R/W callbacks not static


From: Richard Henderson
Subject: Re: [PATCH v2 4/7] target/ppc: turned SPR R/W callbacks not static
Date: Thu, 29 Apr 2021 20:40:49 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1

On 4/29/21 9:21 AM, Bruno Larsen (billionai) wrote:
@@ -234,19 +235,19 @@ static void spr_read_tbu(DisasContext *ctx, int gprn, int 
sprn)
  }
ATTRIBUTE_UNUSED
-static void spr_read_atbl(DisasContext *ctx, int gprn, int sprn)
+void spr_read_atbl(DisasContext *ctx, int gprn, int sprn)
  {

You can drop the ATTRIBUTE_UNUSED at the same time.

It was only there to stop the static symbol from being signaled as unused; for a non-static symbol, the compiler obviously can't tell.

diff --git a/target/ppc/spr_tcg.h b/target/ppc/spr_tcg.h
new file mode 100644
index 0000000000..b573a23e7b
--- /dev/null
+++ b/target/ppc/spr_tcg.h
@@ -0,0 +1,121 @@
+#ifndef SPR_TCG_H
+#define SPR_TCG_H
+
+#include "qemu/osdep.h"
+#include "cpu.h"
+#include "exec/translator.h"
+#include "tcg/tcg.h"

All new files get copyright headers. No headers include osdep.h. It doesn't appear that you need any headers for this file; just add

typedef struct DisasContext DisasContext;

to the top of the file.


r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]