[PATCH] ovl: check IOCB_APPEND flag

From: Weizhao Ouyang
Date: Sat Nov 19 2022 - 22:42:12 EST


Add *_APPEND flag for ovl_iocb_to_rwf().

Signed-off-by: Weizhao Ouyang <o451686892@xxxxxxxxx>
---
fs/overlayfs/file.c | 2 ++
1 file changed, 2 insertions(+)

diff --git a/fs/overlayfs/file.c b/fs/overlayfs/file.c
index a1a22f58ba18..ed286dd0e719 100644
--- a/fs/overlayfs/file.c
+++ b/fs/overlayfs/file.c
@@ -244,6 +244,8 @@ static rwf_t ovl_iocb_to_rwf(int ifl)
{
rwf_t flags = 0;

+ if (ifl & IOCB_APPEND)
+ flags |= RWF_APPEND;
if (ifl & IOCB_NOWAIT)
flags |= RWF_NOWAIT;
if (ifl & IOCB_HIPRI)
--
2.37.2