diff options
| author | Greg Kurz <groug@kaod.org> | 2021-01-18 15:22:59 +0100 |
|---|---|---|
| committer | Greg Kurz <groug@kaod.org> | 2021-01-21 17:49:45 +0100 |
| commit | feabd6cf78ca3b57da2ce48e95b704e72147bf2c (patch) | |
| tree | e17c398181af7c2749ca769fe0e5a33517b60248 /hw/9pfs/9p.h | |
| parent | 2e53160fc62d4d59c76bf93c7a90bd739b8b8157 (diff) | |
| download | focaccia-qemu-feabd6cf78ca3b57da2ce48e95b704e72147bf2c.tar.gz focaccia-qemu-feabd6cf78ca3b57da2ce48e95b704e72147bf2c.zip | |
9pfs: Convert V9fsFidState::fid_list to QSIMPLEQ
The fid_list is currently open-coded. This doesn't seem to serve any purpose that cannot be met with QEMU's generic lists. Let's go for a QSIMPLEQ : this will allow to add new fids at the end of the list and to improve the logic in v9fs_mark_fids_unreclaim(). Reviewed-by: Christian Schoenebeck <qemu_oss@crudebyte.com> Message-Id: <20210118142300.801516-3-groug@kaod.org> Signed-off-by: Greg Kurz <groug@kaod.org>
Diffstat (limited to 'hw/9pfs/9p.h')
| -rw-r--r-- | hw/9pfs/9p.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/9pfs/9p.h b/hw/9pfs/9p.h index 93656323d1..85fb6930b0 100644 --- a/hw/9pfs/9p.h +++ b/hw/9pfs/9p.h @@ -280,7 +280,7 @@ struct V9fsFidState { uid_t uid; int ref; bool clunked; - V9fsFidState *next; + QSIMPLEQ_ENTRY(V9fsFidState) next; V9fsFidState *rclm_lst; }; @@ -339,7 +339,7 @@ typedef struct { struct V9fsState { QLIST_HEAD(, V9fsPDU) free_list; QLIST_HEAD(, V9fsPDU) active_list; - V9fsFidState *fid_list; + QSIMPLEQ_HEAD(, V9fsFidState) fid_list; FileOperations *ops; FsContext ctx; char *tag; |