aboutsummaryrefslogtreecommitdiff
path: root/sim/bfin
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2021-05-23 21:35:32 -0400
committerMike Frysinger <vapier@gentoo.org>2021-05-23 21:37:31 -0400
commit3cc4ee83adf2f6e2ab21e32f7d5942b1d1803a04 (patch)
treef5571f59973f5546e150d1e453aaf878b7f4ec89 /sim/bfin
parent98591adf69eb2eeb0ae4beceb370da406b0ea0dd (diff)
downloadgdb-3cc4ee83adf2f6e2ab21e32f7d5942b1d1803a04.zip
gdb-3cc4ee83adf2f6e2ab21e32f7d5942b1d1803a04.tar.gz
gdb-3cc4ee83adf2f6e2ab21e32f7d5942b1d1803a04.tar.bz2
sim: bfin: fix build warnings w/newer gcc
The bfin_otp_write_page_val func wants a pointer to an bu64[2] array, but this code passes it a pointer to a single bu64. It's in a struct with a known compatible layout: bu64 data0, data1, data2, data3; But gcc doesn't allow these kinds of tricks anymore. Use the more verbose form to make the compiler happy since this is not performance sensitive code.
Diffstat (limited to 'sim/bfin')
-rw-r--r--sim/bfin/ChangeLog4
-rw-r--r--sim/bfin/dv-bfin_otp.c2
2 files changed, 5 insertions, 1 deletions
diff --git a/sim/bfin/ChangeLog b/sim/bfin/ChangeLog
index 1ebf681..9c517d2 100644
--- a/sim/bfin/ChangeLog
+++ b/sim/bfin/ChangeLog
@@ -1,5 +1,9 @@
2021-05-23 Mike Frysinger <vapier@gentoo.org>
+ * dv-bfin_otp.c (bfin_otp_write_page): Call bfin_otp_write_page_val2.
+
+2021-05-23 Mike Frysinger <vapier@gentoo.org>
+
* dv-bfin_cec.c: Include strings.h.
2021-05-17 Mike Frysinger <vapier@gentoo.org>
diff --git a/sim/bfin/dv-bfin_otp.c b/sim/bfin/dv-bfin_otp.c
index 6cf1c81..65afdf5 100644
--- a/sim/bfin/dv-bfin_otp.c
+++ b/sim/bfin/dv-bfin_otp.c
@@ -91,7 +91,7 @@ bfin_otp_write_page_val2 (struct bfin_otp *otp, bu16 page, bu64 lo, bu64 hi)
static void
bfin_otp_write_page (struct bfin_otp *otp, bu16 page)
{
- bfin_otp_write_page_val (otp, page, (void *)&otp->data0);
+ bfin_otp_write_page_val2 (otp, page, otp->data0, otp->data1);
}
static unsigned