All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] Build fixes for liblockdep
@ 2018-08-28 23:36 Ben Hutchings
  2018-08-28 23:37 ` [PATCH 1/2] liblockdep: Stub NMI watchdog reset Ben Hutchings
  2018-08-28 23:37 ` [PATCH 2/2] liblockdep: Stub task_struct::state Ben Hutchings
  0 siblings, 2 replies; 4+ messages in thread
From: Ben Hutchings @ 2018-08-28 23:36 UTC (permalink / raw)
  To: Sasha Levin; +Cc: linux-kernel

[-- Attachment #1: Type: text/plain, Size: 418 bytes --]

In addition to the patch I recently sent for lockdep itself, the
following fixes are also needed to make liblockdep build.

Ben.

Bastian Blank (1):
  liblockdep: Stub NMI watchdog reset

Ben Hutchings (1):
  liblockdep: Stub task_struct::state

 tools/include/linux/lockdep.h |  4 ++++
 tools/include/linux/nmi.h     | 12 ++++++++++++
 2 files changed, 16 insertions(+)
 create mode 100644 tools/include/linux/nmi.h


[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 811 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH 1/2] liblockdep: Stub NMI watchdog reset
  2018-08-28 23:36 [PATCH 0/2] Build fixes for liblockdep Ben Hutchings
@ 2018-08-28 23:37 ` Ben Hutchings
  2018-08-28 23:37 ` [PATCH 2/2] liblockdep: Stub task_struct::state Ben Hutchings
  1 sibling, 0 replies; 4+ messages in thread
From: Ben Hutchings @ 2018-08-28 23:37 UTC (permalink / raw)
  To: Sasha Levin; +Cc: linux-kernel, Bastian Blank

[-- Attachment #1: Type: text/plain, Size: 841 bytes --]

From: Bastian Blank <waldi@debian.org>

lockdep.c now includes <linux/nmi.h> and requires touch_nmi_watchdog(),
so provide those for liblockdep.

Fixes: 88f1c87de11a ("locking/lockdep: Avoid triggering hardlockup from ...")
[bwh: Write a longer description]
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
---
 tools/include/linux/nmi.h | 12 ++++++++++++
 1 file changed, 12 insertions(+)
 create mode 100644 tools/include/linux/nmi.h

diff --git a/tools/include/linux/nmi.h b/tools/include/linux/nmi.h
new file mode 100644
index 000000000000..81ffb39343cc
--- /dev/null
+++ b/tools/include/linux/nmi.h
@@ -0,0 +1,12 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+/*
+ *  linux/include/linux/nmi.h
+ */
+#ifndef LINUX_NMI_H
+#define LINUX_NMI_H
+
+static inline void touch_nmi_watchdog(void)
+{
+}
+
+#endif


[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 811 bytes --]

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH 2/2] liblockdep: Stub task_struct::state
  2018-08-28 23:36 [PATCH 0/2] Build fixes for liblockdep Ben Hutchings
  2018-08-28 23:37 ` [PATCH 1/2] liblockdep: Stub NMI watchdog reset Ben Hutchings
@ 2018-08-28 23:37 ` Ben Hutchings
  1 sibling, 0 replies; 4+ messages in thread
From: Ben Hutchings @ 2018-08-28 23:37 UTC (permalink / raw)
  To: Sasha Levin; +Cc: linux-kernel

[-- Attachment #1: Type: text/plain, Size: 920 bytes --]

lockdep_print_held_locks() now checks task_struct::state.  Define it
so that all tasks are assumed to be running, since we have no
reasonble way to tell in user-space.

Fixes: 8cc05c71ba5f ("locking/lockdep: Move sanity check to inside ...")
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
---
 tools/include/linux/lockdep.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/tools/include/linux/lockdep.h b/tools/include/linux/lockdep.h
index 6b0c36a58fcb..8e84609afb04 100644
--- a/tools/include/linux/lockdep.h
+++ b/tools/include/linux/lockdep.h
@@ -31,12 +31,16 @@ struct task_struct {
 	gfp_t lockdep_reclaim_gfp;
 	int pid;
 	char comm[17];
+	long state;
 };
 
 extern struct task_struct *__curr(void);
 
 #define current (__curr())
 
+/* lockdep checks task_struct::state == TASK_RUNNING */
+#define TASK_RUNNING 0
+
 static inline int debug_locks_off(void)
 {
 	return 1;

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 811 bytes --]

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH 1/2] liblockdep: Stub NMI watchdog reset
  2018-08-28 23:56 [PATCH 0/2] Build fixes for liblockdep Ben Hutchings
@ 2018-08-28 23:57 ` Ben Hutchings
  0 siblings, 0 replies; 4+ messages in thread
From: Ben Hutchings @ 2018-08-28 23:57 UTC (permalink / raw)
  To: Sasha Levin; +Cc: linux-kernel, Bastian Blank

From: Bastian Blank <waldi@debian.org>

lockdep.c now includes <linux/nmi.h> and requires touch_nmi_watchdog(),
so provide those for liblockdep.

Fixes: 88f1c87de11a ("locking/lockdep: Avoid triggering hardlockup from ...")
[bwh: Write a longer description]
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
---
 tools/include/linux/nmi.h | 12 ++++++++++++
 1 file changed, 12 insertions(+)
 create mode 100644 tools/include/linux/nmi.h

diff --git a/tools/include/linux/nmi.h b/tools/include/linux/nmi.h
new file mode 100644
index 000000000000..81ffb39343cc
--- /dev/null
+++ b/tools/include/linux/nmi.h
@@ -0,0 +1,12 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+/*
+ *  linux/include/linux/nmi.h
+ */
+#ifndef LINUX_NMI_H
+#define LINUX_NMI_H
+
+static inline void touch_nmi_watchdog(void)
+{
+}
+
+#endif


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-08-28 23:57 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-08-28 23:36 [PATCH 0/2] Build fixes for liblockdep Ben Hutchings
2018-08-28 23:37 ` [PATCH 1/2] liblockdep: Stub NMI watchdog reset Ben Hutchings
2018-08-28 23:37 ` [PATCH 2/2] liblockdep: Stub task_struct::state Ben Hutchings
  -- strict thread matches above, loose matches on Subject: below --
2018-08-28 23:56 [PATCH 0/2] Build fixes for liblockdep Ben Hutchings
2018-08-28 23:57 ` [PATCH 1/2] liblockdep: Stub NMI watchdog reset Ben Hutchings

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.