From 7f1285a13604ab96c6e839a34a0596be54331c17 Mon Sep 17 00:00:00 2001 From: "William D. Jones" Date: Sun, 19 Aug 2018 00:42:50 -0400 Subject: [PATCH] firmware: Fix unused-var and type mismatch error in recent gcc (7+). --- firmware/ci.c | 2 +- firmware/pll.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/firmware/ci.c b/firmware/ci.c index 2d0d4957..64a0e7aa 100644 --- a/firmware/ci.c +++ b/firmware/ci.c @@ -724,7 +724,7 @@ static void video_mode_set(int mode) static void video_mode_secondary(char *str) { char *token; - if((token = get_token(&str)) == '\0') return; + if((* (token = get_token(&str))) == '\0') return; if(strcmp(token, "off") == 0) { wprintf("Turning off secondary video mode\n"); diff --git a/firmware/pll.c b/firmware/pll.c index 18ebbe82..b2596ef2 100644 --- a/firmware/pll.c +++ b/firmware/pll.c @@ -70,6 +70,8 @@ void pll_config_for_clock(int freq) * Reproducible both with DRP and initial reconfiguration. * Until this spartan6 weirdness is sorted out, just stick to 20x. */ + + (void) pll_config_10x[0]; // Dummy access to suppress to suppress -Werror=unused-const-variable. program_data(pll_config_20x); #ifdef XILINX_SPARTAN6_WORKS_AMAZINGLY_WELL if(freq < 2000)