| To: | Eric Sandeen <sandeen@xxxxxxxxxxx> |
|---|---|
| Subject: | Re: [PATCH 15/19] mkfs: don't treat files as though they are block devices |
| From: | Jan Tulak <jtulak@xxxxxxxxxx> |
| Date: | Thu, 21 Apr 2016 11:22:02 +0200 |
| Cc: | xfs-oss <xfs@xxxxxxxxxxx> |
| Delivered-to: | xfs@xxxxxxxxxxx |
| In-reply-to: | <5717B3F7.2030904@xxxxxxxxxxx> |
| References: | <1458818136-56043-1-git-send-email-jtulak@xxxxxxxxxx> <1458818136-56043-16-git-send-email-jtulak@xxxxxxxxxx> <5706FA7C.7020103@xxxxxxxxxxx> <CACj3i73JEzCj-4kp3=H9mjXCKYgcOUYCOyq-aZSWZFXUih+0MA@xxxxxxxxxxxxxx> <CACj3i722h=WVW-637__y6fi4EekAxxB=cwL8y+F1r1LFk-Z5rw@xxxxxxxxxxxxxx> <CACj3i71Ff2KS682DRP8zG76ee6rhz3X-NZKst1qsruMZKWaHJA@xxxxxxxxxxxxxx> <CACj3i73jk5HjRuRRF7hnX0WoOv0amq-CduAwoHbhoT-=+hTREA@xxxxxxxxxxxxxx> <5717B3F7.2030904@xxxxxxxxxxx> |
On 4/20/16 9:17 AM, Jan Tulak wrote: âand revert this patch to the Dave's version. â ÂI don't get any problems with "mkfs.xfs file" for an existing file, âI bisected it and the issue was really caused by this patch in Dave's version. But luckily, the fix is as simple as: @@ -278,6 +278,8 @@ libxfs_init(libxfs_init_t *a)             a->ddev= libxfs_device_open(dname, a->dcreat, flags,                           a->setblksize);             a->dfd = libxfs_device_to_fd(a->ddev); +            platform_findsizes(dname, a->dfd, &a->dsize, +                        &a->dbsize);         } else {             if (!check_open(dname, flags, &rawfile, &blockfile))                 goto done;â â(and dtto for log/rt variants).â I'm going to send for review what I have, and work on the remaining issues in the meantime. Unless I find something else, the last thing to fix is that it changes the size of the file on -d size=xxx, even when O_TRUNCATE is not used (that is, no -d file is specified). Old behaviour was to keep the file size and just don't use the entire file. This affects xfs/206 and xfs/216. Jan Â
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | ÐÐÐÐÑÐÐÑÐÐÐÑÐ ÐÐÑÐÐÐÐÐÐ ÑÐÑÑÐÐÑÐÐÑ ÐÐÑÐÐÐÐÑÐÐÐÐ., ÐÑÐÐÐÐÐÐÑÐÑ ÑÐÐÐÑÐÐÐÐÐÐÐÐÑ |
|---|---|
| Next by Date: | [PATCH 00/19 v2] mkfs cleaning, Jan Tulak |
| Previous by Thread: | Re: [PATCH 15/19] mkfs: don't treat files as though they are block devices, Eric Sandeen |
| Next by Thread: | Ich bitte um Ihre Unterstuetzung!!, Angela Odum |
| Indexes: | [Date] [Thread] [Top] [All Lists] |