* [PATCH] Btrfs - use %pU to print fsid
@ 2011-02-09 14:05 Ilya Dryomov
2011-03-31 17:14 ` Mitch Harder
2011-06-09 18:02 ` Ilya Dryomov
0 siblings, 2 replies; 4+ messages in thread
From: Ilya Dryomov @ 2011-02-09 14:05 UTC (permalink / raw)
To: linux-btrfs; +Cc: Chris Mason
Get rid of FIXME comment. Uuids from dmesg are now the same as uuids
given by btrfs-progs.
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
---
fs/btrfs/volumes.c | 8 ++------
1 files changed, 2 insertions(+), 6 deletions(-)
diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
index 2636a05..83b789c 100644
--- a/fs/btrfs/volumes.c
+++ b/fs/btrfs/volumes.c
@@ -714,12 +714,8 @@ int btrfs_scan_one_device(const char *path, fmode_t flags, void *holder,
transid = btrfs_super_generation(disk_super);
if (disk_super->label[0])
printk(KERN_INFO "device label %s ", disk_super->label);
- else {
- /* FIXME, make a readl uuid parser */
- printk(KERN_INFO "device fsid %llx-%llx ",
- *(unsigned long long *)disk_super->fsid,
- *(unsigned long long *)(disk_super->fsid + 8));
- }
+ else
+ printk(KERN_INFO "device fsid %pU ", disk_super->fsid);
printk(KERN_CONT "devid %llu transid %llu %s\n",
(unsigned long long)devid, (unsigned long long)transid, path);
ret = device_list_add(path, disk_super, devid, fs_devices_ret);
--
1.7.2.3
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] Btrfs - use %pU to print fsid
2011-02-09 14:05 [PATCH] Btrfs - use %pU to print fsid Ilya Dryomov
@ 2011-03-31 17:14 ` Mitch Harder
2011-03-31 22:21 ` Ilya Dryomov
2011-06-09 18:02 ` Ilya Dryomov
1 sibling, 1 reply; 4+ messages in thread
From: Mitch Harder @ 2011-03-31 17:14 UTC (permalink / raw)
To: Ilya Dryomov; +Cc: linux-btrfs, Chris Mason
On Wed, Feb 9, 2011 at 8:05 AM, Ilya Dryomov <idryomov@gmail.com> wrote=
:
> Get rid of FIXME comment. =A0Uuids from dmesg are now the same as uui=
ds
> given by btrfs-progs.
>
> Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
> ---
> =A0fs/btrfs/volumes.c | =A0 =A08 ++------
> =A01 files changed, 2 insertions(+), 6 deletions(-)
>
> diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
> index 2636a05..83b789c 100644
> --- a/fs/btrfs/volumes.c
> +++ b/fs/btrfs/volumes.c
> @@ -714,12 +714,8 @@ int btrfs_scan_one_device(const char *path, fmod=
e_t flags, void *holder,
> =A0 =A0 =A0 =A0transid =3D btrfs_super_generation(disk_super);
> =A0 =A0 =A0 =A0if (disk_super->label[0])
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0printk(KERN_INFO "device label %s ", d=
isk_super->label);
> - =A0 =A0 =A0 else {
> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 /* FIXME, make a readl uuid parser */
> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 printk(KERN_INFO "device fsid %llx-%llx=
",
> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0*(unsigned long long *)d=
isk_super->fsid,
> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0*(unsigned long long *)(=
disk_super->fsid + 8));
> - =A0 =A0 =A0 }
> + =A0 =A0 =A0 else
> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 printk(KERN_INFO "device fsid %pU ", di=
sk_super->fsid);
> =A0 =A0 =A0 =A0printk(KERN_CONT "devid %llu transid %llu %s\n",
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 (unsigned long long)devid, (unsigned long=
long)transid, path);
> =A0 =A0 =A0 =A0ret =3D device_list_add(path, disk_super, devid, fs_de=
vices_ret);
> --
> 1.7.2.3
>
I've had this patch in my testing stack for a while now, and it's been
working well. The fsid now matches the UUID.
It would be nice if the text string lead off with "Btrfs:" or
"btrfs:". This would be similar to the way other drivers send log
messages, and would make it easier to pick out the Btrfs mount message
from all the other messages.
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" =
in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Btrfs - use %pU to print fsid
2011-03-31 17:14 ` Mitch Harder
@ 2011-03-31 22:21 ` Ilya Dryomov
0 siblings, 0 replies; 4+ messages in thread
From: Ilya Dryomov @ 2011-03-31 22:21 UTC (permalink / raw)
To: Mitch Harder; +Cc: linux-btrfs, Chris Mason
On Thu, Mar 31, 2011 at 12:14:14PM -0500, Mitch Harder wrote:
> On Wed, Feb 9, 2011 at 8:05 AM, Ilya Dryomov <idryomov@gmail.com> wro=
te:
> > Get rid of FIXME comment. =C2=A0Uuids from dmesg are now the same a=
s uuids
> > given by btrfs-progs.
> >
> > Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
> > ---
> > =C2=A0fs/btrfs/volumes.c | =C2=A0 =C2=A08 ++------
> > =C2=A01 files changed, 2 insertions(+), 6 deletions(-)
> >
> > diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
> > index 2636a05..83b789c 100644
> > --- a/fs/btrfs/volumes.c
> > +++ b/fs/btrfs/volumes.c
> > @@ -714,12 +714,8 @@ int btrfs_scan_one_device(const char *path, fm=
ode_t flags, void *holder,
> > =C2=A0 =C2=A0 =C2=A0 =C2=A0transid =3D btrfs_super_generation(disk_=
super);
> > =C2=A0 =C2=A0 =C2=A0 =C2=A0if (disk_super->label[0])
> > =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0printk(KERN_=
INFO "device label %s ", disk_super->label);
> > - =C2=A0 =C2=A0 =C2=A0 else {
> > - =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 /* FIXME, make a=
readl uuid parser */
> > - =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 printk(KERN_INFO=
"device fsid %llx-%llx ",
> > - =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0*(unsigned long long *)disk_super->fsid,
> > - =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=
=A0 =C2=A0*(unsigned long long *)(disk_super->fsid + 8));
> > - =C2=A0 =C2=A0 =C2=A0 }
> > + =C2=A0 =C2=A0 =C2=A0 else
> > + =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 printk(KERN_INFO=
"device fsid %pU ", disk_super->fsid);
> > =C2=A0 =C2=A0 =C2=A0 =C2=A0printk(KERN_CONT "devid %llu transid %ll=
u %s\n",
> > =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (unsigned long lon=
g)devid, (unsigned long long)transid, path);
> > =C2=A0 =C2=A0 =C2=A0 =C2=A0ret =3D device_list_add(path, disk_super=
, devid, fs_devices_ret);
> > --
> > 1.7.2.3
> >
>=20
> I've had this patch in my testing stack for a while now, and it's bee=
n
> working well. The fsid now matches the UUID.
Chris for some reason didn't add it to the pull request, probably
because it's minor.
> It would be nice if the text string lead off with "Btrfs:" or
> "btrfs:". This would be similar to the way other drivers send log
> messages, and would make it easier to pick out the Btrfs mount messag=
e
> from all the other messages.
Currently there is a mix: some of the messages are printed with
"btrfs:", others with "btrfs", most of the messages informing about
abnormal conditions are printed w/o any prefix. I can resend this one
with "btrfs:" prefix, but I think some kind of decision needed, so this
whole thing can be fixed in one commit.
Thanks,
Ilya
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" =
in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Btrfs - use %pU to print fsid
2011-02-09 14:05 [PATCH] Btrfs - use %pU to print fsid Ilya Dryomov
2011-03-31 17:14 ` Mitch Harder
@ 2011-06-09 18:02 ` Ilya Dryomov
1 sibling, 0 replies; 4+ messages in thread
From: Ilya Dryomov @ 2011-06-09 18:02 UTC (permalink / raw)
To: linux-btrfs; +Cc: Chris Mason
Hi Chris,
Can you pull this into the next -rc ? It's minor, but people think it's
useful. I just had another person asking about this patch.
Thanks,
Ilya
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2011-06-09 18:02 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-09 14:05 [PATCH] Btrfs - use %pU to print fsid Ilya Dryomov
2011-03-31 17:14 ` Mitch Harder
2011-03-31 22:21 ` Ilya Dryomov
2011-06-09 18:02 ` Ilya Dryomov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).