public inbox for linux-btrfs@vger.kernel.org
 help / color / mirror / Atom feed
* BTRFS_SEARCH_ARGS_BUFSIZE too small
@ 2014-01-09 23:44 Gerhard Heift
  2014-01-15 18:39 ` David Sterba
  0 siblings, 1 reply; 4+ messages in thread
From: Gerhard Heift @ 2014-01-09 23:44 UTC (permalink / raw)
  To: linux-btrfs

Hello,

I'm playing around with the BTRFS_IOC_SEARCH_TREE to extract the csums
of the physical blocks. During the tests some item_header had len = 0,
which indicates the buffer was to small to hold the item. I added a
printk into the kernel to get the original size of the item and it was
around 6600 bytes. Is there another way to get the item? Otherwise I
would suggest to create an ioctl, which is a little bit more flexible,
something like

struct btrfs_ioctl_search_args2 {
        struct btrfs_ioctl_search_key key;
        __u64 buf_len
        char buf[0];
};

Gerhard

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-01-16 15:07 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-01-09 23:44 BTRFS_SEARCH_ARGS_BUFSIZE too small Gerhard Heift
2014-01-15 18:39 ` David Sterba
2014-01-15 19:29   ` Gerhard Heift
2014-01-16 15:07     ` David Sterba

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox