Update has_rx_fifo and has_tx_fifo types from int to u32 in struct
axis_fifo.
The of_property_read_u32() function expects a pointer to u32. Although
the current code works correctly with int, using u32 aligns the data
structure with the Device Tree API and prevents potential
type-mismatch issues.
Signed-off-by: Gustavo Piaz da Silva <gustavopiazdasilva2102@gmail.com>
---
Changes in v7:
- Rewrote description for better clarity and explicitly acknowledged
that the original code works correctly.
Changes in v6:
- Added missing "---" line after Signed-off-by.
- Updated subject prefix to staging: axis-fifo.
Changes in v3:
- Split from a single patch into a two-patch series.
drivers/staging/axis-fifo/axis-fifo.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
index 509d620d6ce7..7bc7bf191250 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -121,8 +121,8 @@ struct axis_fifo {
unsigned int rx_fifo_depth; /* max words in the receive fifo */
unsigned int tx_fifo_depth; /* max words in the transmit fifo */
- int has_rx_fifo; /* whether the IP has the rx fifo enabled */
- int has_tx_fifo; /* whether the IP has the tx fifo enabled */
+ u32 has_rx_fifo; /* whether the IP has the rx fifo enabled */
+ u32 has_tx_fifo; /* whether the IP has the tx fifo enabled */
wait_queue_head_t read_queue; /* wait queue for asynchronos read */
struct mutex read_lock; /* lock for reading */
--
2.52.0