linux/fs/nilfs2/ioctl.c
<<
>>
Prefs
   1/*
   2 * ioctl.c - NILFS ioctl operations.
   3 *
   4 * Copyright (C) 2007, 2008 Nippon Telegraph and Telephone Corporation.
   5 *
   6 * This program is free software; you can redistribute it and/or modify
   7 * it under the terms of the GNU General Public License as published by
   8 * the Free Software Foundation; either version 2 of the License, or
   9 * (at your option) any later version.
  10 *
  11 * This program is distributed in the hope that it will be useful,
  12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
  13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  14 * GNU General Public License for more details.
  15 *
  16 * You should have received a copy of the GNU General Public License
  17 * along with this program; if not, write to the Free Software
  18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
  19 *
  20 * Written by Koji Sato <koji@osrg.net>.
  21 */
  22
  23#include <linux/fs.h>
  24#include <linux/wait.h>
  25#include <linux/slab.h>
  26#include <linux/capability.h>   /* capable() */
  27#include <linux/uaccess.h>      /* copy_from_user(), copy_to_user() */
  28#include <linux/vmalloc.h>
  29#include <linux/compat.h>       /* compat_ptr() */
  30#include <linux/mount.h>        /* mnt_want_write_file(), mnt_drop_write_file() */
  31#include <linux/buffer_head.h>
  32#include <linux/nilfs2_fs.h>
  33#include "nilfs.h"
  34#include "segment.h"
  35#include "bmap.h"
  36#include "cpfile.h"
  37#include "sufile.h"
  38#include "dat.h"
  39
  40
  41static int nilfs_ioctl_wrap_copy(struct the_nilfs *nilfs,
  42                                 struct nilfs_argv *argv, int dir,
  43                                 ssize_t (*dofunc)(struct the_nilfs *,
  44                                                   __u64 *, int,
  45                                                   void *, size_t, size_t))
  46{
  47        void *buf;
  48        void __user *base = (void __user *)(unsigned long)argv->v_base;
  49        size_t maxmembs, total, n;
  50        ssize_t nr;
  51        int ret, i;
  52        __u64 pos, ppos;
  53
  54        if (argv->v_nmembs == 0)
  55                return 0;
  56
  57        if (argv->v_size > PAGE_SIZE)
  58                return -EINVAL;
  59
  60        buf = (void *)__get_free_pages(GFP_NOFS, 0);
  61        if (unlikely(!buf))
  62                return -ENOMEM;
  63        maxmembs = PAGE_SIZE / argv->v_size;
  64
  65        ret = 0;
  66        total = 0;
  67        pos = argv->v_index;
  68        for (i = 0; i < argv->v_nmembs; i += n) {
  69                n = (argv->v_nmembs - i < maxmembs) ?
  70                        argv->v_nmembs - i : maxmembs;
  71                if ((dir & _IOC_WRITE) &&
  72                    copy_from_user(buf, base + argv->v_size * i,
  73                                   argv->v_size * n)) {
  74                        ret = -EFAULT;
  75                        break;
  76                }
  77                ppos = pos;
  78                nr = dofunc(nilfs, &pos, argv->v_flags, buf, argv->v_size,
  79                               n);
  80                if (nr < 0) {
  81                        ret = nr;
  82                        break;
  83                }
  84                if ((dir & _IOC_READ) &&
  85                    copy_to_user(base + argv->v_size * i, buf,
  86                                 argv->v_size * nr)) {
  87                        ret = -EFAULT;
  88                        break;
  89                }
  90                total += nr;
  91                if ((size_t)nr < n)
  92                        break;
  93                if (pos == ppos)
  94                        pos += n;
  95        }
  96        argv->v_nmembs = total;
  97
  98        free_pages((unsigned long)buf, 0);
  99        return ret;
 100}
 101
 102static int nilfs_ioctl_getflags(struct inode *inode, void __user *argp)
 103{
 104        unsigned int flags = NILFS_I(inode)->i_flags & FS_FL_USER_VISIBLE;
 105
 106        return put_user(flags, (int __user *)argp);
 107}
 108
 109static int nilfs_ioctl_setflags(struct inode *inode, struct file *filp,
 110                                void __user *argp)
 111{
 112        struct nilfs_transaction_info ti;
 113        unsigned int flags, oldflags;
 114        int ret;
 115
 116        if (!inode_owner_or_capable(inode))
 117                return -EACCES;
 118
 119        if (get_user(flags, (int __user *)argp))
 120                return -EFAULT;
 121
 122        ret = mnt_want_write_file(filp);
 123        if (ret)
 124                return ret;
 125
 126        flags = nilfs_mask_flags(inode->i_mode, flags);
 127
 128        mutex_lock(&inode->i_mutex);
 129
 130        oldflags = NILFS_I(inode)->i_flags;
 131
 132        /*
 133         * The IMMUTABLE and APPEND_ONLY flags can only be changed by the
 134         * relevant capability.
 135         */
 136        ret = -EPERM;
 137        if (((flags ^ oldflags) & (FS_APPEND_FL | FS_IMMUTABLE_FL)) &&
 138            !capable(CAP_LINUX_IMMUTABLE))
 139                goto out;
 140
 141        ret = nilfs_transaction_begin(inode->i_sb, &ti, 0);
 142        if (ret)
 143                goto out;
 144
 145        NILFS_I(inode)->i_flags = (oldflags & ~FS_FL_USER_MODIFIABLE) |
 146                (flags & FS_FL_USER_MODIFIABLE);
 147
 148        nilfs_set_inode_flags(inode);
 149        inode->i_ctime = CURRENT_TIME;
 150        if (IS_SYNC(inode))
 151                nilfs_set_transaction_flag(NILFS_TI_SYNC);
 152
 153        nilfs_mark_inode_dirty(inode);
 154        ret = nilfs_transaction_commit(inode->i_sb);
 155out:
 156        mutex_unlock(&inode->i_mutex);
 157        mnt_drop_write_file(filp);
 158        return ret;
 159}
 160
 161static int nilfs_ioctl_getversion(struct inode *inode, void __user *argp)
 162{
 163        return put_user(inode->i_generation, (int __user *)argp);
 164}
 165
 166static int nilfs_ioctl_change_cpmode(struct inode *inode, struct file *filp,
 167                                     unsigned int cmd, void __user *argp)
 168{
 169        struct the_nilfs *nilfs = inode->i_sb->s_fs_info;
 170        struct nilfs_transaction_info ti;
 171        struct nilfs_cpmode cpmode;
 172        int ret;
 173
 174        if (!capable(CAP_SYS_ADMIN))
 175                return -EPERM;
 176
 177        ret = mnt_want_write_file(filp);
 178        if (ret)
 179                return ret;
 180
 181        ret = -EFAULT;
 182        if (copy_from_user(&cpmode, argp, sizeof(cpmode)))
 183                goto out;
 184
 185        mutex_lock(&nilfs->ns_snapshot_mount_mutex);
 186
 187        nilfs_transaction_begin(inode->i_sb, &ti, 0);
 188        ret = nilfs_cpfile_change_cpmode(
 189                nilfs->ns_cpfile, cpmode.cm_cno, cpmode.cm_mode);
 190        if (unlikely(ret < 0))
 191                nilfs_transaction_abort(inode->i_sb);
 192        else
 193                nilfs_transaction_commit(inode->i_sb); /* never fails */
 194
 195        mutex_unlock(&nilfs->ns_snapshot_mount_mutex);
 196out:
 197        mnt_drop_write_file(filp);
 198        return ret;
 199}
 200
 201static int
 202nilfs_ioctl_delete_checkpoint(struct inode *inode, struct file *filp,
 203                              unsigned int cmd, void __user *argp)
 204{
 205        struct the_nilfs *nilfs = inode->i_sb->s_fs_info;
 206        struct nilfs_transaction_info ti;
 207        __u64 cno;
 208        int ret;
 209
 210        if (!capable(CAP_SYS_ADMIN))
 211                return -EPERM;
 212
 213        ret = mnt_want_write_file(filp);
 214        if (ret)
 215                return ret;
 216
 217        ret = -EFAULT;
 218        if (copy_from_user(&cno, argp, sizeof(cno)))
 219                goto out;
 220
 221        nilfs_transaction_begin(inode->i_sb, &ti, 0);
 222        ret = nilfs_cpfile_delete_checkpoint(nilfs->ns_cpfile, cno);
 223        if (unlikely(ret < 0))
 224                nilfs_transaction_abort(inode->i_sb);
 225        else
 226                nilfs_transaction_commit(inode->i_sb); /* never fails */
 227out:
 228        mnt_drop_write_file(filp);
 229        return ret;
 230}
 231
 232static ssize_t
 233nilfs_ioctl_do_get_cpinfo(struct the_nilfs *nilfs, __u64 *posp, int flags,
 234                          void *buf, size_t size, size_t nmembs)
 235{
 236        int ret;
 237
 238        down_read(&nilfs->ns_segctor_sem);
 239        ret = nilfs_cpfile_get_cpinfo(nilfs->ns_cpfile, posp, flags, buf,
 240                                      size, nmembs);
 241        up_read(&nilfs->ns_segctor_sem);
 242        return ret;
 243}
 244
 245static int nilfs_ioctl_get_cpstat(struct inode *inode, struct file *filp,
 246                                  unsigned int cmd, void __user *argp)
 247{
 248        struct the_nilfs *nilfs = inode->i_sb->s_fs_info;
 249        struct nilfs_cpstat cpstat;
 250        int ret;
 251
 252        down_read(&nilfs->ns_segctor_sem);
 253        ret = nilfs_cpfile_get_stat(nilfs->ns_cpfile, &cpstat);
 254        up_read(&nilfs->ns_segctor_sem);
 255        if (ret < 0)
 256                return ret;
 257
 258        if (copy_to_user(argp, &cpstat, sizeof(cpstat)))
 259                ret = -EFAULT;
 260        return ret;
 261}
 262
 263static ssize_t
 264nilfs_ioctl_do_get_suinfo(struct the_nilfs *nilfs, __u64 *posp, int flags,
 265                          void *buf, size_t size, size_t nmembs)
 266{
 267        int ret;
 268
 269        down_read(&nilfs->ns_segctor_sem);
 270        ret = nilfs_sufile_get_suinfo(nilfs->ns_sufile, *posp, buf, size,
 271                                      nmembs);
 272        up_read(&nilfs->ns_segctor_sem);
 273        return ret;
 274}
 275
 276static int nilfs_ioctl_get_sustat(struct inode *inode, struct file *filp,
 277                                  unsigned int cmd, void __user *argp)
 278{
 279        struct the_nilfs *nilfs = inode->i_sb->s_fs_info;
 280        struct nilfs_sustat sustat;
 281        int ret;
 282
 283        down_read(&nilfs->ns_segctor_sem);
 284        ret = nilfs_sufile_get_stat(nilfs->ns_sufile, &sustat);
 285        up_read(&nilfs->ns_segctor_sem);
 286        if (ret < 0)
 287                return ret;
 288
 289        if (copy_to_user(argp, &sustat, sizeof(sustat)))
 290                ret = -EFAULT;
 291        return ret;
 292}
 293
 294static ssize_t
 295nilfs_ioctl_do_get_vinfo(struct the_nilfs *nilfs, __u64 *posp, int flags,
 296                         void *buf, size_t size, size_t nmembs)
 297{
 298        int ret;
 299
 300        down_read(&nilfs->ns_segctor_sem);
 301        ret = nilfs_dat_get_vinfo(nilfs->ns_dat, buf, size, nmembs);
 302        up_read(&nilfs->ns_segctor_sem);
 303        return ret;
 304}
 305
 306static ssize_t
 307nilfs_ioctl_do_get_bdescs(struct the_nilfs *nilfs, __u64 *posp, int flags,
 308                          void *buf, size_t size, size_t nmembs)
 309{
 310        struct nilfs_bmap *bmap = NILFS_I(nilfs->ns_dat)->i_bmap;
 311        struct nilfs_bdesc *bdescs = buf;
 312        int ret, i;
 313
 314        down_read(&nilfs->ns_segctor_sem);
 315        for (i = 0; i < nmembs; i++) {
 316                ret = nilfs_bmap_lookup_at_level(bmap,
 317                                                 bdescs[i].bd_offset,
 318                                                 bdescs[i].bd_level + 1,
 319                                                 &bdescs[i].bd_blocknr);
 320                if (ret < 0) {
 321                        if (ret != -ENOENT) {
 322                                up_read(&nilfs->ns_segctor_sem);
 323                                return ret;
 324                        }
 325                        bdescs[i].bd_blocknr = 0;
 326                }
 327        }
 328        up_read(&nilfs->ns_segctor_sem);
 329        return nmembs;
 330}
 331
 332static int nilfs_ioctl_get_bdescs(struct inode *inode, struct file *filp,
 333                                  unsigned int cmd, void __user *argp)
 334{
 335        struct the_nilfs *nilfs = inode->i_sb->s_fs_info;
 336        struct nilfs_argv argv;
 337        int ret;
 338
 339        if (copy_from_user(&argv, argp, sizeof(argv)))
 340                return -EFAULT;
 341
 342        if (argv.v_size != sizeof(struct nilfs_bdesc))
 343                return -EINVAL;
 344
 345        ret = nilfs_ioctl_wrap_copy(nilfs, &argv, _IOC_DIR(cmd),
 346                                    nilfs_ioctl_do_get_bdescs);
 347        if (ret < 0)
 348                return ret;
 349
 350        if (copy_to_user(argp, &argv, sizeof(argv)))
 351                ret = -EFAULT;
 352        return ret;
 353}
 354
 355static int nilfs_ioctl_move_inode_block(struct inode *inode,
 356                                        struct nilfs_vdesc *vdesc,
 357                                        struct list_head *buffers)
 358{
 359        struct buffer_head *bh;
 360        int ret;
 361
 362        if (vdesc->vd_flags == 0)
 363                ret = nilfs_gccache_submit_read_data(
 364                        inode, vdesc->vd_offset, vdesc->vd_blocknr,
 365                        vdesc->vd_vblocknr, &bh);
 366        else
 367                ret = nilfs_gccache_submit_read_node(
 368                        inode, vdesc->vd_blocknr, vdesc->vd_vblocknr, &bh);
 369
 370        if (unlikely(ret < 0)) {
 371                if (ret == -ENOENT)
 372                        printk(KERN_CRIT
 373                               "%s: inva2/ioctl.c#L367" id="L vnrty="+code=ns_segctor_sea42l.c#L3ef">ret;
 227buf, =segctllu, de=ns_ class="line" name="L227"> 227buf, )=segctllu, vbh)=segctllu\nde=ns_ class=="line" name="L365"> 365   tic int <3 href="+code=nilfs_ioctl3get_s37t argpvd_vblocknr, &de=ns_ class= :L367" id="L vnrty="+code=ns_4" cde=ns_ class=="line" name="L365"> 365   t                              uns3gned 3nt c(/a>, voidlongdlong)a href="+code=vd_vblocknr" class="sref">vd_vblocknr, & 365   a href="f3/nilfs2/ioctl.c#L279" id3"L27937    vd_vblocknr, & 365   ahref="fs/t , voidlongdlong)a href="+code=vd_vblocknr" class="sref">vd_vblocknr, &vdesc->"line" name="L365"> 365        stru3t size,(/a>, voidlongdlong)a href="+code=vd_vblocknr" class="sref">vd_vblocknr, & 365        int 3a href="+code=ret" class3"sref38="+code=nmembs" class="sref">nmembs<(/a>, voidlongdlong)a href="+code=vd_vblocknr" class="sref">vd_vblocknr, &bh);
 369
printka href="fs/nilfs2/ioctl.c#L353" id="L353" class="line" name="L353"> 353}
<     down_read 354
re3 = (ret < 0)) !a> *ret, , & 371        bhref="+code=KERN_CRIT" class="sref">KERN_CRIT
 227=segctllu, bh)=segctllu, vbh)=segctllu\nde=ns_ class=="line" name="L365"> 365            3   return ret;
