+ fs-ntfs-fix-set-but-not-used-variable-log_page_mask.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     Subject: fs/ntfs: fix set but not used variable 'log_page_mask'
has been added to the -mm tree.  Its filename is
     fs-ntfs-fix-set-but-not-used-variable-log_page_mask.patch

This patch should soon appear at
    https://ozlabs.org/~akpm/mmots/broken-out/fs-ntfs-fix-set-but-not-used-variable-log_page_mask.patch
and later at
    https://ozlabs.org/~akpm/mmotm/broken-out/fs-ntfs-fix-set-but-not-used-variable-log_page_mask.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Zheng Zengkai <zhengzengkai@xxxxxxxxxx>
Subject: fs/ntfs: fix set but not used variable 'log_page_mask'

Fixes gcc '-Wunused-but-set-variable' warning:

fs/ntfs/logfile.c: In function ntfs_check_logfile:
fs/ntfs/logfile.c:481:21:
 warning: variable log_page_mask set but not used [-Wunused-but-set-variable]

Actually log_page_mask can be used to replace 'log_page_size - 1' as it is set.

Link: https://lkml.kernel.org/r/20200312041353.19877-1-zhengzengkai@xxxxxxxxxx
Signed-off-by: Zheng Zengkai <zhengzengkai@xxxxxxxxxx>
Acked-by: Anton Altaparmakov <anton@xxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 fs/ntfs/logfile.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/fs/ntfs/logfile.c~fs-ntfs-fix-set-but-not-used-variable-log_page_mask
+++ a/fs/ntfs/logfile.c
@@ -506,7 +506,7 @@ bool ntfs_check_logfile(struct inode *lo
 	 * optimize log_page_size and log_page_bits into constants.
 	 */
 	log_page_bits = ntfs_ffs(log_page_size) - 1;
-	size &= ~(s64)(log_page_size - 1);
+	size &= ~(s64)(log_page_mask);
 	/*
 	 * Ensure the log file is big enough to store at least the two restart
 	 * pages and the minimum number of log record pages.
_

Patches currently in -mm which might be from zhengzengkai@xxxxxxxxxx are

fs-ntfs-fix-set-but-not-used-variable-log_page_mask.patch




[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux