mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Bert Karwatzki <spasswolf@web.de>
To: linux-kernel@vger.kernel.org
Cc: Bert Karwatzki <spasswolf@web.de>,
	Johannes Weiner <hannes@cmpxchg.org>,
	Michal Hocko <mhocko@kernel.org>,
	Roman Gushchin <roman.gushchin@linux.dev>,
	Shakeel Butt <shakeel.butt@linux.dev>,
	Muchun Song <muchun.song@linux.dev>,
	cgroups@vger.kernel.org, linux-mm@kvack.org,
	linux-next@vger.kernel.org
Subject: [PATCH] mm: memcontrol: fix compilation
Date: Mon,  7 Sep 2026 16:14:07 +0200	[thread overview]
Message-ID: <20260907141409.215031-1-spasswolf@web.de> (raw)

Signed-off-by: Bert Karwatzki <spasswolf@web.de>
---
 mm/memcontrol.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index 5b9e0ebd42ae..e50135df6e82 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -71,6 +71,7 @@
 #include "memcontrol-v1.h"
 
 #include <linux/uaccess.h>
+#include <linux/irq_work.h>
 
 #define CREATE_TRACE_POINTS
 #include <trace/events/memcg.h>
-- 
2.55.0

In next-20260904 compilation fails with this error:

mm/memcontrol.c: In function ‘try_charge_memcg’:
mm/memcontrol.c:2859:41: error: implicit declaration of function ‘irq_work_queue’; did you mean ‘drain_workqueue’? [-Wimplicit-function-declaration]
 2859 |                                         irq_work_queue(&memcg->high_irq_work);
      |                                         ^~~~~~~~~~~~~~
      |                                         drain_workqueue
  CC [M]  drivers/usb/typec/ucsi/ucsi.o
  CC [M]  drivers/usb/typec/tipd/core.o
mm/memcontrol.c: In function ‘mem_cgroup_alloc’:
mm/memcontrol.c:4234:9: error: implicit declaration of function ‘init_irq_work’; did you mean ‘init_irq_proc’? [-Wimplicit-function-declaration]
 4234 |         init_irq_work(&memcg->high_irq_work, high_irq_work_func);
      |         ^~~~~~~~~~~~~
      |         init_irq_proc
  CC [M]  drivers/net/wireless/mediatek/mt76/mt792x_acpi_sar.o
mm/memcontrol.c: In function ‘mem_cgroup_css_free’:
mm/memcontrol.c:4443:9: error: implicit declaration of function ‘irq_work_sync’ [-Wimplicit-function-declaration]
 4443 |         irq_work_sync(&memcg->high_irq_work);
      |         ^~~~~~~~~~~~~

explicitly including include/linux/irq_work.h fixes the issue.

Bert Karwatzki

             reply	other threads:[~2026-09-07 14:19 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-07 14:14 Bert Karwatzki [this message]
     [not found] ` <20260907141808.3F4581F00A3A@smtp.kernel.org>
2026-09-07 17:29   ` Bert Karwatzki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260907141409.215031-1-spasswolf@web.de \
    --to=spasswolf@web.de \
    --cc=cgroups@vger.kernel.org \
    --cc=hannes@cmpxchg.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=linux-next@vger.kernel.org \
    --cc=mhocko@kernel.org \
    --cc=muchun.song@linux.dev \
    --cc=roman.gushchin@linux.dev \
    --cc=shakeel.butt@linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®