Skip to content

Commit 6be5449

Browse files
prajnohakergon
authored andcommitted
dm ioctl: remove __dev_status from geometry and target message
Remove useless __dev_status call while processing an ioctl that sets up device geometry and target message. The data is not returned to userspace so there is no point collecting it and in the case of target_message it is collected before processing the message so if it did return it might be stale. Signed-off-by: Peter Rajnoha <prajnoha@redhat.com> Signed-off-by: Alasdair G Kergon <agk@redhat.com>
1 parent c241104 commit 6be5449

1 file changed

Lines changed: 0 additions & 6 deletions

File tree

‎drivers/md/dm-ioctl.c‎

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -818,8 +818,6 @@ static int dev_set_geometry(struct dm_ioctl *param, size_t param_size)
818818
geometry.start = indata[3];
819819

820820
r = dm_set_geometry(md, &geometry);
821-
if (!r)
822-
r = __dev_status(md, param);
823821

824822
param->data_size = 0;
825823

@@ -1333,10 +1331,6 @@ static int target_message(struct dm_ioctl *param, size_t param_size)
13331331
if (!md)
13341332
return -ENXIO;
13351333

1336-
r = __dev_status(md, param);
1337-
if (r)
1338-
goto out;
1339-
13401334
if (tmsg < (struct dm_target_msg *) param->data ||
13411335
invalid_str(tmsg->message, (void *) param + param_size)) {
13421336
DMWARN("Invalid target message parameters.");

0 commit comments

Comments
 (0)