lkml.org 
[lkml]   [2021]   [Sep]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH v2 33/33] staging: wfx: early exit of PDS is not correct
Date
From: Jérôme Pouiller <jerome.pouiller@silabs.com>

If PDS data is not correct, the device is unlikely to work. Worse, the
pinmux maybe it misconfigured and it can generate IRQ-storms. Therefore,
do not try to start-up the device if PDS is invalid.

Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
---
drivers/staging/wfx/main.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/wfx/main.c b/drivers/staging/wfx/main.c
index 4386e9957ee6..b24ff4b31b72 100644
--- a/drivers/staging/wfx/main.c
+++ b/drivers/staging/wfx/main.c
@@ -409,7 +409,9 @@ int wfx_probe(struct wfx_dev *wdev)

dev_dbg(wdev->dev, "sending configuration file %s\n",
wdev->pdata.file_pds);
- wfx_send_pdata_pds(wdev);
+ err = wfx_send_pdata_pds(wdev);
+ if (err)
+ goto err0;

wdev->poll_irq = false;
err = wdev->hwbus_ops->irq_subscribe(wdev->hwbus_priv);
--
2.33.0
\
 
 \ /
  Last update: 2021-09-13 10:36    [W:0.288 / U:1.096 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site