* [PATCH 0/2] mm: remove redundant static variable initializations
@ 2026-06-23 11:47 Igor Putko
2026-06-23 11:47 ` [PATCH 1/2] mm/kasan: remove redundant initialization for kasan_flag_write_only Igor Putko
2026-06-23 11:47 ` [PATCH 2/2] mm/memory-failure: remove redundant initialization for hw_memory_failure Igor Putko
0 siblings, 2 replies; 8+ messages in thread
From: Igor Putko @ 2026-06-23 11:47 UTC (permalink / raw)
To: ryabinin.a.a, glider, andreyknvl, dvyukov, vincenzo.frascino,
linmiaohe, nao.horiguchi
Cc: akpm, kasan-dev, linux-mm, linux-kernel, Igor Putko
This series removes explicit initializations of static bool variables to
false within the mm/ subsystem. In C, static variables without explicit
initialization are implicitly placed in the .bss section and initialized
to zero/false by default. Removing these explicit initializations follows
the Linux kernel coding style and avoids cluttering the data section.
Igor Putko (2):
mm/kasan: remove redundant initialization for kasan_flag_write_only
mm/memory-failure: remove redundant initialization for
hw_memory_failure
mm/kasan/hw_tags.c | 2 +-
mm/memory-failure.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
--
2.34.1
^ permalink raw reply [flat|nested] 8+ messages in thread* [PATCH 1/2] mm/kasan: remove redundant initialization for kasan_flag_write_only
2026-06-23 11:47 [PATCH 0/2] mm: remove redundant static variable initializations Igor Putko
@ 2026-06-23 11:47 ` Igor Putko
2026-06-24 0:19 ` SeongJae Park
2026-06-24 5:54 ` Lance Yang
2026-06-23 11:47 ` [PATCH 2/2] mm/memory-failure: remove redundant initialization for hw_memory_failure Igor Putko
1 sibling, 2 replies; 8+ messages in thread
From: Igor Putko @ 2026-06-23 11:47 UTC (permalink / raw)
To: ryabinin.a.a, glider, andreyknvl, dvyukov, vincenzo.frascino,
linmiaohe, nao.horiguchi
Cc: akpm, kasan-dev, linux-mm, linux-kernel, Igor Putko
The static variable 'kasan_flag_write_only' is implicitly initialized
to false. Remove the explicit initialization to follow the Linux
kernel coding style.
Signed-off-by: Igor Putko <igorpetindev@gmail.com>
---
mm/kasan/hw_tags.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mm/kasan/hw_tags.c b/mm/kasan/hw_tags.c
index cbef5e450954..a848eb2f9910 100644
--- a/mm/kasan/hw_tags.c
+++ b/mm/kasan/hw_tags.c
@@ -61,7 +61,7 @@ DEFINE_STATIC_KEY_FALSE(kasan_flag_vmalloc);
EXPORT_SYMBOL_GPL(kasan_flag_vmalloc);
/* Whether to check write accesses only. */
-static bool kasan_flag_write_only = false;
+static bool kasan_flag_write_only;
#define PAGE_ALLOC_SAMPLE_DEFAULT 1
#define PAGE_ALLOC_SAMPLE_ORDER_DEFAULT 3
--
2.34.1
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH 1/2] mm/kasan: remove redundant initialization for kasan_flag_write_only
2026-06-23 11:47 ` [PATCH 1/2] mm/kasan: remove redundant initialization for kasan_flag_write_only Igor Putko
@ 2026-06-24 0:19 ` SeongJae Park
2026-06-24 5:54 ` Lance Yang
1 sibling, 0 replies; 8+ messages in thread
From: SeongJae Park @ 2026-06-24 0:19 UTC (permalink / raw)
To: Igor Putko
Cc: SeongJae Park, ryabinin.a.a, glider, andreyknvl, dvyukov,
vincenzo.frascino, linmiaohe, nao.horiguchi, akpm, kasan-dev,
linux-mm, linux-kernel
On Tue, 23 Jun 2026 14:47:42 +0300 Igor Putko <igorpetindev@gmail.com> wrote:
> The static variable 'kasan_flag_write_only' is implicitly initialized
> to false. Remove the explicit initialization to follow the Linux
> kernel coding style.
>
> Signed-off-by: Igor Putko <igorpetindev@gmail.com>
Reviewed-by: SeongJae Park <sj@kernel.org>
Thanks,
SJ
[...]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 1/2] mm/kasan: remove redundant initialization for kasan_flag_write_only
2026-06-23 11:47 ` [PATCH 1/2] mm/kasan: remove redundant initialization for kasan_flag_write_only Igor Putko
2026-06-24 0:19 ` SeongJae Park
@ 2026-06-24 5:54 ` Lance Yang
1 sibling, 0 replies; 8+ messages in thread
From: Lance Yang @ 2026-06-24 5:54 UTC (permalink / raw)
To: igorpetindev
Cc: ryabinin.a.a, glider, andreyknvl, dvyukov, vincenzo.frascino,
linmiaohe, nao.horiguchi, akpm, kasan-dev, linux-mm, linux-kernel,
Lance Yang
On Tue, Jun 23, 2026 at 02:47:42PM +0300, Igor Putko wrote:
>The static variable 'kasan_flag_write_only' is implicitly initialized
>to false. Remove the explicit initialization to follow the Linux
>kernel coding style.
>
>Signed-off-by: Igor Putko <igorpetindev@gmail.com>
>---
Thanks.
Reviewed-by: Lance Yang <lance.yang@linux.dev>
^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH 2/2] mm/memory-failure: remove redundant initialization for hw_memory_failure
2026-06-23 11:47 [PATCH 0/2] mm: remove redundant static variable initializations Igor Putko
2026-06-23 11:47 ` [PATCH 1/2] mm/kasan: remove redundant initialization for kasan_flag_write_only Igor Putko
@ 2026-06-23 11:47 ` Igor Putko
2026-06-24 0:20 ` SeongJae Park
` (2 more replies)
1 sibling, 3 replies; 8+ messages in thread
From: Igor Putko @ 2026-06-23 11:47 UTC (permalink / raw)
To: ryabinin.a.a, glider, andreyknvl, dvyukov, vincenzo.frascino,
linmiaohe, nao.horiguchi
Cc: akpm, kasan-dev, linux-mm, linux-kernel, Igor Putko
The static variable 'hw_memory_failure' is implicitly initialized
to false. Remove the explicit initialization to follow the Linux
kernel coding style.
Signed-off-by: Igor Putko <igorpetindev@gmail.com>
---
mm/memory-failure.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mm/memory-failure.c b/mm/memory-failure.c
index 51508a55c405..4963ea9f6ec6 100644
--- a/mm/memory-failure.c
+++ b/mm/memory-failure.c
@@ -76,7 +76,7 @@ static int sysctl_enable_soft_offline __read_mostly = 1;
atomic_long_t num_poisoned_pages __read_mostly = ATOMIC_LONG_INIT(0);
-static bool hw_memory_failure __read_mostly = false;
+static bool hw_memory_failure __read_mostly;
static DEFINE_MUTEX(mf_mutex);
--
2.34.1
^ permalink raw reply related [flat|nested] 8+ messages in thread* Re: [PATCH 2/2] mm/memory-failure: remove redundant initialization for hw_memory_failure
2026-06-23 11:47 ` [PATCH 2/2] mm/memory-failure: remove redundant initialization for hw_memory_failure Igor Putko
@ 2026-06-24 0:20 ` SeongJae Park
2026-06-24 5:56 ` Lance Yang
2026-06-24 6:27 ` Miaohe Lin
2 siblings, 0 replies; 8+ messages in thread
From: SeongJae Park @ 2026-06-24 0:20 UTC (permalink / raw)
To: Igor Putko
Cc: SeongJae Park, ryabinin.a.a, glider, andreyknvl, dvyukov,
vincenzo.frascino, linmiaohe, nao.horiguchi, akpm, kasan-dev,
linux-mm, linux-kernel
On Tue, 23 Jun 2026 14:47:43 +0300 Igor Putko <igorpetindev@gmail.com> wrote:
> The static variable 'hw_memory_failure' is implicitly initialized
> to false. Remove the explicit initialization to follow the Linux
> kernel coding style.
>
> Signed-off-by: Igor Putko <igorpetindev@gmail.com>
Reviewed-by: SeongJae Park <sj@kernel.org>
Thanks,
SJ
[...]
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 2/2] mm/memory-failure: remove redundant initialization for hw_memory_failure
2026-06-23 11:47 ` [PATCH 2/2] mm/memory-failure: remove redundant initialization for hw_memory_failure Igor Putko
2026-06-24 0:20 ` SeongJae Park
@ 2026-06-24 5:56 ` Lance Yang
2026-06-24 6:27 ` Miaohe Lin
2 siblings, 0 replies; 8+ messages in thread
From: Lance Yang @ 2026-06-24 5:56 UTC (permalink / raw)
To: igorpetindev
Cc: ryabinin.a.a, glider, andreyknvl, dvyukov, vincenzo.frascino,
linmiaohe, nao.horiguchi, akpm, kasan-dev, linux-mm, linux-kernel,
Lance Yang
On Tue, Jun 23, 2026 at 02:47:43PM +0300, Igor Putko wrote:
>The static variable 'hw_memory_failure' is implicitly initialized
>to false. Remove the explicit initialization to follow the Linux
>kernel coding style.
>
>Signed-off-by: Igor Putko <igorpetindev@gmail.com>
>---
Thanks.
Reviewed-by: Lance Yang <lance.yang@linux.dev>
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 2/2] mm/memory-failure: remove redundant initialization for hw_memory_failure
2026-06-23 11:47 ` [PATCH 2/2] mm/memory-failure: remove redundant initialization for hw_memory_failure Igor Putko
2026-06-24 0:20 ` SeongJae Park
2026-06-24 5:56 ` Lance Yang
@ 2026-06-24 6:27 ` Miaohe Lin
2 siblings, 0 replies; 8+ messages in thread
From: Miaohe Lin @ 2026-06-24 6:27 UTC (permalink / raw)
To: Igor Putko
Cc: akpm, kasan-dev, linux-mm, linux-kernel, ryabinin.a.a, glider,
andreyknvl, dvyukov, vincenzo.frascino, nao.horiguchi
On 2026/6/23 19:47, Igor Putko wrote:
> The static variable 'hw_memory_failure' is implicitly initialized
> to false. Remove the explicit initialization to follow the Linux
> kernel coding style.
>
> Signed-off-by: Igor Putko <igorpetindev@gmail.com>
Acked-by: Miaohe Lin <linmiaohe@huawei.com>
Thanks.
.
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2026-06-24 6:28 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-23 11:47 [PATCH 0/2] mm: remove redundant static variable initializations Igor Putko
2026-06-23 11:47 ` [PATCH 1/2] mm/kasan: remove redundant initialization for kasan_flag_write_only Igor Putko
2026-06-24 0:19 ` SeongJae Park
2026-06-24 5:54 ` Lance Yang
2026-06-23 11:47 ` [PATCH 2/2] mm/memory-failure: remove redundant initialization for hw_memory_failure Igor Putko
2026-06-24 0:20 ` SeongJae Park
2026-06-24 5:56 ` Lance Yang
2026-06-24 6:27 ` Miaohe Lin
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.