bhref="+code=KERgpfunc__ass="sref">argpvd_vblocknr, &de=ns_ class= :L367" id="L vnrty="+code=ns_4" cde=ns_ class=="line" name="L365"> 365     href="f3nilfs2/ioctl.c#L289" id=3L289"38    , voidlongdlong)a href="+code=vd_vblocknr" class="sref">vd_vblocknr, & 365        if (3a href="+code=copy_to_us3r" cl38    &vd_vblocknr, & 365            3   ret = -, voidlongdlong)a href="+code=vd_vblocknr" class="sref">vd_vblocknr, &vdesc->"line" name="L365"> 365        retu3n , voidlongdlong)a href="+code=vd_vblocknr" class="sref">vd_vblocknr, & 365   a href="f3/nilfs2/ioctl.c#L293" id3"L29339" class="sref">printk(, voidlongdlong)a href="+code=vd_vblocknr" class="sref">vd_vblocknr, &bh);
 369
ret =  369
b;
 353}
 354
, , & 353}
re;
 326        int 3a href="+code=ret" class3"sref3>ret 354
 300  4     dowlock" class="sref">nilfs_ioctl_move_inode_bbh(struct  365  4     re40="+code=nmembs" class="sref">nmembs)fs_argv argv;
argv) href="+code=size_t" class="sref">size_t <="line" name="L372"> 372  4     up_re="line" name="L371"> 371  4     retu4n ret;
nmembs)
nilfsctlgv" class="sref">argv, & 353}
4a href="f4/nilfs2/ioctl.c#L305" id4"L30540e=buf" class=nilfs *nilfs = inode-> 336  4 href="fs4nilfs2/ioctl.c#L306" id=4L306"40s="sref">the_nilfs *inode,
 336  4 6ref="fs4n           void *nilfs_argv vdesc,
 336  4 7ref="fs4nnilfs2/ioctl.c#L298" id4cs" c407s="sref">nilfs_argv bh;
 336  4 8ref="fs4n href="+code=ret" class4f="+c40up_read(& 353}
