summaryrefslogtreecommitdiff
path: root/super1.c
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.de>2015-02-12 13:21:17 +1100
committerNeilBrown <neilb@suse.de>2015-02-12 13:21:17 +1100
commit1ade5cc15a61c6fe3084c5170934e05e9a574843 (patch)
treecef09af9a834857dc8d5929573784583cf35902d /super1.c
parentd56dd607ba433d9334f0fb4114fe081742ae4361 (diff)
downloadmdadm-1ade5cc15a61c6fe3084c5170934e05e9a574843.tar.gz
Consistently print program Name and __func__ in debug messages.
make dprintf() print program name and __func__, so that this messaging is consistent. Also remove all __func__ messages from pr_err(). We shouldn't leak that internal data in error message. If we really want function name there, we new pr_XXX might be wanted. Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'super1.c')
-rw-r--r--super1.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/super1.c b/super1.c
index cff021d..0fd84e2 100644
--- a/super1.c
+++ b/super1.c
@@ -811,7 +811,7 @@ static int examine_badblocks_super1(struct supertype *st, int fd, char *devname)
size = __le32_to_cpu(sb->bblog_size)* 512;
if (posix_memalign((void**)&bbl, 4096, size) != 0) {
- pr_err("%s could not allocate badblocks list\n", __func__);
+ pr_err("could not allocate badblocks list\n");
return 0;
}
offset = __le64_to_cpu(sb->super_offset) +
@@ -1328,7 +1328,7 @@ static int init_super1(struct supertype *st, mdu_array_info_t *info,
int sbsize;
if (posix_memalign((void**)&sb, 4096, SUPER1_SIZE) != 0) {
- pr_err("%s could not allocate superblock\n", __func__);
+ pr_err("could not allocate superblock\n");
return 0;
}
memset(sb, 0, SUPER1_SIZE);
@@ -1726,7 +1726,7 @@ static int compare_super1(struct supertype *st, struct supertype *tst)
if (!first) {
if (posix_memalign((void**)&first, 4096, SUPER1_SIZE) != 0) {
- pr_err("%s could not allocate superblock\n", __func__);
+ pr_err("could not allocate superblock\n");
return 1;
}
memcpy(first, second, SUPER1_SIZE);
@@ -1837,8 +1837,7 @@ static int load_super1(struct supertype *st, int fd, char *devname)
}
if (posix_memalign((void**)&super, 4096, SUPER1_SIZE) != 0) {
- pr_err("%s could not allocate superblock\n",
- __func__);
+ pr_err("could not allocate superblock\n");
return 1;
}