linux-stable/fs/ubifs
Zhihao Cheng e619939a53 ubifs: setflags: Make dirtied_ino_d 8 bytes aligned
commit 1b83ec057d upstream.

Make 'ui->data_len' aligned with 8 bytes before it is assigned to
dirtied_ino_d. Since 8871d84c8f8b0c6b("ubifs: convert to fileattr")
applied, 'setflags()' only affects regular files and directories, only
xattr inode, symlink inode and special inode(pipe/char_dev/block_dev)
have none- zero 'ui->data_len' field, so assertion
'!(req->dirtied_ino_d & 7)' cannot fail in ubifs_budget_space().
To avoid assertion fails in future evolution(eg. setflags can operate
special inodes), it's better to make dirtied_ino_d 8 bytes aligned,
after all aligned size is still zero for regular files.

Fixes: 1e51764a3c ("UBIFS: add new flash file system")
Signed-off-by: Zhihao Cheng <chengzhihao1@huawei.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-04-20 09:06:40 +02:00
..
Kconfig
Makefile
budget.c
commit.c
compress.c
debug.c ubifs: dent: Fix some potential memory leaks while iterating entries 2020-11-10 10:23:58 +01:00
debug.h
dir.c ubifs: Add missing iput if do_tmpfile() failed in rename whiteout 2022-04-20 09:06:40 +02:00
file.c ubifs: Fix deadlock in concurrent bulk-read and writepage 2020-02-14 16:31:00 -05:00
find.c
gc.c UBIFS: improve function-level documentation 2016-10-02 22:55:02 +02:00
io.c ubifs: wbuf: Don't leak kernel memory to flash 2021-01-17 13:57:54 +01:00
ioctl.c ubifs: setflags: Make dirtied_ino_d 8 bytes aligned 2022-04-20 09:06:40 +02:00
journal.c ubifs: Fix synced_i_size calculation for xattr inodes 2018-09-09 20:01:24 +02:00
key.h
log.c
lprops.c ubifs: Fix memory leak in lprobs self-check 2018-09-09 20:01:24 +02:00
lpt.c
lpt_commit.c UBIFS: improve function-level documentation 2016-10-02 22:55:02 +02:00
master.c
misc.c
misc.h
orphan.c
recovery.c
replay.c ubifs: Handle re-linking of inodes correctly while recovery 2018-12-29 13:40:16 +01:00
sb.c lib/uuid.c: move generate_random_uuid() to uuid.c 2016-05-20 17:58:30 -07:00
scan.c
shrinker.c
super.c ubifs: Error path in ubifs_remount_rw() seems to wrongly free write buffers 2022-01-27 08:47:40 +01:00
tnc.c ubifs: Fix journal replay wrt. xattr nodes 2017-01-26 08:24:40 +01:00
tnc_commit.c ubifs: Fix assertion in layout_in_gaps() 2016-08-23 23:02:40 +02:00
tnc_misc.c
ubifs-media.h
ubifs.h ubifs: Implement RENAME_EXCHANGE 2016-10-02 22:55:02 +02:00
xattr.c ubifs: Massage assert in ubifs_xattr_set() wrt. init_xattrs 2018-02-17 13:21:14 +01:00