4a href="f4/nilfs2/ioctl.c#L310" id4"L31040">down_read(&nme56" c>)
 353}
4     stru4t down_read(&posp, int (& 353}
4     ;
bd_blockf="+code=size" cll.c#L353" id="L353" class="line" name="L353"> 353}
4     int 4a href="+code=ret" class4"sref41lass="line" name="L283"> 283  4 href="fs4nilfs2/ioctl.c#L314" id=4L314"41f">ret;
i < vd_vef="fs/nilfs2/ioctl.c#L312" id="L312" class=="+code=nmembs" class="sref">nmembs; i++) {
 371  4     b href="fs/nilfsil.c#L223" id="L22il.lassef="fs/nilfs2/ioctd_vblocknr" class="sref">vd_vblocknr, & 353}
4 href="fs4bhref="+code=KERtl.c#L223" id="L22cl.lassef="fs/nilfs2/ioctd_vblocknr" class="sref">vd_vblocknr, & 353}
4 6ref="fs4   ret = inode,
nilfs_ioctl_wrap_copyid="hre_gesc" class="sref">vdesyid="hre_geRIT
 353}
4         4                        4     4     cmd
inode,
 371  4         4                        4     4     nilfs_ioctl_wrPTR_ERlass="sref">cmd
inode,
 353}
4  href="f4                        4     4     &bcaile"lass="line" name="L353"> 353}
4         4   if (ret < ="line" name="L354"> 354
<4         4           if (ret(ret, nilfs->inode,
ret 371  4         4                   up_re367" id="L vncomment">/* class="line" name="L227"> 227read" class="sref">up_re * Add nil e toeGC e ode=. Garbage Collection class="line" name="L227"> 227read" class="sref">up_re * is serialized and no two processes manipulate nil class="line" name="L227"> 227read" class="sref">up_re * ode= simultaneously. class="line" name="L227"> 227read" class="sref">up_re */ class="line" name="L227"> 227
inode,
 353}
4     , nilfs->inode,
ret 365  4     retu4n ns_segctor_sem);
 353}
4a href="f4/nilfs2/ioctl.c#L331" id4"L33143="sref">ret < ="line" name="L354"> 354
<4 href="fs4nilfs2/ioctl.c#L332" id=4L332"4class="line" name="L332"> 332st4tic int <4 href="+code=nilfs_ioctl4get_b43e=up_read" class="sredos="line" name="L371"> 371  4         4                     uns4gned 4nt nilfs_ioctl_wroctl_move_inode_block(struct inodeinode,
vd_v="line" name="L365"> 365  4a href="f4/nilfs2/ioctl.c#L335" id4"L33543e=buf" class="sref">buf,  353}
4     stru4t buf, (ret < 0)) {
 371  4     stru4t nme5pucRIT
inode,
 353}
4     int 4a href="+code=ret" class4"sref43t bcaile"lass="line" name="L353"> 353}
4 href="fs4nilfs2/ioctl.c#L339" id=4L339"43     354
<4     retu4a href="+code=copy_from_4ser" 43    &vd_v++="line" name="L353"> 353}
4         4   return -EFAULT} while (++"+code=nmembs" class="sref">nmembs; i++) {
 353}
4 href="fs4nilfs2/ioctl.c#L342" id=4L342"44="+code=nmembs" class="sref">n"fs/nilfs2/ioctd_vblocknr" class="sref">vd_vblocknr, &vd_vblocknr, & 353}
4     if (4a href="+code=argv" clas4="sre44lass="line" name="L283"> 283  4         4   return -EINVALa href="+code=nepuclass="sref">nme5pucRIT
inode,
/* Til e still remains e ode= */ class="line" name="L227"> 227 354
<4     re44lass="line" name="L306"> 306st4         4                       <4 href44=buf" class="a> *inodode=bhre_each_entry_saflRIT
 371  4     if (4a href="+code=ret" class4"sref44ef">ret = nilfs_gccache_submiwai=band_mark_dirtlass="sref">ret<_gccache_submiwai=band_mark_dirtlRIT
 353}
4 href="fs4   return ret;
<(ret < 0)) {
 371  4 href="fs4nilfs2/ioctl.c#L350" id=4L350"44    & 353}
4     if (4a href="+code=copy_to_us4r" cl45="+code=size" class="sref">sigotoef="+code=filp" caile" class="sref">bcaile"lass="line" name="L353"> 353}
4         4   ret = - 354
<4     retu4n , , & 353}
4         4/nilfs2/ioctl.c#L354" id4"L35445ef">ret =  369
<4 href="fs4nilfs2/ioctl.c#L355" id=4L355"45e=buf" class=="line" name="L354"> 354
<4tic int <4 href="+code=nilfs_ioctl4move_45e=buf" class=/a>;
 330}
4         4                        4  str4ct  330}
4     if (4                        4  str4ct bcaile"lass:"line" name="L330"> 330}
4 href="fs4/nilfs2/ioctl.c#L359" id4"L35945up_read(&inodode=bhre_each_entry_saflRIT
 371  4     stru4t , , & 353}
4     int 4a href="+code=ret" class4"sref46="+code=size" class="="+code=nilfs_gbrass=tl.c#L358" id="Lrass=RIT
 369
<4 href="fs4nilfs2/ioctl.c#L362" id=4L362"461=buf" class=="line" name="L354"> 354
<4     if (4a href="+code=vdesc" cla4s="sr46f">ret;
 353}
4         4    354
<4         4            355st4         4           nilfs_ioctl_move_indelete_ubmckpolas href="fs/nilfs2/ioctl.c#L347elete_ubmckpolas RIT *nilfs, __u64 * 355st4         4ni>)fs_argv argv;
argv) href="+code=size_t" class="sref">size_t <="line" name="L372"> 372  4         4   r="line" name="L371"> 371  4         4           nmembs)
nilfsctlgv" class="sref">argv, & 353}
4 href="fs4nilfs2/ioctl.c#L370" id=4L370"46ass="sref">buffer_head *inode,
filpnilfs_gccactor_sem" class="sref">ns_segctor_sem);
filp 353}
4     if (4a href="+code=unlikely" 4lass=47ss="sref">nilfs_bmap *b+code=perio",
nilfsl.c#L312" id="L312" class="line" name="L312"> 312  4         4   if (;
i;
 313
<4         4            283  4         4                  "href="+code=i" class="sref">i < nmembs; i++) {
 316  4a href="f4/nilfs2/ioctl.c#L275" id4"L27547e=buf" class="sref">b="+code=nilfs_gccache_submit_read_node" class="sref">nilfs_gccaccpclasndelete_ubmckpolas href="fs/nilfs2/ioctlcpclasndelete_ubmckpolas RIT 316  4a        4nilfs2/ioctl.c#L276" id=4L276"47e=buf" class="sref">buf, ref="fs/nilfs2/cpclass="sref">filpbd_blocknr = 0;
bd_blocknr = 0;
bp_en"class="line" name="L369"> 369
<4tic int <4 href="+code=nilfs_ioctl4get_s47t  348  4t        4                     uns4gned 4nt  353}
4a href="f4/nilfs2/ioctl.c#L279" id4"L27947     354
<4ahref="fs4t ;
 330}
4     stru4t  331
<4     int 4a href="+code=ret" class4"sref48lass="line" name="L332"> 332st4 href="fs4nilfs2/ioctl.c#L283" id=4L283"48scs" class="sref">nilfs_ioctl_get_bdescsbh) href="fs/nilfs2/ioctl.c#L34free">bh) RIT *nilfs, __u64 * 355st4     ret =  argv;
argv) href="+code=size_t" class="sref">size_t <="line" name="L372"> 372  4     re48class="line" name="L335"> 335  4     nmembs)
nilfsctlgv" class="sref">argv, & 353}
4     if (4a href="+code=ret" class4"sref48t  361
<4         4   return  361
<4  href="f4nilfs2/ioctl.c#L289" id=4L289"48up_read(&nilfs_gccacdat4free" class="sref">argv
ns_segctor_sem);
filpsize_t  369
<4     if (4a href="+code=copy_to_us4r" cl48lass="line" name="L300"> 300  4         4   ret =/a>;
 330}
4     retu4n  331
<4a href="f4/nilfs2/ioctl.c#L293" id4"L29349lass="line" name="L283"> 283  4 href="fs4nilfs2/ioctl.c#L294" id=4L294"49ef">rlock" class="sref">nilfs_ioctl_move_inoark_bhret<_gccacove_inoark_bh *nilfs, __u64 * 355st4tic breffffffffffffffffffffffffs_argv argv;
argv) href="+code=size_t" class="sref">size_t <="line" name="L372"> 372  4href="+co4e=nilfs_ioctl_do_get_vin4o" cl49e=buf="line" name="L335"> 335  4         4            void *nmembs)
nilfsctlgv" class="sref">argv, & 353}
4h        4/nilfs2/ioctl.c#L298" id4"L298497s="sref">nilfs_argv argvabma"a hrelass="sref">nilfsilfs" class="sref">nilfs->ns_segctor_sem);
filpaiabma"a hr="line" name="L353"> 353}
4h href="f4a href="+code=ret" class4"sref498s="sref">nilfs_argv nilfsl.c#L312" id="L312" class="line" name="L312"> 312  4     if (4nilfs2/ioctl.c#L300" id=4L300"49ass="sref">copef="fs/nilfs2/ioct="sref">i;
 313
