diff options
author | Soumya Negi <soumya.negi97@gmail.com> | 2023-10-13 16:47:14 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2023-10-15 18:21:18 +0200 |
commit | 2a7f242e88d1fb4bcebe92e38f57a4cbacf40f7c (patch) | |
tree | 2529ae169a16f6500395efa69889e35aed5f704c /drivers/staging | |
parent | 4d8cc30a9b49781089c082cd858a1c0fc882f480 (diff) | |
download | linux-stable-2a7f242e88d1fb4bcebe92e38f57a4cbacf40f7c.tar.gz linux-stable-2a7f242e88d1fb4bcebe92e38f57a4cbacf40f7c.tar.bz2 linux-stable-2a7f242e88d1fb4bcebe92e38f57a4cbacf40f7c.zip |
staging: vme_user: Fix unbalanced {} in if-else blocks
Add missing braces so that {} are balanced in all arms of if-else
statements as per Linux coding style. Issue found by checkpatch.pl
Signed-off-by: Soumya Negi <soumya.negi97@gmail.com>
Link: https://lore.kernel.org/r/b0fad6de7405a105235b3b595e0bb2c51be7dcf0.1697240381.git.soumya.negi97@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r-- | drivers/staging/vme_user/vme.c | 3 | ||||
-rw-r--r-- | drivers/staging/vme_user/vme_tsi148.c | 7 |
2 files changed, 6 insertions, 4 deletions
diff --git a/drivers/staging/vme_user/vme.c b/drivers/staging/vme_user/vme.c index 80083ea0fb53..6519a7c994a0 100644 --- a/drivers/staging/vme_user/vme.c +++ b/drivers/staging/vme_user/vme.c @@ -1849,8 +1849,9 @@ static int __vme_register_driver_bus(struct vme_driver *drv, if (vdev->dev.platform_data) { list_add_tail(&vdev->drv_list, &drv->devices); list_add_tail(&vdev->bridge_list, &bridge->devices); - } else + } else { device_unregister(&vdev->dev); + } } return 0; diff --git a/drivers/staging/vme_user/vme_tsi148.c b/drivers/staging/vme_user/vme_tsi148.c index 2f5eafd50934..d549c22da534 100644 --- a/drivers/staging/vme_user/vme_tsi148.c +++ b/drivers/staging/vme_user/vme_tsi148.c @@ -2118,8 +2118,9 @@ static int tsi148_slot_get(struct vme_bridge *tsi148_bridge) if (!geoid) { slot = ioread32be(bridge->base + TSI148_LCSR_VSTAT); slot = slot & TSI148_LCSR_VSTAT_GA_M; - } else + } else { slot = geoid; + } return (int)slot; } @@ -2196,9 +2197,9 @@ static int tsi148_crcsr_init(struct vme_bridge *tsi148_bridge, dev_info(tsi148_bridge->parent, "CR/CSR Offset: %d\n", cbar); crat = ioread32be(bridge->base + TSI148_LCSR_CRAT); - if (crat & TSI148_LCSR_CRAT_EN) + if (crat & TSI148_LCSR_CRAT_EN) { dev_info(tsi148_bridge->parent, "CR/CSR already enabled\n"); - else { + } else { dev_info(tsi148_bridge->parent, "Enabling CR/CSR space\n"); iowrite32be(crat | TSI148_LCSR_CRAT_EN, bridge->base + TSI148_LCSR_CRAT); |