git: sys/vfs/hammer2: Fail ioctl(HAMMER2IOC_GROWFS) if size > devvp size

Tomohiro Kusumi tkusumi at crater.dragonflybsd.org
Tue Jun 6 20:23:44 PDT 2023


commit 0f90a2c50b9fb4e368de6603408da30283cb7b63
Author: Tomohiro Kusumi <tkusumi at netbsd.org>
Date:   Wed Jun 7 00:49:20 2023 -0700

    sys/vfs/hammer2: Fail ioctl(HAMMER2IOC_GROWFS) if size > devvp size
    
    Currently, ioctl(HAMMER2IOC_GROWFS) with growfs->size larger than
    devvp size can destroy the volume. The ioctl needs to fail if size
    > devvp size.
    
    Note that hammer2(8) growfs directive always uses growfs->size == 0,
    meaning the volume is always expanded to its devvp size.

Summary of changes:
 sys/vfs/hammer2/hammer2_ioctl.c | 41 +++++++++++++++++++++++++----------------
 1 file changed, 25 insertions(+), 16 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/0f90a2c50b9fb4e368de6603408da30283cb7b63


-- 
DragonFly BSD source repository


More information about the Commits mailing list