<5     dow"line" name="L313"> 313
<5 1   re50="+code=nmembhref="+code=i" class="sref">i < nmembs; i++) {
 316  5     /* XXX: use macro refinp_re func toeubmck liven 2s */ class="line" name="L227"> 227ret = nilfs_gccacbma"_lookup_at4leves2/ioctl.c#L319"_gccacbma"_lookup_at4levesRIT
abma"a hr "line" name="L355"> 355st5a href="f5/nilfs2/ioctl.c#L305" id5"L30550e=buf" class="sref">brefffffffffffffffffffffff bd_blocknr = 0;
bdesc->"line" name="L365"> 365  5 href="fs5nilfs2/ioctl.c#L306" id=5L306"50e=buf" class="sref">buf, fffffffffffffffff bd_blocknr = 0;
 365  5 6ref="fs5n           void *ni>))))))))a href="+code=argp" .;
bd_blocknr = 0;
 369
<5 7ref="fs5nnilfs2/ioctl.c#L298" id5cs" c50     316  5 8ref="fs5n href="+code=ret" class5f="+c50    ( 372  5a href="f5/nilfs2/ioctl.c#L310" id5"L31050    & 353}
5     stru5t sif="+code=argp" .;
bd_blocknr = 0;
 353}
5 1   ret = - 354
<5     int 5a href="+code=ret" class5"sref51e=up_read" class="sre(bd_blocknr = 0;
nilfsl;
bd_blocknr = 0;
 354
<5     retu5nilfs2/ioctl.c#L314" id=5L314"51ef">ret = /* skip deadret*/ class="line" name="L227"> 227bbbbbbbbbcontinuef"line" name="L353"> 353}
5 href="fs5b(bd_blocknr = 0;
 316  5 6ref="fs5   ret = sif="+code=argp" ccache_submit_read_node" class="sref">nilfs_gccacmdtnoark_bhret<_gccacmdtnoark_bh
ns_segctor_sem);
filp 316  5 7ref="fs5                        5     5     bd_blocknr = 0;
bdesc->s="line" name="L369"> 369
<5         5                        5     5     ( 316  5  href="f5                        5     5     & 369
<5         5   if (ret <                 a href="fs/nilfs2/ioctl.c#L353" id="L353" class="line" name="L353"> 353}
5         5           if (ret 354
<5         5                    316  5         5                   retur5 nilfs_ioctl_wroctl_mbma"_oark2/ioctl.c#L319"_gccacbma"_oarkRIT
abma"a hr damp;bd_blocknr = 0;
bdesc->f"line" name="L316"> 316  5     brefffffffffffffffffffffff bd_blocknr = 0;
 369
<5 href="fs5           buf, ( 316  5 6ref="fs5   }
 369
<5 7ref="fs5href="fs/nilfs2/ioctl.c#5328" 52t  353}
5         5ef="+code=up_read" class5"sref52     354
<5  href="f5n  354
<5a href="f5/nilfs2/ioctl.c#L331" id5"L33153="sref">ret 354
<5a        5nilfs2/ioctl.c#L332" id=5L332"53t" class="sre/a>;
 330}
