Watchdog enable/disable on Leon3 KCU105

Hello,

I am working on the example design leon3-xilinx-kcu105 of the grlib-gpl-2023.2-b4283 (I will update). Appart from other modifications, I want to use the watchdog included in the GPTIMER, but I want to be able to select if it should be enabled/disabled at start up using one of the switches of the KCU105 board.

I have instantiated the GPTIMER with wdog and ewdogen values different of 0.

  gpt : if CFG_GPT_ENABLE /= 0 generate
    -- Timer Unit
    timer0 : gptimer
      generic map (pindex  => 3, paddr => 3, pirq => CFG_GPT_IRQ,
                   sepirq  => 0, sbits => 8, ntimers => 2,
                   nbits   => 32, wdog =>16#1FFFFFF# , ewdogen => 1)
      port map (rstn, clkm, apbi, apbo(3), gpti, gpto)

I am using the GPTI.WDOGEN signal to select if the watchdog should be enabled/disabled. It should be connected to the switch (using and inpad) but to simplify, I have fixed to 1, so the watchdog should be enabled.

 gpti.wdogen <= '1';

The problem is that the synthesis tools claims:

CRITICAL WARNING: [Synth 8-3352] multi-driven net \gpti[wdogen] with 1st driver pin ‘GND’ [designs/leon3-xilinx-kcu105/leon3mp.vhd:1205]
CRITICAL WARNING: [Synth 8-3352] multi-driven net \gpti[wdogen] with 2nd driver pin ‘VCC’ [designs/leon3-xilinx-kcu105/leon3mp.vhd:1205]
CRITICAL WARNING: [Synth 8-5559] multi-driven net \gpti[wdogen] is connected to constant driver, other driver is ignored [designs/leon3-xilinx-kcu105/leon3mp.vhd:1205]

The signal is tied to gnd and I can not manage the enable/disable of the watchdog. I can not find where the gpti[wdogen] signal is assigned GND.

Do you have any hint?

You can replace the original driver.

--gpti <= gpti_dhalt_drive('0');
  gpti <= (dhalt  => '0',
           extclk => '0',
           wdogen => '1',
           latchv => (others => '0'),
           latchd => (others => '0'));

That solved the issue.

Thanks Wei,