summaryrefslogtreecommitdiff
path: root/block/partitions/check.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2020-03-24 10:25:20 +0300
committerJens Axboe <axboe@kernel.dk>2020-03-24 16:57:08 +0300
commitffa9ed647aa4cda79fa8cb9583a566e9d777dd4c (patch)
tree217352f1f75e3511ecb2f7906c1acd02c03f2aed /block/partitions/check.c
parent74cc979c3c7f8328b24651daf15280f07533e735 (diff)
downloadlinux-ffa9ed647aa4cda79fa8cb9583a566e9d777dd4c.tar.xz
block: remove warn_no_part
The warn_no_part is initialized to 1 and never changed. Remove it and execute the code keyed off from it unconditionally. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/partitions/check.c')
-rw-r--r--block/partitions/check.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/block/partitions/check.c b/block/partitions/check.c
index ffe408fead0c..8fe46881ef63 100644
--- a/block/partitions/check.c
+++ b/block/partitions/check.c
@@ -37,8 +37,6 @@
#include "sysv68.h"
#include "cmdline.h"
-int warn_no_part = 1; /*This is ugly: should make genhd removable media aware*/
-
static int (*check_part[])(struct parsed_partitions *) = {
/*
* Probe partition formats with tables at disk address 0
@@ -186,9 +184,8 @@ check_partition(struct gendisk *hd, struct block_device *bdev)
/* The partition is unrecognized. So report I/O errors if there were any */
res = err;
if (res) {
- if (warn_no_part)
- strlcat(state->pp_buf,
- " unable to read partition table\n", PAGE_SIZE);
+ strlcat(state->pp_buf,
+ " unable to read partition table\n", PAGE_SIZE);
printk(KERN_INFO "%s", state->pp_buf);
}