linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Hans van Kranenburg <hans.van.kranenburg@mendix.com>
To: Timofey Titovets <nefelim4ag@gmail.com>,
	linux-btrfs <linux-btrfs@vger.kernel.org>
Subject: Re: RFC: Btrfs does not store checksum type? Only size? O_o
Date: Wed, 20 Sep 2017 22:45:25 +0200	[thread overview]
Message-ID: <fd5c3de5-bf9a-171c-35e8-6c1ffc1da398@mendix.com> (raw)
In-Reply-To: <CAGqmi76MPGYFiksk5Jt05wjhQoQXpQuu1CiJFhxQw8QEB0gPpw@mail.gmail.com>

On 09/20/2017 10:31 PM, Timofey Titovets wrote:
> I was reading the kernel code and docs and didn't find anything about
> some info like "cheksum type" as btrfs have for compression code.
> (I only found some silent "hack" in btrfs-progs, that print "checksum
> type", but get "checksum size")
> 
> If i understood all correctly btrfs only store checksum size, i.e. 4
> for current CRC32C.

The checksum type is set in the superblock:

csum_type		0 (crc32c)
csum_size		4
[...]

So in the current design, you probably could have different checksum
types, but you will have to choose one of them when creating a filesystem.

-- 
Hans van Kranenburg

  reply	other threads:[~2017-09-20 20:45 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-20 20:31 RFC: Btrfs does not store checksum type? Only size? O_o Timofey Titovets
2017-09-20 20:45 ` Hans van Kranenburg [this message]
2017-09-20 23:27 ` Qu Wenruo

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=fd5c3de5-bf9a-171c-35e8-6c1ffc1da398@mendix.com \
    --to=hans.van.kranenburg@mendix.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=nefelim4ag@gmail.com \
    /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;
as well as URLs for NNTP newsgroup(s).