From: Nicolas Chautru Date: Tue, 22 Oct 2019 13:16:17 +0000 (-0700) Subject: baseband/fpga_lte_fec: fix polling of MMIO register X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=e12aabced4a9db018b3340a084568a76a217872b;p=dpdk.git baseband/fpga_lte_fec: fix polling of MMIO register Polling of MMIO register could misreport the actual value set dynamically in hardware as the variable was not set explicitly to volatile integer. Fixes: efd453698c49 ("baseband/fpga_lte_fec: add driver for FEC on FPGA") Cc: stable@dpdk.org Signed-off-by: Nicolas Chautru --- diff --git a/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c b/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c index 2fc7f110ac..8bd10b401a 100644 --- a/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c +++ b/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c @@ -889,7 +889,7 @@ fpga_queue_stop(struct rte_bbdev *dev, uint16_t queue_id) * completed. If completion flag is not updated within 1ms it is * considered as a failure. */ - while (!(*((uint8_t *)d->flush_queue_status + q->q_idx) & payload)) { + while (!(*((volatile uint8_t *)d->flush_queue_status + q->q_idx) & payload)) { if (counter > timeout) { rte_bbdev_log(ERR, "FPGA Queue Flush failed for queue %d", queue_id);