block/partitions/msdos.c: code clean-up

checkpatch fixing:
WARNING: Missing a blank line after declarations
WARNING: space prohibited between function name and open parenthesis '('
ERROR: spaces required around that '<' (ctx:VxV)

Cc: Jens Axboe <axboe@kernel.dk>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Fabian Frederick <fabf@skynet.be>
Signed-off-by: Jens Axboe <axboe@fb.com>
This commit is contained in:
Fabian Frederick 2014-06-12 20:16:57 +02:00 committed by Jens Axboe
parent 600ffc5ead
commit dce14c239a

View file

@ -161,6 +161,7 @@ static void parse_extended(struct parsed_partitions *state,
*/ */
for (i = 0; i < 4; i++, p++) { for (i = 0; i < 4; i++, p++) {
sector_t offs, size, next; sector_t offs, size, next;
if (!nr_sects(p) || is_extended_partition(p)) if (!nr_sects(p) || is_extended_partition(p))
continue; continue;
@ -527,6 +528,7 @@ int msdos_partition(struct parsed_partitions *state)
for (slot = 1 ; slot <= 4 ; slot++, p++) { for (slot = 1 ; slot <= 4 ; slot++, p++) {
sector_t start = start_sect(p)*sector_size; sector_t start = start_sect(p)*sector_size;
sector_t size = nr_sects(p)*sector_size; sector_t size = nr_sects(p)*sector_size;
if (!size) if (!size)
continue; continue;
if (is_extended_partition(p)) { if (is_extended_partition(p)) {
@ -537,6 +539,7 @@ int msdos_partition(struct parsed_partitions *state)
* sector, although it may not be enough/proper. * sector, although it may not be enough/proper.
*/ */
sector_t n = 2; sector_t n = 2;
n = min(size, max(sector_size, n)); n = min(size, max(sector_size, n));
put_partition(state, slot, start, n); put_partition(state, slot, start, n);