From: Goffredo Baroncelli <kreijack@inwind.it>
To: Qu Wenruo <quwenruo.btrfs@gmx.com>,
Anand Jain <anand.jain@oracle.com>, Moviuro <moviuro@gmail.com>,
linux-btrfs@vger.kernel.org
Subject: Re: btrfs-progs and btrfs(8) inconsistencies
Date: Sun, 7 Feb 2016 21:26:09 +0100 [thread overview]
Message-ID: <56B7A861.2060802@inwind.it> (raw)
In-Reply-To: <56B71777.7050609@gmx.com>
On 2016-02-07 11:07, Qu Wenruo wrote:
> +1 too.
>
> But first in C, then python wrapper.
>
> Not sure why there is no such libbtrfs for C wrapper of btrfs ioctls.
>
> Maybe just because current btrfs ioctl is too easy to use?
Unfortunately no.
I think the main problem of writing a libbtrfs, is the code changes needed.
In fact in order to avoid code duplication (and to have more testing), the btrfs command has to be a client of libbtrfs. But it is not easy: you have to refactoring the error handling and the message printing...
> AFAIK, systemd (container storage part) calls btrfs ioctl directly, especially for subvolume/snapshot creation mainly > because the design of them are quite easy.
Also udev does the same (I don't remember if this happened before or after it went under the systemd umbrella).
I remember a case where it was impossible to change the semantic of BTRFS_IOC_DEVICES_READY: on the basis of its name, it could be seems that this ioctl should _only_ check if a filesystem is ready. Unfortunately it register also the device [1].
It was discussed in the ML to change its semantic, but having already widespread client like udev it was impossible to do (even tough we could discuss to change their name)
> Thanks,
> Qu
BR
G.Baroncelli
[1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=772744
next prev parent reply other threads:[~2016-02-07 20:26 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-03 21:54 btrfs-progs and btrfs(8) inconsistencies Moviuro
2016-02-04 1:33 ` Qu Wenruo
2016-02-04 8:57 ` Moviuro
2016-02-04 9:15 ` Qu Wenruo
2016-02-04 10:14 ` Martin Steigerwald
2016-02-04 12:04 ` Moviuro
2016-02-04 12:53 ` Austin S. Hemmelgarn
2016-02-04 19:40 ` Chris Murphy
2016-02-04 20:19 ` Austin S. Hemmelgarn
2016-02-04 20:40 ` Moviuro
2016-02-05 13:04 ` Austin S. Hemmelgarn
2016-02-04 17:17 ` Goffredo Baroncelli
2016-02-04 19:48 ` Hugo Mills
2016-02-04 20:10 ` Chris Murphy
2016-02-04 18:22 ` Chris Murphy
2016-02-05 3:11 ` Anand Jain
2016-02-05 12:59 ` Austin S. Hemmelgarn
2016-02-06 21:35 ` Chris Murphy
2016-02-07 10:07 ` Qu Wenruo
2016-02-07 20:26 ` Goffredo Baroncelli [this message]
2016-03-08 16:02 ` David Sterba
2016-03-09 10:02 ` Moviuro
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=56B7A861.2060802@inwind.it \
--to=kreijack@inwind.it \
--cc=anand.jain@oracle.com \
--cc=linux-btrfs@vger.kernel.org \
--cc=moviuro@gmail.com \
--cc=quwenruo.btrfs@gmx.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.