All of lore.kernel.org
 help / color / mirror / Atom feed
From: Anand Jain <Anand.Jain@oracle.com>
To: dsterba@suse.cz, linux-btrfs@vger.kernel.org
Subject: Re: [PATCH] btrfs-progs: force overwrite should wipe stale SB
Date: Wed, 01 Oct 2014 19:45:10 +0800	[thread overview]
Message-ID: <542BE946.8020500@oracle.com> (raw)
In-Reply-To: <20141001112606.GO11436@twin.jikos.cz>



On 10/01/2014 07:26 PM, David Sterba wrote:
> On Fri, Sep 05, 2014 at 11:51:24PM +0800, Anand Jain wrote:
>> +static void wipe_existing_fs(int fd)
>> +{
> ...
>> +	blkid_probe_enable_partitions(pr, 1);
>> +
>> +	while (blkid_do_probe(pr) == 0)
>> +		blkid_do_wipe(pr, 0);
>
> Reported by a user on IRC, I verified it on one of my old test boxes.
> The function is missing in older versions of blkid and causes comilation
> errors:
>
>      [CC]     utils.o
> utils.c: In function ‘wipe_existing_fs’:
> utils.c:705:3: warning: implicit declaration of function ‘blkid_do_wipe
>
> utils.o: In function `wipe_existing_fs':
> /labs/dsterba/btrfs-progs/utils.c:705: undefined reference to `blkid_do_wipe'
> collect2: ld returned 1 exit status
 >
> blkid_do_wipe is from Novembe 2011, so nothing really new, but I'd still
> like to keep the backward compatibility of btrfs-progs.  The

> implementation of blkid_do_wipe uses some internal data so it's not
> possible to simply copy the implementation. Maybe wiping the first
> megabyte is enough.

  for the sake of backward compatible.. the only choice I see as of now
  yes to write our own wipe. will send one.

Anand


> --
> 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
>

  reply	other threads:[~2014-10-01 11:40 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-05 15:51 [PATCH] btrfs-progs: force overwrite should wipe stale SB Anand Jain
2014-09-15 16:15 ` David Sterba
2014-10-01 11:26 ` David Sterba
2014-10-01 11:45   ` Anand Jain [this message]
2014-10-01 23:22   ` [PATCH v2] " Anand Jain
2014-10-10  7:39     ` David Sterba
2014-10-10  7:47       ` Anand Jain

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=542BE946.8020500@oracle.com \
    --to=anand.jain@oracle.com \
    --cc=dsterba@suse.cz \
    --cc=linux-btrfs@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 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.