commit | d7e6db20944c8fb26073bc3ba9d5328992b82858 | [log] [tgz] |
---|---|---|
author | Damien Le Moal <damien.lemoal@wdc.com> | Wed Jan 30 16:07:34 2019 +0900 |
committer | Martin K. Petersen <martin.petersen@oracle.com> | Mon Feb 04 22:07:24 2019 -0500 |
tree | 2fcc6f26bb7b30d006713d8129c3b5ee26d0ac9c | |
parent | 27752647f88a1b03019e03f21f32b60452af7d4b [diff] |
scsi: sd: Improve sd_print_capacity() There is no need to call twice string_get_size() when the capacity messages are not going to be printed. Reverse the message output condition to return early and avoid executing string_get_size() when it is not necessary. Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>