From: Karel Zak <kzak@redhat.com>
To: Alejandro Martinez Ruiz <alex@nowcomputing.com>
Cc: util-linux@vger.kernel.org
Subject: Re: [PATCH 1/2] libblkid: add Flash-Friendly File System (f2fs) support
Date: Wed, 6 Feb 2013 12:23:45 +0100 [thread overview]
Message-ID: <20130206112345.GA7212@x2.net.home> (raw)
In-Reply-To: <1360083607-29885-2-git-send-email-alex@nowcomputing.com>
On Tue, Feb 05, 2013 at 06:00:06PM +0100, Alejandro Martinez Ruiz wrote:
> +static int probe_f2fs(blkid_probe pr, const struct blkid_idmag *mag)
> +{
> + struct f2fs_super_block *sb;
> + uint16_t major, minor;
> +
> + sb = blkid_probe_get_sb(pr, mag, struct f2fs_super_block);
> + if (!sb)
> + return -1;
> +
> + major = le16_to_cpu(sb->major_ver);
> + minor = le16_to_cpu(sb->minor_ver);
> +
> + /* For version 1.0 we cannot know the correct sb structure */
> + if (major == 1 && minor == 0)
> + return 0;
> +
> + if (*((unsigned char *) sb->volume_name))
> + blkid_probe_set_utf8label(pr, (unsigned char *) sb->volume_name,
> + sizeof(sb->volume_name),
> + BLKID_ENC_UTF16LE);
> +
> + blkid_probe_set_uuid(pr, sb->uuid);
> + blkid_probe_sprintf_version(pr, "%u.%u", major, minor);
return 0;
> +}
Fixed, applied. Thanks.
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
next prev parent reply other threads:[~2013-02-06 11:23 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-05 17:00 libblkid: add f2fs support Alejandro Martinez Ruiz
2013-02-05 17:00 ` [PATCH 1/2] libblkid: add Flash-Friendly File System (f2fs) support Alejandro Martinez Ruiz
2013-02-06 11:23 ` Karel Zak [this message]
2013-02-05 17:00 ` [PATCH 2/2] tests: add f2fs image test Alejandro Martinez Ruiz
2013-02-06 11:24 ` Karel Zak
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130206112345.GA7212@x2.net.home \
--to=kzak@redhat.com \
--cc=alex@nowcomputing.com \
--cc=util-linux@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox