[lvc-project] [PATCH] staging: vme: Remove unneeded check in vme_lm_request()
Aleksandr Mishin
amishin at t-argos.ru
Fri Jul 5 14:02:34 MSK 2024
In vme_lm_request() list_for_each() pointer 'lm' is compared to NULL which
is useless.
Fix this issue by removing unneeded check.
Found by Linux Verification Center (linuxtesting.org) with SVACE.
Fixes: 42fb503122d8 ("Staging: vme: add VME Location Monitor management mechanism")
Signed-off-by: Aleksandr Mishin <amishin at t-argos.ru>
---
drivers/staging/vme_user/vme.c | 6 ------
1 file changed, 6 deletions(-)
diff --git a/drivers/staging/vme_user/vme.c b/drivers/staging/vme_user/vme.c
index 0cd370ab1008..223c4d607c88 100644
--- a/drivers/staging/vme_user/vme.c
+++ b/drivers/staging/vme_user/vme.c
@@ -1445,12 +1445,6 @@ struct vme_resource *vme_lm_request(struct vme_dev *vdev)
/* Loop through LM resources */
list_for_each_entry(lm, &bridge->lm_resources, list) {
- if (!lm) {
- dev_err(bridge->parent,
- "Registered NULL Location Monitor resource\n");
- continue;
- }
-
/* Find an unlocked controller */
mutex_lock(&lm->mtx);
if (lm->locked == 0) {
--
2.30.2
More information about the lvc-project
mailing list