summaryrefslogtreecommitdiff
path: root/block
diff options
context:
space:
mode:
authorLi kunyu <kunyu@nfschina.com>2024-03-06 18:06:59 +0800
committerJens Axboe <axboe@kernel.dk>2024-03-06 08:29:43 -0700
commit2449be8c8cfcbb24b3cd15d8b55c2c91041c847b (patch)
treebcc7433840f4034a8b86722d98ecd3a9622dcc45 /block
parent217fcc48074be4f526190675140a478ee795d90d (diff)
sed-opal: Remove unnecessary ‘0’ values from ret
ret is assigned first, so it does not need to initialize the assignment. Signed-off-by: Li kunyu <kunyu@nfschina.com> Link: https://lore.kernel.org/r/20240306100659.106521-1-kunyu@nfschina.com Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block')
-rw-r--r--block/sed-opal.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/block/sed-opal.c b/block/sed-opal.c
index b6887920a84e..f62b7ee933f7 100644
--- a/block/sed-opal.c
+++ b/block/sed-opal.c
@@ -2576,7 +2576,7 @@ static int opal_get_discv(struct opal_dev *dev, struct opal_discovery *discv)
const struct opal_step discovery0_step = {
opal_discovery0, discv
};
- int ret = 0;
+ int ret;
mutex_lock(&dev->dev_lock);
setup_opal_dev(dev);
@@ -3065,7 +3065,7 @@ bool opal_unlock_from_suspend(struct opal_dev *dev)
{
struct opal_suspend_data *suspend;
bool was_failure = false;
- int ret = 0;
+ int ret;
if (!dev)
return false;