All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Jordan <daniel.m.jordan@oracle.com>
To: Corentin Labbe <clabbe.montjoie@gmail.com>
Cc: Daniel Jordan <daniel.m.jordan@oracle.com>,
	Will Deacon <will@kernel.org>,
	tj@kernel.org, jiangshanlai@gmail.com, mark.rutland@arm.com,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-crypto@vger.kernel.org
Subject: Re: WARNING: at kernel/workqueue.c:1473 __queue_work+0x3b8/0x3d0
Date: Mon, 2 Mar 2020 12:25:10 -0500	[thread overview]
Message-ID: <20200302172510.fspofleipqjcdxak@ca-dmjordan1.us.oracle.com> (raw)
In-Reply-To: <20200301175351.GA11684@Red>

On Sun, Mar 01, 2020 at 06:53:51PM +0100, Corentin Labbe wrote:
> I tried to bisect this problem, but the result is:
...
> # first bad commit: [81ff5d2cba4f86cd850b9ee4a530cd221ee45aa3] Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
> 
> The only interesting thing I see in this MR is: "Add fuzz testing to testmgr"
> 
> But this wont help.

Hm, that merge commit has only a couple lines of powerpc build change, so maybe
there's something nondeterministic going on.

Does this fix it?  I can't verify but figure it's worth trying the simplest
explanation first, which is that the work isn't initialized by the time it's
queued.

thanks,
daniel

---8<---

Subject: [PATCH] module: statically initialize init section freeing data

Signed-off-by: Daniel Jordan <daniel.m.jordan@oracle.com>
---
 kernel/module.c | 13 +++----------
 1 file changed, 3 insertions(+), 10 deletions(-)

diff --git a/kernel/module.c b/kernel/module.c
index 33569a01d6e1..db0cda206167 100644
--- a/kernel/module.c
+++ b/kernel/module.c
@@ -88,8 +88,9 @@ EXPORT_SYMBOL_GPL(module_mutex);
 static LIST_HEAD(modules);
 
 /* Work queue for freeing init sections in success case */
-static struct work_struct init_free_wq;
-static struct llist_head init_free_list;
+static void do_free_init(struct work_struct *w);
+static DECLARE_WORK(init_free_wq, do_free_init);
+static LLIST_HEAD(init_free_list);
 
 #ifdef CONFIG_MODULES_TREE_LOOKUP
 
@@ -3501,14 +3502,6 @@ static void do_free_init(struct work_struct *w)
 	}
 }
 
-static int __init modules_wq_init(void)
-{
-	INIT_WORK(&init_free_wq, do_free_init);
-	init_llist_head(&init_free_list);
-	return 0;
-}
-module_init(modules_wq_init);
-
 /*
  * This is where the real work happens.
  *
-- 
2.25.1


WARNING: multiple messages have this Message-ID (diff)
From: Daniel Jordan <daniel.m.jordan@oracle.com>
To: Corentin Labbe <clabbe.montjoie@gmail.com>
Cc: mark.rutland@arm.com, jiangshanlai@gmail.com,
	linux-kernel@vger.kernel.org,
	Daniel Jordan <daniel.m.jordan@oracle.com>,
	linux-crypto@vger.kernel.org, tj@kernel.org,
	Will Deacon <will@kernel.org>,
	linux-arm-kernel@lists.infradead.org
Subject: Re: WARNING: at kernel/workqueue.c:1473 __queue_work+0x3b8/0x3d0
Date: Mon, 2 Mar 2020 12:25:10 -0500	[thread overview]
Message-ID: <20200302172510.fspofleipqjcdxak@ca-dmjordan1.us.oracle.com> (raw)
In-Reply-To: <20200301175351.GA11684@Red>

On Sun, Mar 01, 2020 at 06:53:51PM +0100, Corentin Labbe wrote:
> I tried to bisect this problem, but the result is:
...
> # first bad commit: [81ff5d2cba4f86cd850b9ee4a530cd221ee45aa3] Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
> 
> The only interesting thing I see in this MR is: "Add fuzz testing to testmgr"
> 
> But this wont help.

Hm, that merge commit has only a couple lines of powerpc build change, so maybe
there's something nondeterministic going on.

Does this fix it?  I can't verify but figure it's worth trying the simplest
explanation first, which is that the work isn't initialized by the time it's
queued.

thanks,
daniel

---8<---

Subject: [PATCH] module: statically initialize init section freeing data

Signed-off-by: Daniel Jordan <daniel.m.jordan@oracle.com>
---
 kernel/module.c | 13 +++----------
 1 file changed, 3 insertions(+), 10 deletions(-)

diff --git a/kernel/module.c b/kernel/module.c
index 33569a01d6e1..db0cda206167 100644
--- a/kernel/module.c
+++ b/kernel/module.c
@@ -88,8 +88,9 @@ EXPORT_SYMBOL_GPL(module_mutex);
 static LIST_HEAD(modules);
 
 /* Work queue for freeing init sections in success case */
