Re: [RFC PATCH v7 1/2] Btrfs: Add a new ioctl to get the label of a mounted file system

2012-12-24 Thread Jeff Liu
On 12/22/2012 01:36 AM, Goffredo Baroncelli wrote: On 12/21/2012 07:42 AM, Jeff Liu wrote: Hi Goffredo, On 12/21/2012 04:18 AM, Goffredo Baroncelli wrote: HI Jeff, On 12/20/2012 09:43 AM, Jeff Liu wrote: With the new ioctl(2) BTRFS_IOC_GET_FSLABEL we can fetch the label of a mounted file

[PATCH V2] Btrfs: flush all dirty inodes if writeback can not start

2012-12-24 Thread Miao Xie
We may try to flush some dirty pages when there is no enough space to reserve. But it is possible that this operation fails, in order to get enough space to reserve successfully, we will sync all the delalloc file. This operation is safe, we needn't worry about the case that the filesystem goes

Re: [RFC PATCH v7 1/2] Btrfs: Add a new ioctl to get the label of a mounted file system

2012-12-24 Thread Goffredo Baroncelli
Hi Jeff, On 12/24/2012 09:07 AM, Jeff Liu wrote: On 12/22/2012 01:36 AM, Goffredo Baroncelli wrote: On 12/21/2012 07:42 AM, Jeff Liu wrote: [...] I don't think we should replace strlen() with strnlen() since it's totally wrong if the length of label is more than BTRFS_LABEL_SIZE -1, we can

Re: [RFC PATCH v7 1/2] Btrfs: Add a new ioctl to get the label of a mounted file system

2012-12-24 Thread Jeff Liu
On 12/24/2012 09:46 PM, Goffredo Baroncelli wrote: Hi Jeff, On 12/24/2012 09:07 AM, Jeff Liu wrote: On 12/22/2012 01:36 AM, Goffredo Baroncelli wrote: On 12/21/2012 07:42 AM, Jeff Liu wrote: [...] I don't think we should replace strlen() with strnlen() since it's totally wrong if the

Re: incomplete erase of btrfs with wipefs

2012-12-24 Thread Goffredo Baroncelli
Hi, Chrism On 12/23/2012 10:11 PM, Chris Murphy wrote: Hi, I'm not completely sure if this is a wipefs bug, or a btrfs(-progs) bug. The gist is that after using wipefs on a btrfs formatted partition, then reformatted as ext4, mount sees it as ext4, parted sees it as ext4, but I btrfs fi

Re: incomplete erase of btrfs with wipefs

2012-12-24 Thread Chris Murphy
On Dec 24, 2012, at 10:52 AM, Goffredo Baroncelli kreij...@gmail.com wrote: Hi, Chrism On 12/23/2012 10:11 PM, Chris Murphy wrote: Hi, I'm not completely sure if this is a wipefs bug, or a btrfs(-progs) bug. The gist is that after using wipefs on a btrfs formatted partition, then