5tic int <5 href="+code=nilfs_ioctl5get_b53e=up_="line" name="L354"> 354
<5a        5                     uns5gned 5nt  354
<5a    nilfs_ioctl_move_inprepare_clean_segment href="fs/nilfs2/ioctl.c#L34prepare_clean_segment RIT *nilfs, __u64 * 355st5     stru5t buf,                fs_argv argv;
argv) href=ef="fs/nilfs2/iokbuclass="sref">__u6kbucllasss"line" name="L354"> 354
<5     stru5t  316  5     int 5a href="+code=ret" class5"sref53t __u6msglass="line" name="L330"> 330}
5t        5nilfs2/ioctl.c#L339" id=5L339"53     361
<5     retu5a href="+code=copy_from_5ser" 53lass="line" name="L300"> 300  5         5   return -down_read(&nilfs_ioctl_wroctl_move_indelete_ubmckpolas href="fs/nilfs2/ioctl.c#L347elete_ubmckpolas RIT__u64 *argv__u6kbucllass[1]=="line" name="L369"> 369
<5 href="fs5nilfs2/ioctl.c#L342" id=5L342"54="+code=nmemb( 316  5     if (5a href="+code=argv" clas5="sre54e=up_read" class="srea67" id="L vncomment">/* class="line" name="L227"> 227read" class="sref* c" isaflly abort because ubmckpolas  c" ibe remove"lalass="line" name="L227"> 227read" class="sref*"redepeedently. class="line" name="L227"> 227re54" cla367" id="L vncomment">read" class="sref*/ class="line" name="L227"> 227ret = __u6msglass f">67" id="L vnrty="+code=ns_cannot 7elete ubmckpolas de=ns_ class=="line" name="L369"> 369
<5     int 5a href="+code=ret" class5"sref54ef">ret = bcaile"lass="line" name="L353"> 353}
5 href="fs5   return  354
<5 href="fs5nilfs2/ioctl.c#L350" id=5L350"54    &(&nilfs_ioctl_wroctl_move_infree">bh) href="fs/nilfs2/ioctl.c#L34free">bh) RIT__u64 *argv__u6kbucllass[2]=="line" name="L369"> 369
<5     if (5a href="+code=copy_to_us5r" cl55="+code=size"( 316  5         5   ret = -/* class="line" name="L227"> 227read" class="sref* c" isaflly abort because DAT clas is updated atomicalt; 0lass="line" name="L227"> 227read" class="sref* us="+ accopy-on-write nechnique. class="line" name="L227"> 227read" class="sref*/ class="line" name="L227"> 227bhref="+code=KERmsgass="sref">__u6msglass f">67" id="L vnrty="+code=ns_cannot 7elete virtualret 369
<5         5                        5  str55ef">ret = bcaile"lass="line" name="L353"> 353}
5     if (5                        5  str557    354
<5 href="fs5/nilfs2/ioctl.c#L359" id5"L35955up_read(&nilfs_ioctl_wroctl_move_inoark_bhret<_gccacove_inoark_bh__u64 *argv__u6kbucllass[3]=="line" name="L369"> 369
<5 href="fs5t ( 316  5     int 5a href="+code=ret" class5"sref56="+code=size" class="=67" id="L vncomment">/* class="line" name="L227"> 227read" class="sref* c" isaflly abort because nil operation is noedefs_argive. class="line" name="L227"> 227read" class="sref*/ class="line" name="L227"> 227ret = __u6msglass f">67" id="L vnrty="+code=ns_cannot oarkccopy="+ et 369
<5         5           bgotoef="+code=filp" caile" class="sref">bcaile"lass="line" name="L353"> 353}
5         5            354
<5         5;
 326  5         5    361
<5         5           bcaile"lass:"line" name="L330"> 330}
5 href="fs5nilfs2/ioctl.c#L370" id=5L370"56    &(&cmd 355st5     if (5a href="+code=unlikely" 5lass=57="+code=size" class=amp;__u6msglassf="+code=size" cll.c#L353" id="L353" class=="line" name="L369"> 369
<5         5   if ( 361
<5         5            354
<5         5                   354
<5a href="f5/nilfs2/ioctl.c#L275" id5"L27557e=buflock" class="sref">nilfs_ioctl_move_inclean_segment href="fs/nilfs2/ioctl.c#L34clean_segment RIT *inode,
 filpacla" * 355st5a        5nilfs2/ioctl.c#L276" id=5L276"57e=buf" class="sref">buf,               unsigne" lass="sref">nilfs_icm" class="sref">bcm"v) href="sref">nilfs_i__usede=bh" class="sr__useda hreef="fs/nilfs2/ioctl" class="sref">actl"lasss"line" name="L354"> 354
<5tic int <5 href="+code=nilfs_ioctl5get_s57t  316  5t        5                     uns5gned 577s="sref">nilfs_argv argv;
argv 361
<5         5/nilfs2/ioctl.c#L279" id5"L279578s="sref">nilfsck" cconst f="+code=argp" ibs" class="sref">nmembs)
arszv 316  5thref="fs5t vdesc,
 355st5     stru5t b+code=perio",
 355st5         5a href="+code=ret" class5"sref58ef">ret = -nilfs_i__ulass="sref">posp, int ) "line" name="L355"> 355st5         5nilfs2/ioctl.c#L283" id=5L283"58e=up_read" class="srembs * 355st5         5ef="+code=down_read" cla5s="sr58ef">ret = nilfs_i__ulass="sref">posp, int ) "line" name="L355"> 355st5  href="f5ef="+code=ret" class="sr5f">re58e=buf" class==="line" name="L361"> 361
<5     nilfs_i__usede=bh" class="sr__useda hreef="fs/nilfs2/iobas=tl.c#L358" id="Lasslass="line" name="L353"> 353}
5     if (5a href="+code=ret" class5"sref58t __u6kbucllass[5]="line" name="L361"> 361
<5         5   return nilfs_argv nilfs, __u64 * 361
<5         5nilfs2/ioctl.c#L289" id=5L289"58up_read(&nmembs)
 361
<5 href="fs5a href="+code=copy_to_us5r" cl58ass="sref">copef="fs/nilfs2/ioctnsc" class="sref"lass h href="fs/nilfsl.c#L361" id="L361" class="line" name="L361"> 361
<5         5   dow"line" name="L313"> 313
<5     retu5n !="sref">nilfs_icapabass="sref">filp 354
<5a href="f5/nilfs2/ioctl.c#L293" id5"L29359e=up_read" class="sre/a>;
 361
<5         5nilfs2/ioctl.c#L294" id=5L294"59t  354
<5tic nilfs_ioctl_wrmnt_want_write_class="sref">filpacla" * 369
<5href="+co5e=nilfs_ioctl_do_get_vin5o" cl595"+code=nmemb"+code=size" cll.c#L353" id="L353" class="line" name="L369"> 369
<5h    if (5            void *ret = ;
 361
<5h        5/nilfs2/ioctl.c#L298" id5"L29859ass=""line" name="L361"> 361
<5h href="f5a href="+code=ret" class5"sref59up_read(& 361
<5hhref="fs5nilfs2/ioctl.c#L300" id=5L300"59    &(argv)f="fs/nilfs2/ioctl" class="sref">actl"lass,fmbsnilfs_ictlgv" class="sref">argv 354
<6     nmeouclass="line" name="L361"> 361
<6 1   re60lass="line" name="L332"> 332st6      361
<6 3   ret ="+code=size" clnseggctor_sem" class=aegg *nilfsctlgv" class="sref">argv = 0;
 353}
6a href="f6/nilfs2/ioctl.c#L305" id6"L30560e=buf" class=(argv = 0;
nilfs>arszv" class="sref">arszv 354
<6 5href="f6/=nilfs_ioctl_do_get_vin6L306"60e=buf" class="sref">bgotoef="+code=filp" ouclass="sref">nmeouclass="line" name="L361"> 361
<6 6href="f6/           void *nilfs_i__ulass="sref">posp, int )s"line" name="L354"> 354
<6 7href="f6/nilfs2/ioctl.c#L298" id6cs" c60    nmeouclass="line" name="L361"> 361
<6 8href="f6/ href="+code=ret" class6f="+c60    <"line" name="L361"> 361
<6 9href="f6/ilfs2/ioctl.c#L300" id=6"L31060    &/* class="line" name="L227"> 227read" cla* >arg[4] polas  toesegment number  this 227 227read" cla* use kmalloc()bhrefis  fs2/io because /ioory usedbhrefnil class="line" name="L227"> 227read" cla*esegment number  is enough small. class="line" name="L227"> 227read" cla*/ class="line" name="L227"> 227__u6kbucllass[4] f">nilfs_ioctl_wrmemdup_usede=bh" class="srmemdup_usedRITnilfs_i__usede=bh" class="sr__useda hree)(unsigne" long)(argv = 0;
 355st6 href="fs6bbbbbbbbbbbbbbbb(nilfs_i__ulass="sref">posp, int )s="line" name="L361"> 361
<6 6ref="fs6   (cmd__u6kbucllass[4]ass="line" name="L371"> 371  6 7ref="fs6                        6     6     nilfs_ioctl_wrPTR_ERlass="sref">cmd__u6kbucllass[4]a="line" name="L361"> 361
<6 8href="f6                        6     6     nmeouclass="line" name="L361"> 361
<6  href="f6                        6     6     & 354
<6         6   if (down_read(&__u64 *nilfs_ioctl_wrioctl.c#L356" id="L356" classt; 361
<6         6           if ( 332st6         6                    316  6         6                   retur6  361
<6     b(argv = 0;
nilfs>arszv" class="sref">arszv 354
<6 href="fs6           buf, gotoef="+code=filp" ouc4freelass="sref">nmeouc4freelass="line" name="L361"> 361
<6 6ref="fs6   }
 330}
6 7ref="fs6href="fs/nilfs2/ioctl.c#6328" 62t (argv = 0;
(&__u64 *);
 369
<6         6ef="+code=up_read" class6"sref62    nmeouc4freelass="line" name="L361"> 361
<6  href="f6n  300  6a href="f6/nilfs2/ioctl.c#L331" id6"L33163="+code=size" class="(argv = 0;
nilfsUINT_MAXctor_sem" classUINT_MAX *argv = 0;
 369
<6a        6nilfs2/ioctl.c#L332" id=6L332"63t" class="sref">retnmeouc4freelass="line" name="L361"> 361
<6tic int <6 href="+code=nilfs_ioctl6get_b63lass="line" name="L283"> 283  6a        6                     uns6gned 63t nilfsctlgv" class="sref">argv = 0;
(&argv = 0;
 361
<6t    b="+code=nilfs_gbas=tl.c#L358" id="Lasslasscla( href="sref">nilfs_i__usede=bh" class="sr__useda hree)(unsigne" long)(argv = 0;
 361
<6thref="fs6t b( 316  6     stru6t ret = sif="+code=argp" kbuclass="sref">__u6kbucllass["+code=nmembs" nsc" class="sref"lassnelass="sref">nilfsiULLl.c#L372" id="LiULL * 361
<6t7ref="fs6a href="+code=ret" class6"sref63t  353}
6t        6nilfs2/ioctl.c#L339" id=6L339"63     354
<6     retu6a href="+code=copy_from_6ser" 63lass="line" name="L300"> 300  6         6   return -__u6kbucllass["+code=nmembs" nsc" class="sref"lassnelass="sref">nilfsvmalloctl.c#L358" id=" mallocRIT 361
<6 href="fs6nilfs2/ioctl.c#L342" id=6L342"64t" class="sref">ret!="sref">nilfs_ikbuclass="sref">__u6kbucllass["+code=nmembs" nsc" class="sref"lassn=s="line" name="L316"> 316  6     if (6a href="+code=argv" clas6="sre64e=up_read" class="sre class="="+code=nilfs_gl.c#L353" id="L353" class f"a href="fs/nilfs2NOMEMs2/ioctl.c#L3712NOMEM * 361
<6         6   return -nmeouc4freelass="line" name="L361"> 361
<6     b="line" name="L354"> 354
<6     re64e=buf" class="sref">b(__u6kbucllass["+code=nmembs" nsc" class="sref"lassn damp; 316  6     stru6                       <6 href64ef">ret =  361
<6     int 6a href="+code=ret" class6"sref64ef">ret = nmevfreelass/ref="+code=__u6kbuclass="sref">__u6kbucllass["+code=nmembs" nsc" class="sref"lassna="line" name="L361"> 361
<6         6   return nmeouc4freelass="line" name="L361"> 361
<6 href="fs6nilfs2/ioctl.c#L350" id=6L350"64    & 354
<6     if (6a href="+code=copy_to_us6r" cl65="sref">ret 354
<6         6    332st6     retu6n /* class="line" name="L227"> 227read" cla* _gccacove_inoove bh 227read" cla* which will operates " i56" c list withouc et 227read" cla* To protect nil list from concurrent operations, class="line" name="L227"> 227r367" id="L vncomment">read" cla* _gccacove_inoove bh 227read" cla*/ class="line" name="L227"> 227(&(GC_RUNNING#L353" id="L353THE_fsGC_RUNNINGlass da href="+code=argp" 4" class="sref">__u64 *);
 316  6 href="fs6t  361
<6     int 6a href="+code=ret" class6"sref66="+code=size" class="gotoef="+code=filp" ouc4freelass="sref">nmeouc4freelass="line" name="L361"> 361
<6 href="fs6nilfs2/ioctl.c#L362" id=6L362"661"sref">ret 354
<6     if (6a href="+code=vdesc" cla6s="sr66lass="line" name="L283"> 283  6         6   ret ="+code=size" cll.c#L353" id="L353" class f">nilfs_ioctl_wroctl_move_inoove bh__u64move_inoove bhargv__u6kbucllass[0na="line" name="L361"> 361
<6         6           ( 361
<6 ic int <6           b(cmd 361
<6     stru6ret =  369
<6         6   ret =ass=s="line" name="L316"> 316  6         6           (__u64msb_need_updateRIT__u64 * 354
<6 href="fs6nilfs2/ioctl.c#L370" id=6L370"66    &mdiscontinue" class="sref">bsec44mdiscontinue"RIT__u64 * 369
<6     if (6a href="+code=unlikely" 6lass=67="+code=size" class=="+code=size" cll.c#L353" id="L353" class f">nilfs_ioctl_wroctl_mclean_segment href="fs/nilfs2/ioctlclean_segment RITargv__u6kbucllass)="line" name="L369"> 369
<6 href="fs6   if (ret 354
<6         6            283  6         6                  ret ="+code=size" clnioctlremove_alt_gc56" c href="fs/nilfs2/ioctlremove_alt_gc56" c RIT__u64 * 369
<6         6/nilfs2/ioctl.c#L275" id6"L27567e=buf" class=amp;__u64 * 369
<6 ic int <6nilfs2/ioctl.c#L276" id=6L276"67e=buf"line" name="L369"> 369
<6     stru6 href="+code=nilfs_ioctl6get_s67t nmeouc4freelass:"line" name="L330"> 330}
6t        6                     uns6gned 677s="sref">nilwhlas (-a href="fs/nilfsnsc" class="sref"lass 1seglaas"line" name="L361"> 361
<6         6/nilfs2/ioctl.c#L279" id6"L27967    nmevfreelass/ref="+code=__u6kbuclass="sref">__u6kbucllass["+code=nmembs" nsc" class="sref"lassna="line" name="L361"> 361
<6thref="fs6t (&nmekfreelass/ref="+code=__u6kbuclass="sref">__u6kbucllass[4]a="line" name="L361"> 361
<6     stru6t nmeouclass:"line" name="L330"> 330}
6         6a href="+code=ret" class6"sref68ef">ret =f="+code=filp" mnt_drop_write_class="sref">filpacla" * 369
<6         6nilfs2/ioctl.c#L283" id=6L283"68e=up_read" cl/a>;
 361
<6         6ef="+code=down_read" cla6s="sr68ef">r="line" name="L354"> 354
<6  href="f6ef="+code=ret" class="sr6f">re68e=buf"line" name="L354"> 354
<6 ic int <6ef="+code=up_read" class6"sref68e=buflock" class="sref">nilfs_ioctl_move_insyns2/ioctl.c#L343" id="Love_insynslass/nilfs *inode,
 filpacla" * 355st6     if (6a href="+code=ret" class6"sref68ef">ret = nilfs_icm" class="sref">bcm"v) href="sref">nilfs_i__usede=bh" class="sr__useda hreef="fs/nilfs2/ioctl" class="sref">actl"lasss"line" name="L354"> 354
<6         6   return  316  6         6nilfs2/ioctl.c#L289" id=6L289"68up_read(&posp, int s="sref">nilfs_icn.c#L223" id="L22cn.lass="line" name="L361"> 361
<6 href="fs6a href="+code=copy_to_us6r" cl68ass="sref">copef="fs/nilfs2/ioctl.c#L361" id="L361" class="line" name="L361"> 361
<6         6    nilfs, __u64 * 361
<6     retu6n  332st6a href="f6/nilfs2/ioctl.c#L293" id6"L29369e=up_read" clamp;nilfs_ioctl_wroctl_mconst_arg_segmentctor_sem" class=ctl_mconst_arg_segmentRIT 369
<6         6nilfs2/ioctl.c#L294" id=6L294"69ef">ret =( 361
<6tic b/a>;
 361
<6href="+co6e=nilfs_ioctl_do_get_vin6o" cl69e=buf"line" name="L369"> 369
<6h    if (6            void *ret =ref="+code=__u64" class="sref">__u64 *nilfs_ioctl_wrioctl.c#L356" id="L356" classt; 361
<6h        6/nilfs2/ioctl.c#L298" id6"L298697f">ret =(__u64 *cmd 316  6h href="f6a href="+code=ret" class6"sref69    nilfs_ioctl_wrblkdev_issue_clush#L353" id="L353blkdev_issue_clushRIT 369
<6 href="fs6nilfs2/ioctl.c#L300" id=6L300"69    & 354
<7     b/a>;
 361
<7 1   re701"sref">ret 354
<7      283  7 3   ret =(actl"lass"!lass="sref">nilfsiULLl.c#L372" id="LiULL * 316  7a href="f7/nilfs2/ioctl.c#L305" id7"L30570e=buf" class="sref">b="+code=nilfs_gdown_readl.c#L372" id="Ldown_readRIT__u64 *);
 369
<7 5href="f7/=nilfs_ioctl_do_get_vin7L306"70e=buf" class="sref">b="sref">nilfs_icn.c#L223" id="L22cn.lass f">nilfs_ioctl_wroctl_ass="sref">__u64 *);
 369
<7 6href="f7/           void *ret = );
up_readl.c#L372" id="Lup_readRIT__u64 *);
 369
<7 7href="f7/nilfs2/ioctl.c#L298" id7cs" c70    actl"lass,fa href="+code=argp" cn.c#L223" id="L22cn.lass,fmbsnilfs_icn.c#L223" id="L22cn.lass))s"line" name="L354"> 354
<7 8href="f7/ href="+code=ret" class7f="+c70    ;
 361
<7 9href="f7/ilfs2/ioctl.c#L300" id=7"L31070    & 354
<7     stru7t ;
 326  7 1    354
<7      283  7     retu7nilfs2/ioctl.c#L314" id=7L314"71f="+clock" class="sref">nilfs_ioctl_move_inrembsinode,
 filpacla" * 355st7     bbbbbbbbbbbbbbb href="sref">nilfs_i__usede=bh" class="sr__useda hreef="fs/nilfs2/ioctl" class="sref">actl"lasss"line" name="L354"> 354
<7 href="fs7 316  7 6ref="fs7   ret =ref="+code=__u6__ulass="sref">posp, int s="sref">nilfs_inewmbs 361
<7 7ref="fs7                        7     7      361
<7 8href="f7                        7     71    <"line" name="L361"> 361
<7  href="f7                        7     71    &!="sref">nilfs_icapabass="sref">filp 354
<7         7   if (nmeouclass="line" name="L361"> 361
<7         7           if ( 332st7         7                   nilfs_ioctl_wrmnt_want_write_class="sref">filpacla" * 369
<7         7                   retur7 ret =( 354
<7     bgotoef="+code=filp" ouclass="sref">nmeouclass="line" name="L361"> 361
<7 href="fs7            369
<7 6ref="fs7   }
ret =ref="+code=__u6l.c#L353" id="L353" class f"a href="fs/nilfs2FAULtl.c#L372" id="L3FAULtlass="line" name="L361"> 361
<7 7ref="fs7href="fs/nilfs2/ioctl.c#7328" 727f">ret =(actl"lass,fmbsnilfs_i4ewmbs 354
<7         7ef="+code=up_read" class7"sref72    nmeouc4drop_writelass="line" name="L361"> 361
<7  href="f7n  300  7a href="f7/nilfs2/ioctl.c#L331" id7"L33173">down_read(&nilfs_ioctl_wroctl_mrembs<_class="sref">__u64mrembs<_clRIT 361
<7a        7nilfs2/ioctl.c#L332" id=7L332"73lass="line" name="L332"> 332st7tic int <7 href="+code=nilfs_ioctl7get_b73lass=f="+code=filp" ouc4drop_writelass="sref">nmeouc4drop_writelass:"line" name="L330"> 330}
7a        7                     uns7gned 73ef">ret ="+code=size" clmnt_drop_write_class="sref">filpacla" * 369
<7t    nmeouclass:"line" name="L330"> 330}
7ahref="fs7t ;
 361
<7     stru7t r="line" name="L354"> 354
<7t7ref="fs7a href="+code=ret" class7"sref73ass=""line" name="L361"> 361
<7t        7nilfs2/ioctl.c#L339" id=7L339"73    nilfs_ioctl_move_inset_alloc_ranginode,
nilfs_i__usede=bh" class="sr__useda hreef="fs/nilfs2/ioctl" class="sref">actl"lasss"line" name="L354"> 354
<7     retu7a href="+code=copy_from_7ser" 73lass=="line" name="L316"> 316  7         7   return - nilfs, __u64 *nilfs_ioctl_wrioctl.c#L356" id="L356" classt; 361
<7 href="fs7nilfs2/ioctl.c#L342" id=7L342"74ef">ret =f="+code=filp" __ulass="sref">posp, int s="sref">nilfs_irang 361
<7     if (7a href="+code=argv" clas7="sre74e=up_read" clamp;posp, int s="sref">nilfs_imi=aegs="sref">filpfilp 361
<7         7   return - 361
<7      361
<7     re74e=buf"line" name="L369"> 369
<7     stru7                       <7 href74t nilfs_icapabass="sref">filp 354
<7     int 7a href="+code=ret" class7"sref74ef">ret = nmeouclass="line" name="L361"> 361
<7         7   return  361
<7 href="fs7nilfs2/ioctl.c#L350" id=7L350"74    &(& 361
<7     if (7a href="+code=copy_to_us7r" cl75="sref">ret(actl"lass,fmbsnilfs_i__ulass="sref">posp, int [2]))s"line" name="L354"> 354
<7         7   retnmeouclass="line" name="L361"> 361
<7     retu7n  283  7         7/nilfs2/ioctl.c#L354" id7"L35475ef">ret ="+code=size" cll.c#L353" id="L353" class f"a href="fs/nilfs2RANGEl.c#L372" id="L3RANGElass="line" name="L361"> 361
<7     ( 354
<7tic int <7 href="+code=nilfs_ioctl7move_75e=buf" class="sref">bgotoef="+code=filp" ouclass="sref">nmeouclass="line" name="L361"> 361
<7     stru7                        7  str75t  330}
7t    int 7                        7  str757f">ret ="+code=size" clsegbytc href="fs/nilfs2segbytc lass f">nilfs_ioctl_wroctl_ass="sref">__u64 *);
(&__u64 *);
 361
<7         7/nilfs2/ioctl.c#L359" id7"L35975    <"line" name="L361"> 361
<7 href="fs7t (&filpnilfs_ioctl_wrlang 369
<7     int 7a href="+code=ret" class7"sref76">down_read(&filp 369
<7 href="fs7nilfs2/ioctl.c#L362" id=7L362"76ef">ret =f="+code=filp" maxaegs="sref">filpnilfsisSB2_OFFSET_BYTESs="sref">filpSB2_OFFSET_BYTESRIT 369
<7     retu7a href="+code=vdesc" cla7s="sr76e=up_read" clamp;filp 369
<7         7   ret ="+code=size" clmaxaegs="sref">filp 369
<7      354
<7 ic int <7           (&nilfs_ioctl_wroctl_msuclasnset_alloc_rang__u64 *);
filpfilpfilp 369
<7     stru7nmeouclass:"line" name="L330"> 330}
7         7   ret =/a>;
 361
<7         7            354
<7 href="fs7nilfs2/ioctl.c#L370" id=7L370"76lass="line" name="L300"> 300  7     if (7a href="+code=unlikely" 7lass=77="+colock" class="sref">nilfs_ioctl_move_ingec4.nf.c#L223" id="L22octl_move_ingec4.nf.lass/nilfs *inode,
 filpacla" * 355st7 href="fs7   if (retnilfs_icm" class="sref">bcm"v) href="sref">nilfs_i__usede=bh" class="sr__useda hreef="fs/nilfs2/ioctl" class="sref">actl"lass "line" name="L355"> 355st7     retu7            ="+code=size" clsbs<_c#L361" id="L361sbs<_cint s="sref">nilfs_imioctzv" class="sref"mioctzlass "line" name="L355"> 355st7         7                  ret =ass="sre class="et ="+code=size" clssbs<_c#L361" id="L361ssbs<_cint s(ef="fs/nilfs2/iodofuns2/ioctl.c#L343"dofunslass=/nilfs *nilfs,  355st7     bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbamp;posp, int s*, las "line" name="L355"> 355st7 ic int <7nilfs2/ioctl.c#L276" id=7L276"77e=buf" class="sref">bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb href*f="+code=size" clsbs<_c#L361" id="L361sbs<_cint f="+code=size" clsbs<_c#L361" id="L361sbs<_cint )s"line" name="L354"> 354
<7     stru7 href="+code=nilfs_ioctl7get_s77t  330}
7t        7                     uns7gned 777s="s="line" name="L316"> 316  7         7/nilfs2/ioctl.c#L279" id7"L27977    nilfs, __u64 *nilfs_ioctl_wrioctl.c#L356" id="L356" classt; 316  7 href="fs7t  nilfs_ictlgv" class="sref">argv 316  7     stru7t ret 361
<7         7a href="+code=ret" class7"sref78lass="line" name="L332"> 332st7         7nilfs2/ioctl.c#L283" id=7L283"78e=up_read" cl(argvactl"lass,fmbsnilfs_ictlgv" class="sref">argv 354
<7         7ef="+code=down_read" cla7s="sr78ef">ret =ass="sre/a>;
 361
<7  href="f7ef="+code=ret" class="sr7f">re78e=buf"line" name="L354"> 354
<7 ic int <7ef="+code=up_read" class7"sref785=up_read" cl(argv = 0;
nilfs_imioctzv" class="sref"mioctzlasss"line" name="L354"> 354
<7     stru7a href="+code=ret" class7"sref78ef">ret = ;
 361
<7         7   return  361
<7         7nilfs2/ioctl.c#L289" id=7L289"78up_read(&nilfs_ioctl_wroctl_move_inwrap_copyc#L223" id="L22octl_move_inwrap_copyRIT__u64 *argvcmd<_IOC_DIlRITbcm"v 361
<7 href="fs7a href="+code=copy_to_us7r" cl78    &amp; 361
<7         7    361
<7     retu7n  332st7a href="f7/nilfs2/ioctl.c#L293" id7"L29379e=up_read" cl(actl"lass,fa href="+code=argp" ctlgv" class="sref">argvnilfs_ictlgv" class="sref">argv 354
<7         7nilfs2/ioctl.c#L294" id=7L294"79ef">ret =ass="sre"+code=size" cll.c#L353" id="L353" class f"a href="fs/nilfs2FAULtl.c#L372" id="L3FAULtlass="line" name="L361"> 361
<7tic ;
 361
<7 ic int <7e=nilfs_ioctl_do_get_vin7o" cl79e=buf="line" name="L354"> 354
<7h    if (7            void * 330}
7h        7/nilfs2/ioctl.c#L298" id7"L298797f">rlongcref="+code=__u6octl_move_ic#L223" id="L22octl_move_ilass/nilfs *filpacla" *nilfs_icm" class="sref">bcm"v)unsigne" longcref="+code=__u6>arv" class="sref">arlasss"line" name="L354"> 354
<7h href="f7a href="+code=ret" class7"sref79    <="line" name="L316"> 316  7 href="fs7nilfs2/ioctl.c#L300" id=7L300"79    & inode,
nilfs_ioctl_wrcla" class="sref">acla" * 361
<8     nilfs_i__usede=bh" class="sr__useda hreef="fs/nilfs2/ioctl" class="sref">actl"lasscla( href="sref">nilfs_i__usede=bh" class="sr__useda hree)ref="+code=__u6>arv" class="sref">arlass="line" name="L361"> 361
<8 1   re80lass="line" name="L332"> 332st8     (bcm"v 316  8 3   ret =casef="sref">nilfs_iFS_IOC_GETFLAGSs="sref">filp 330}
8a href="f8/nilfs2/ioctl.c#L305" id8"L30580e=buf" class="sref">b/a>;
actl"lass=="line" name="L361"> 361
<8 5href="f8/=nilfs_ioctl_do_get_vin8L306"80e=buf" class=casef="sref">nilfs_iFS_IOC_SETFLAGSs="sref">filp 330}
8a6href="f8/           void *ret = ;
acla" *actl"lass=="line" name="L361"> 361
<8 7href="f8/nilfs2/ioctl.c#L298" id8cs" c80    nilfs_iFS_IOC_GETVERSIONs2/ioctl.c#L371FS_IOC_GETVERSIONlass:"line" name="L330"> 330}
8a8href="f8/ href="+code=ret" class8f="+c80    actl"lass=="line" name="L361"> 361
<8 9href="f8/ilfs2/ioctl.c#L300" id=8"L31080    &nilfs_iisIOCTL_CHANGE_CPMODEl.c#L372" id="LisIOCTL_CHANGE_CPMODElass:"line" name="L330"> 330}
8     stru8t acla" *bcm"v)f="fs/nilfs2/ioctl" class="sref">actl"lass=="line" name="L361"> 361
<8 1   nilfs_iisIOCTL_DELETE_CHECKPOINtl.c#L372" id="LisIOCTL_DELETE_CHECKPOINtlass:"line" name="L330"> 330}
8     acla" *bcm"v)f="fs/nilfs2/ioctl" class="sref">actl"lass=="line" name="L361"> 361
<8 3   ret =casef="sref">nilfs_iisIOCTL_GET_CPINFOl.c#L372" id="LisIOCTL_GET_CPINFOlass:"line" name="L330"> 330}
8  href="f8ef="+code=down_read" cla8s="sr81e=buf" class="sref">b/a>;
acla" *bcm"v)f="fs/nilfs2/ioctl" class="sref">actl"lass "line" name="L355"> 355st8 href="fs8bbbbbbbbbbbbbbbbbbbbbbbbbbbbbmbs  355st8 6href="f8   ret =  361
<8 7href="f8                        8     81    nilfs_iisIOCTL_GET_CPSTAtl.c#L372" id="LisIOCTL_GET_CPSTAtlass:"line" name="L330"> 330}
8 8href="f8                        8     81    acla" *bcm"v)f="fs/nilfs2/ioctl" class="sref">actl"lass=="line" name="L361"> 361
<8 9href="f8                        8     81    &nilfs_iisIOCTL_GET_SUINFOl.c#L372" id="LisIOCTL_GET_SUINFOlass:"line" name="L330"> 330}
8         8   if (acla" *bcm"v)f="fs/nilfs2/ioctl" class="sref">actl"lass "line" name="L330"> 330}
8 1   ret  355st8         8                    ="""""""""""" href="fs/nilfs"ctl_move_indongec4su.nf.c#L223" id="L22octl_move_indongec4su.nf.lass=="line" name="L361"> 361
<8         8                   retur8 ret =casef="sref">nilfs_iisIOCTL_GET_SUSTAtl.c#L372" id="LisIOCTL_GET_SUSTAtlass:"line" name="L330"> 330}
8  href="f8           }
b/a>;
acla" *bcm"v)f="fs/nilfs2/ioctl" class="sref">actl"lass=="line" name="L361"> 361
<8 href="fs8           nilfs_iisIOCTL_GET_VINFOl.c#L372" id="LisIOCTL_GET_VINFOlass:"line" name="L330"> 330}
8 6href="f8   }
ret = ;
acla" *bcm"v)f="fs/nilfs2/ioctl" class="sref">actl"lass "line" name="L330"> 330}
8 7href="f8href="fs/nilfs2/ioctl.c#8328" 82ef">ret =   355st8 8href="f8ef="+code=up_read" class8"sref82     ="""""""""""" href="fs/nilfs"ctl_move_indongec4v.nf.c#L223" id="L22octl_move_indongec4v.nf.lass=="line" name="L361"> 361
<8 9href="f8n nilfs_iisIOCTL_GET_BDESCSs="sref">filpIOCTL_GET_BDESCSlass:"line" name="L330"> 330}
8a href="f8/nilfs2/ioctl.c#L331" id8"L33183="+code=size" class="/a>;
acla" *bcm"v)f="fs/nilfs2/ioctl" class="sref">actl"lass=="line" name="L361"> 361
<8a        8nilfs2/ioctl.c#L332" id=8L332"831   &nilfs_iisIOCTL_CLEAN_SEGMENTSs="sref">filpIOCTL_CLEAN_SEGMENTSlass:"line" name="L330"> 330}
8a        8 href="+code=nilfs_ioctl8get_b83e=up_read" class="sre/a>;
acla" *bcm"v)f="fs/nilfs2/ioctl" class="sref">actl"lass=="line" name="L361"> 361
<8a        8                     uns8gned 83ef">ret =casef="sref">nilfs_iisIOCTL_SYNCs="sref">filpIOCTL_SYNClass:"line" name="L330"> 330}
8a href="f8/nilfs2/ioctl.c#L335" id8"L33583e=buf" class="sref">b/a>;
acla" *bcm"v)f="fs/nilfs2/ioctl" class="sref">actl"lass=="line" name="L361"> 361
<8ahref="fs8t nilfs_iisIOCTL_RESIZEl.c#L372" id="LisIOCTL_RESIZElass:"line" name="L330"> 330}
8a6href="f8t ret = ;
acla" *actl"lass=="line" name="L361"> 361
<8t7ref="fs8a href="+code=ret" class8"sref83    nilfs_iisIOCTL_SET_ALLOC_RANGEl.c#L372" id="LisIOCTL_SET_ALLOC_RANGElass:"line" name="L330"> 330}
8a8href="f8nilfs2/ioctl.c#L339" id=8L339"83    actl"lass=="line" name="L361"> 361
<8     retu8a href="+code=copy_from_8ser" 83    & 330}
8         8   return -a2NOTTY"+co="line" name="L361"> 361
<8 href="fs8nilfs2/ioctl.c#L342" id=8L342"841"sref">ret 354
<8     if (8a href="+code=argv" clas8="sre84e=up_="line" name="L354"> 354
<8         8   return - 354
<8  href="f8nilfs2/ioctl.c#L345" id=8L345"84e=buf#ifdef f="fs/nilfs2/ioCONFIG_COMPAtl.c#L372" id="LCONFIG_COMPAt  354
<8 href="fs8ef="+code=ret" class="sr8f">re84e=buflongcref="+code=__u6octl_mcompatmove_ic#L223" id="L22octl_mcompatmove_ilass/nilfs *filpacla" *nilfs_icm" class="sref">bcm"v)unsigne" longcref="+code=__u6>arv" class="sref">arlasss"line" name="L354"> 354
<8     stru8                       <8 href84t  316  8     int 8a href="+code=ret" class8"sref84ef">ret =switcha>(bcm"v 316  8         8   return nilfs_i/a>IOC32_GETFLAGSs="sref">filp 330}
8 href="fs8nilfs2/ioctl.c#L350" id=8L350"84    &bcm"vnilfs_ioctl_wrFS_IOC_GETFLAGSs="sref">filp 361
<8     if (8a href="+code=copy_to_us8r" cl85="+code=size" class="break="line" name="L361"> 361
<8 href="fs8   nilfs_iFS_IOC32_SETFLAGSs="sref">filp 330}
8     retu8n bcm"vnilfs_ioctl_wrFS_IOC_SETFLAGSs="sref">filp 361
<8         8/nilfs2/ioctl.c#L354" id8"L35485ef">ret =ass="srebreak="line" name="L361"> 361
<8  href="f8nilfs2/ioctl.c#L355" id=8L355"85e=buf" class=casef="sref">nilfs_i/a>IOC32_GETVERSIONs2/ioctl.c#L371FS_IOC32_GETVERSIONlass:"line" name="L330"> 330}
8 href="fs8 href="+code=nilfs_ioctl8move_85e=buf" class="sref">b(bcm"vnilfs_ioctl_wrFS_IOC_GETVERSIONs2/ioctl.c#L371FS_IOC_GETVERSIONlass="line" name="L361"> 361
<8     stru8                        8  str85ef">ret =  361
<8     int 8                        8  str85    nilfs_iisIOCTL_CHANGE_CPMODEl.c#L372" id="LisIOCTL_CHANGE_CPMODElass:"line" name="L330"> 330}
8         8/nilfs2/ioctl.c#L359" id8"L359858   nilfs_iisIOCTL_DELETE_CHECKPOINtl.c#L372" id="LisIOCTL_DELETE_CHECKPOINtlass:"line" name="L330"> 330}
8 href="fs8t nilfs_iisIOCTL_GET_CPINFOl.c#L372" id="LisIOCTL_GET_CPINFOlass:"line" name="L330"> 330}
8     int 8a href="+code=ret" class8"sref86">down_readnilfs_iisIOCTL_GET_CPSTAtl.c#L372" id="LisIOCTL_GET_CPSTAtlass:"line" name="L330"> 330}
8 href="fs8nilfs2/ioctl.c#L362" id=8L362"861   &nilfs_iisIOCTL_GET_SUINFOl.c#L372" id="LisIOCTL_GET_SUINFOlass:"line" name="L330"> 330}
8     retu8a href="+code=vdesc" cla8s="sr86e=up_read" clcasef="sref">nilfs_iisIOCTL_GET_SUSTAtl.c#L372" id="LisIOCTL_GET_SUSTAtlass:"line" name="L330"> 330}
8         8   ret =casef="sref">nilfs_iisIOCTL_GET_VINFOl.c#L372" id="LisIOCTL_GET_VINFOlass:"line" name="L330"> 330}
8     nilfs_iisIOCTL_GET_BDESCSs="sref">filpIOCTL_GET_BDESCSlass:"line" name="L330"> 330}
8 ic int <8           nilfs_iisIOCTL_CLEAN_SEGMENTSs="sref">filpIOCTL_CLEAN_SEGMENTSlass:"line" name="L330"> 330}
8     stru8nilfs_iisIOCTL_SYNCs="sref">filpIOCTL_SYNClass:"line" name="L330"> 330}
8         8   nilfs_iisIOCTL_RESIZEl.c#L372" id="LisIOCTL_RESIZElass:"line" name="L330"> 330}
8         8           nilfs_iisIOCTL_SET_ALLOC_RANGEl.c#L372" id="LisIOCTL_SET_ALLOC_RANGElass:"line" name="L330"> 330}
8 href="fs8nilfs2/ioctl.c#L370" id=8L370"86    & 361
<8     if (8a href="+code=unlikely" 8lass=87">down_read 330}
8 href="fs8   if (ret;
a2NOIOCTLCMDlass="line" name="L361"> 361
<8     retu8            354
<8         8                  ret =/a>;
acla" *bcm"v)(unsigne" long)ref="+code=__u6compatmptde=bh" class="srcompatmptdlass/ref="+code=__u6>arv" class="sref">arlasss=="line" name="L361"> 361
<8      354
<8 ic int <8nilfs2/ioctl.c#L276" id=8L276"87e=buf#endif"line" name="L354"> 354
<8     stru8 href="+code=nilfs_ioctl8get_s87t 


The original LXR software by thef="sref">nhttp://sourceforge.net/projects/lxr">LXR communityv)this experimental version by ="sref">nmailto:lxr@e=nux.no">lxr@e=nux.nov lxr.e=nux.no kindly hoste" by ="sref">nhttp://www.redpill-e=npro.no">Redpill L=npro ASv)provider of L=nux consulting and operations services since 1995.