-static struct work_struct init_free_wq;
-static struct llist_head init_free_list;
+static void do_free_init(struct work_struct *w);
+static DECLARE_WORK(init_free_wq, do_free_init);
+static LLIST_HEAD(init_free_list);
 
 #ifdef CONFIG_MODULES_TREE_LOOKUP
 
@@ -3501,14 +3502,6 @@ static void do_free_init(struct work_struct *w)
 	}
 }
 
-static int __init modules_wq_init(void)
-{
-	INIT_WORK(&init_free_wq, do_free_init);
-	init_llist_head(&init_free_list);
-	return 0;
-}
-module_init(modules_wq_init);
-
 /*
  * This is where the real work happens.
  *
-- 
2.25.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2020-03-02 17:26 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-17 20:48 WARNING: at kernel/workqueue.c:1473 __queue_work+0x3b8/0x3d0 Corentin Labbe
2020-02-17 20:48 ` Corentin Labbe
2020-02-18 16:35 ` Daniel Jordan
2020-02-18 16:35   ` Daniel Jordan
2020-02-20  9:03   ` Corentin Labbe
2020-02-20  9:03     ` Corentin Labbe
2020-02-21 17:42     ` Daniel Jordan
2020-02-21 17:42       ` Daniel Jordan
2020-02-28 12:33       ` Will Deacon
2020-02-28 12:33         ` Will Deacon
2020-02-28 15:33         ` Daniel Jordan
2020-02-28 15:33           ` Daniel Jordan
2020-03-01 17:53           ` Corentin Labbe
2020-03-01 17:53             ` Corentin Labbe
2020-03-02 17:25             ` Daniel Jordan [this message]
2020-03-02 17:25               ` Daniel Jordan
2020-03-02 18:00               ` Robin Murphy
2020-03-02 18:00                 ` Robin Murphy
2020-03-03 21:30                 ` Daniel Jordan
2020-03-03 21:30                   ` Daniel Jordan
2020-03-03 22:43                   ` Eric Biggers
2020-03-03 22:43                     ` Eric Biggers
2020-03-06 16:12                     ` Daniel Jordan
2020-03-06 16:12                       ` Daniel Jordan
2020-10-01 17:50                   ` Corentin Labbe
2020-10-05 17:09                     ` Daniel Jordan
2020-10-05 17:09                       ` Daniel Jordan
2020-10-07 19:41                       ` Corentin Labbe
2020-10-07 19:41                         ` Corentin Labbe
2020-10-08 17:07                         ` Daniel Jordan
2020-10-08 17:07                           ` Daniel Jordan
2020-03-03  7:48               ` Corentin Labbe
2020-03-03  7:48                 ` Corentin Labbe
2020-03-03 21:31                 ` Daniel Jordan
2020-03-03 21:31                   ` Daniel Jordan
2020-09-25 18:12                   ` Corentin Labbe
2020-09-25 18:12                     ` Corentin Labbe
2020-09-30 18:18                     ` Daniel Jordan
2020-09-30 18:18                       ` Daniel Jordan

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=20200302172510.fspofleipqjcdxak@ca-dmjordan1.us.oracle.com \
    --to=daniel.m.jordan@oracle.com \
    --cc=clabbe.montjoie@gmail.com \
    --cc=jiangshanlai@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=tj@kernel.org \
    --cc=will@kernel.org \
    /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 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.