]> git.ipfire.org Git - thirdparty/qemu.git/commit
9pfs: Introduce ftruncate file op
authorGreg Kurz <groug@kaod.org>
Wed, 12 Mar 2025 15:29:29 +0000 (16:29 +0100)
committerChristian Schoenebeck <qemu_oss@crudebyte.com>
Mon, 5 May 2025 09:28:29 +0000 (11:28 +0200)
commit0c798dd52355f3489b29bba0dfd7df0e24cfa1dd
treed563a14ff4c72b91fa2e0ab4865827c8453a4598
parentf2bb367d2b265c6c0ead1e0d4a8f7c43310b3107
9pfs: Introduce ftruncate file op

Add an ftruncate operation to the fs driver and use if when a fid has
a valid file descriptor. This is required to support more cases where
the client wants to do an action on an unlinked file which it still
has an open file decriptor for.

Only 9P2000.L was considered.

Signed-off-by: Greg Kurz <groug@kaod.org>
Reviewed-by: Christian Schoenebeck <qemu_oss@crudebyte.com>
Message-Id: <20250312152933.383967-4-groug@kaod.org>
Signed-off-by: Christian Schoenebeck <qemu_oss@crudebyte.com>
fsdev/file-op-9p.h
hw/9pfs/9p-local.c
hw/9pfs/9p-synth.c
hw/9pfs/9p.c
hw/9pfs/cofs.c
hw/9pfs/coth.h