lkml.org 
[lkml]   [2023]   [Aug]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] bus: bt1-apb: Change from u32 to unsigned int for regmap_read() calls
Date
regmap_read() API signature expects the caller to send "unsigned int"
type to return back the read value.
Change the two calls to match the regmap_read() signature.
Also shuffle the variable declaration lines around to respect
reverse christmas tree order.

Signed-off-by: Yann Sionneau <yann@sionneau.net>
---
drivers/bus/bt1-apb.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/bus/bt1-apb.c b/drivers/bus/bt1-apb.c
index e97c1d1c7578..becc92572bea 100644
--- a/drivers/bus/bt1-apb.c
+++ b/drivers/bus/bt1-apb.c
@@ -92,7 +92,7 @@ static inline unsigned long bt1_apb_timeout_to_n_us(struct bt1_apb *apb,
static irqreturn_t bt1_apb_isr(int irq, void *data)
{
struct bt1_apb *apb = data;
- u32 addr = 0;
+ unsigned int addr = 0;

regmap_read(apb->regs, APB_EHB_ADDR, &addr);

@@ -274,8 +274,8 @@ static ssize_t timeout_show(struct device *dev, struct device_attribute *attr,
{
struct bt1_apb *apb = dev_get_drvdata(dev);
unsigned long timeout;
+ unsigned int n;
int ret;
- u32 n;

ret = regmap_read(apb->regs, APB_EHB_TIMEOUT, &n);
if (ret)
base-commit: 2ccdd1b13c591d306f0401d98dedc4bdcd02b421
--
2.34.1

\
 
 \ /
  Last update: 2023-08-16 12:27    [W:0.016 / U:1.052 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site