diff options
author | Pedro F. Giffuni <pfg@FreeBSD.org> | 2017-02-23 15:05:01 +0000 |
---|---|---|
committer | Pedro F. Giffuni <pfg@FreeBSD.org> | 2017-02-23 15:05:01 +0000 |
commit | 95c10b8fa097297f9b7e4c4faf9fb32a3ccafa44 (patch) | |
tree | 0a1b6374237efc4f0181921c68bf7365b4119c46 /usr.sbin/camdd/camdd.c | |
parent | adbb8a93d6908cb7a8caa5626e297b2b0122f4c2 (diff) | |
download | src-test2-95c10b8fa097297f9b7e4c4faf9fb32a3ccafa44.tar.gz src-test2-95c10b8fa097297f9b7e4c4faf9fb32a3ccafa44.zip |
camdd(8): double assignment.
Why do a calculation twice when you can do it just once.
Found with: coccinelle (da.cocci)
Notes
Notes:
svn path=/head/; revision=314140
Diffstat (limited to 'usr.sbin/camdd/camdd.c')
-rw-r--r-- | usr.sbin/camdd/camdd.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/usr.sbin/camdd/camdd.c b/usr.sbin/camdd/camdd.c index 05225f6a86e5..e360723d82a0 100644 --- a/usr.sbin/camdd/camdd.c +++ b/usr.sbin/camdd/camdd.c @@ -3107,10 +3107,6 @@ camdd_rw(struct camdd_io_opts *io_opts, int num_io_opts, uint64_t max_io, (devs[i]->start_offset_bytes / devs[i]->sector_size) + (max_io / devs[i]->sector_size) - 1; - devs[i]->sector_io_limit = - (devs[i]->start_offset_bytes / - devs[i]->sector_size) + - (max_io / devs[i]->sector_size) - 1; } devs[i]->next_io_pos_bytes = devs[i]->start_offset_bytes; |