[PATCH] ebgpart: Reword information during partition scan

2 views
Skip to first unread message

Andreas J. Reichel

unread,
Sep 11, 2018, 7:42:31 AM9/11/18
to efibootg...@googlegroups.com, Andreas Reichel
From: Andreas Reichel <andreas.r...@siemens.com>

During system-update, a lot of 'errors' are printed out, which
are not 'errors' in the sense of failing but are normal during
partition scanning. Reword these to 'Cannot ... skipping...'

Signed-off-by: Andreas Reichel <andreas.r...@siemens.com>
---
tools/ebgpart.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/tools/ebgpart.c b/tools/ebgpart.c
index eabf5d0..471c2df 100644
--- a/tools/ebgpart.c
+++ b/tools/ebgpart.c
@@ -270,16 +270,17 @@ static bool check_partition_table(PedDevice *dev)
VERBOSE(stdout, "Checking %s\n", dev->path);
fd = open(dev->path, O_RDONLY);
if (fd < 0) {
- VERBOSE(stderr, "Error opening block device.\n");
+ VERBOSE(stderr, "Cannot open block device, skipping...\n");
return false;
}
if (read(fd, &mbr, sizeof(mbr)) != sizeof(mbr)) {
- VERBOSE(stderr, "Error reading mbr on %s.\n", dev->path);
+ VERBOSE(stderr, "Cannot read MBR on %s, skipping...\n",
+ dev->path);
close(fd);
return false;
};
if (mbr.mbrsignature != 0xaa55) {
- VERBOSE(stderr, "Error, MBR has wrong signature.\n");
+ VERBOSE(stderr, "No valid MBR signature found, skipping...\n");
close(fd);
return false;
}
--
2.18.0

Jan Kiszka

unread,
Sep 11, 2018, 10:33:56 AM9/11/18
to [ext] Andreas J. Reichel, efibootg...@googlegroups.com
Thanks, applied.

Jan

--
Siemens AG, Corporate Technology, CT RDA IOT SES-DE
Corporate Competence Center Embedded Linux
Reply all
Reply to author
Forward
0 new messages