Skip to contentSkip to conversation

statedump: adjust to v6.7 cpu topology struct

PATCH In review Bruce Ashfield via lttng-dev 1 participant 7 messages Nov 23, 2023 – Nov 28, 2023

lore
Share & tools
lore
#0 lore raw

PATCH 1/3 statedump: adjust to v6.7 cpu topology struct

From: Bruce Ashfield <[email protected]>

Adjusting the statedump to the following upstream commits:

commit b9655e702dc5 [x86/cpu: Encapsulate topology information in cpuinfo_x86] commit e95256335d45 [x86/cpu: Move cpu_core_id into topology info] commit 02fb601d27a7 [x86/cpu: Move phys_proc_id into topology info]

We now have the topo struct, as well as some minor member name changes.

---

Someone else may or may not already have this in flight, but I didn't see anything on the list or in the git repo.

I ran into this failure when working on the v6.7-rc kernel as part of yocto project kernel updates.

Tweak as necessary, as I'm no expert in the right way to version these sort of changes.

Bruce

 include/instrumentation/events/lttng-statedump.h | 5 +++++
 1 file changed, 5 insertions(+)
include/instrumentation/events/lttng-statedump.h +5 -0
index 642aa356..5f52a29c 100644
@@ -263,8 +263,13 @@ LTTNG_TRACEPOINT_EVENT(lttng_statedump_cpu_topology,
 		ctf_integer(uint8_t, family, c->x86)
 		ctf_integer(uint8_t, model, c->x86_model)
 		ctf_string(model_name, c->x86_model_id[0] ? c->x86_model_id : "unknown")
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
 		ctf_integer(uint16_t, physical_id, c->phys_proc_id)
 		ctf_integer(uint16_t, core_id, c->cpu_core_id)
+#else
+		ctf_integer(uint16_t, physical_id, c->topo.pkg_id)
+		ctf_integer(uint16_t, core_id, c->topo.core_id)
+#endif
 		ctf_integer(uint16_t, cores, c->booted_cores)
 	)
 )
Signature · 6 lines
2.34.1

_______________________________________________
lttng-dev mailing list
[email protected]
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
#1 lore raw

PATCH 2/3 wrapper/fdtable: adjust fd lookup to v6.7+

From: Bruce Ashfield <[email protected]>

commit 0ede61d8589cc2d93 [file: convert to SLAB_TYPESAFE_BY_RCU] renames lookup_fd_rcu to lookup_fdget_rcu, so we need to version adjust the fdtable wrapper accordingly.

---

Repeating the comment from patch 1 of this series:

Someone else may or may not already have this in flight, but I didn't see anything on the list or in the git repo.

I ran into this failure when working on the v6.7-rc kernel as part of yocto project kernel updates.

Tweak as necessary, as I'm no expert in the right way to version these sort of changes.

Bruce

 include/wrapper/fdtable.h | 4 ++++
 1 file changed, 4 insertions(+)
include/wrapper/fdtable.h +4 -0
index fa5f7207..aaf2b9e7 100644
@@ -16,7 +16,11 @@
 static inline
 struct file *lttng_lookup_fd_rcu(unsigned int fd)
 {
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
 	return lookup_fd_rcu(fd);
+#else
+	return lookup_fdget_rcu(fd);
+#endif
 }
 #else
 static inline
Signature · 6 lines
2.34.1

_______________________________________________
lttng-dev mailing list
[email protected]
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
#2 lore raw

PATCH 3/3 vmscan: drop isolate_mode (v6.7+)

In reply to Bruce Ashfield via lttng-dev

From: Bruce Ashfield <[email protected]>

commit 3dfbb555c98ac55b9 [mm, vmscan: remove ISOLATE_UNMAPPED] makes the isolate_mode parameter unused, so it is removed.

This updates the event to match.

---

Repeating the comment from patch 1 & 2 of this series:

Someone else may or may not already have this in flight, but I didn't see anything on the list or in the git repo.

I ran into this failure when working on the v6.7-rc kernel as part of yocto project kernel updates.

Tweak as necessary, as I'm no expert in the right way to version these sort of changes.

Bruce

 include/instrumentation/events/mm_vmscan.h | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)
include/instrumentation/events/mm_vmscan.h +9 -1
index e7e9b613..a3e9ddf2 100644
@@ -343,12 +343,18 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate,
 		unsigned long nr_scanned,
 		unsigned long nr_skipped,
 		unsigned long nr_taken,
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
 		isolate_mode_t isolate_mode,
+#endif
 		int lru
 	),
 
 	TP_ARGS(classzone_idx, order, nr_requested, nr_scanned, nr_skipped,
-		nr_taken, isolate_mode, lru
+		nr_taken,
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
+		isolate_mode,
+#endif
+		lru
 	),
 
 	TP_FIELDS(
@@ -358,7 +364,9 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate,
 		ctf_integer(unsigned long, nr_scanned, nr_scanned)
 		ctf_integer(unsigned long, nr_skipped, nr_skipped)
 		ctf_integer(unsigned long, nr_taken, nr_taken)
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
 		ctf_integer(isolate_mode_t, isolate_mode, isolate_mode)
+#endif
 		ctf_integer(int, lru, lru)
 	)
 )
Signature · 6 lines
2.34.1

_______________________________________________
lttng-dev mailing list
[email protected]
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
#3 lore raw

Re: [lttng-dev] [PATCH 3/3] vmscan: drop isolate_mode (v6.7+)

Hi Bruce,

thanks for the patches! There's a similar series waiting for review: https://review.lttng.org/q/topic:%22fix-linux-6.7.0-rc1%22

thanks,
kienan

Quoted 52 lines · Bruce Ashfield via lttng-dev

From: Bruce Ashfield <[email protected]>

commit 3dfbb555c98ac55b9 [mm, vmscan: remove ISOLATE_UNMAPPED] makes the isolate_mode parameter unused, so it is removed.

This updates the event to match.

---

Repeating the comment from patch 1 & 2 of this series:

Someone else may or may not already have this in flight, but I didn't see anything on the list or in the git repo.

I ran into this failure when working on the v6.7-rc kernel as part of yocto project kernel updates.

Tweak as necessary, as I'm no expert in the right way to version these sort of changes.

Bruce

  include/instrumentation/events/mm_vmscan.h | 10 +++++++++-
  1 file changed, 9 insertions(+), 1 deletion(-)
include/instrumentation/events/mm_vmscan.h +7 -1
index e7e9b613..a3e9ddf2 100644
@@ -343,12 +343,18 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate,
  		unsigned long nr_scanned,
  		unsigned long nr_skipped,
  		unsigned long nr_taken,
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
  		isolate_mode_t isolate_mode,
+#endif
  		int lru
  	),
 
  	TP_ARGS(classzone_idx, order, nr_requested, nr_scanned, nr_skipped,
-		nr_taken, isolate_mode, lru
+		nr_taken,
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
+		isolate_mode,
+#endif
+		lru
  	),
 
  	TP_FIELDS(

include/instrumentation/events/mm_vmscan.h LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate, · line 372

Quoted 9 lines
include/instrumentation/events/mm_vmscan.h +2 -0
@@ -358,7 +364,9 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate,
  		ctf_integer(unsigned long, nr_scanned, nr_scanned)
  		ctf_integer(unsigned long, nr_skipped, nr_skipped)
  		ctf_integer(unsigned long, nr_taken, nr_taken)
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
  		ctf_integer(isolate_mode_t, isolate_mode, isolate_mode)
+#endif
  		ctf_integer(int, lru, lru)
  	)
  )

_______________________________________________
lttng-dev mailing list
[email protected]
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

#4 lore raw

Re: [lttng-dev] [PATCH 3/3] vmscan: drop isolate_mode (v6.7+)

Aha,

So the mailing list isn't used for patch submission anymore ? I didn't notice any updates in the READMEs, etc, so I just fell back to my existing workflow.

I just want to know, so I won't waste time in the future.

Bruce

Quoted 71 lines · Kienan Stewart

Hi Bruce,

thanks for the patches! There's a similar series waiting for review:
https://review.lttng.org/q/topic:%22fix-linux-6.7.0-rc1%22

thanks,
kienan

Quoted 61 lines · Bruce Ashfield via lttng-dev

From: Bruce Ashfield <[email protected]>

commit 3dfbb555c98ac55b9 [mm, vmscan: remove ISOLATE_UNMAPPED] makes the isolate_mode parameter unused, so it is removed.

This updates the event to match.

---

Repeating the comment from patch 1 & 2 of this series:

Someone else may or may not already have this in flight, but I didn't see anything on the list or in the git repo.

I ran into this failure when working on the v6.7-rc kernel as part of yocto project kernel updates.

Tweak as necessary, as I'm no expert in the right way to version these sort of changes.

Bruce

  include/instrumentation/events/mm_vmscan.h | 10 +++++++++-
  1 file changed, 9 insertions(+), 1 deletion(-)
include/instrumentation/events/mm_vmscan.h +9 -1
index e7e9b613..a3e9ddf2 100644
@@ -343,12 +343,18 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate,
              unsigned long nr_scanned,
              unsigned long nr_skipped,
              unsigned long nr_taken,
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
              isolate_mode_t isolate_mode,
+#endif
              int lru
      ),
 
      TP_ARGS(classzone_idx, order, nr_requested, nr_scanned, nr_skipped,
-             nr_taken, isolate_mode, lru
+             nr_taken,
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
+             isolate_mode,
+#endif
+             lru
      ),
 
      TP_FIELDS(
@@ -358,7 +364,9 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate,
              ctf_integer(unsigned long, nr_scanned, nr_scanned)
              ctf_integer(unsigned long, nr_skipped, nr_skipped)
              ctf_integer(unsigned long, nr_taken, nr_taken)
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
              ctf_integer(isolate_mode_t, isolate_mode, isolate_mode)
+#endif
              ctf_integer(int, lru, lru)
      )
  )
Signature · 7 lines
- Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end
- "Use the force Harry" - Gandalf, Star Trek II
_______________________________________________
lttng-dev mailing list
[email protected]
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
#5 lore raw

Re: [lttng-dev] [PATCH 3/3] vmscan: drop isolate_mode (v6.7+)

Hi Bruce,

Others may chime in here as I'm not sure I have the full context off-hand.

Quoted 3 lines · Bruce Ashfield

Aha,

So the mailing list isn't used for patch submission anymore ?

Patches submitted to the mailing list are reviewed. That being said, I think it's fair to say that the principal workflow has shifted away from the mailing list to https://review.lttng.org - many patches are reviewed there and not posted on the mailing list.

I think some patch series also get submitted to the mailing list in addition to https://review.lttng.org in order to solicit a wider feedback from the community.

Quoted 3 lines

I didn't
notice any updates in the READMEs, etc, so I just fell back to my existing workflow.

You are correct that the README for lttng-modules doesn't make any mention of this. Thanks for bringing this up, it should definitely be addressed!

I'll go through the READMEs and CONTRIBUTING.md files to make sure they indicate the current workflows.

thanks,
kienan

Quoted 66 lines

I just want to know, so I won't waste time in the future.

Bruce

Quoted 60 lines · Kienan Stewart

Hi Bruce,

thanks for the patches! There's a similar series waiting for review:
https://review.lttng.org/q/topic:%22fix-linux-6.7.0-rc1%22

thanks,
kienan

Quoted 50 lines · Bruce Ashfield via lttng-dev

From: Bruce Ashfield <[email protected]>

commit 3dfbb555c98ac55b9 [mm, vmscan: remove ISOLATE_UNMAPPED] makes the isolate_mode parameter unused, so it is removed.

This updates the event to match.

---

Repeating the comment from patch 1 & 2 of this series:

Someone else may or may not already have this in flight, but I didn't see anything on the list or in the git repo.

I ran into this failure when working on the v6.7-rc kernel as part of yocto project kernel updates.

Tweak as necessary, as I'm no expert in the right way to version these sort of changes.

Bruce

   include/instrumentation/events/mm_vmscan.h | 10 +++++++++-
   1 file changed, 9 insertions(+), 1 deletion(-)
include/instrumentation/events/mm_vmscan.h +7 -1
index e7e9b613..a3e9ddf2 100644
@@ -343,12 +343,18 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate,
               unsigned long nr_scanned,
               unsigned long nr_skipped,
               unsigned long nr_taken,
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
               isolate_mode_t isolate_mode,
+#endif
               int lru
       ),
 
       TP_ARGS(classzone_idx, order, nr_requested, nr_scanned, nr_skipped,
-             nr_taken, isolate_mode, lru
+             nr_taken,
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
+             isolate_mode,
+#endif
+             lru
       ),
 
Quoted 14 lines
Quoted 11 lines

include/instrumentation/events/mm_vmscan.h LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate, · line 372

Quoted 11 lines
include/instrumentation/events/mm_vmscan.h +2 -0
       TP_FIELDS(
@@ -358,7 +364,9 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate,
               ctf_integer(unsigned long, nr_scanned, nr_scanned)
               ctf_integer(unsigned long, nr_skipped, nr_skipped)
               ctf_integer(unsigned long, nr_taken, nr_taken)
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
               ctf_integer(isolate_mode_t, isolate_mode, isolate_mode)
+#endif
               ctf_integer(int, lru, lru)
       )
   )

_______________________________________________
lttng-dev mailing list
[email protected]
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

#6 lore raw

Re: [lttng-dev] [PATCH 3/3] vmscan: drop isolate_mode (v6.7+)

In reply to Bruce Ashfield via lttng-dev

Hi Bruce,

just a quick follow-up to say that the fixes for building against Linux 6.7 have been merged into the master and stable-2.13 branches of lttng-modules.

thanks,
kienan

Quoted 71 lines · Bruce Ashfield

Aha,

So the mailing list isn't used for patch submission anymore ? I didn't notice any updates in the READMEs, etc, so I just fell back to my existing workflow.

I just want to know, so I won't waste time in the future.

Bruce

Quoted 60 lines · Kienan Stewart

Hi Bruce,

thanks for the patches! There's a similar series waiting for review:
https://review.lttng.org/q/topic:%22fix-linux-6.7.0-rc1%22

thanks,
kienan

Quoted 50 lines · Bruce Ashfield via lttng-dev

From: Bruce Ashfield <[email protected]>

commit 3dfbb555c98ac55b9 [mm, vmscan: remove ISOLATE_UNMAPPED] makes the isolate_mode parameter unused, so it is removed.

This updates the event to match.

---

Repeating the comment from patch 1 & 2 of this series:

Someone else may or may not already have this in flight, but I didn't see anything on the list or in the git repo.

I ran into this failure when working on the v6.7-rc kernel as part of yocto project kernel updates.

Tweak as necessary, as I'm no expert in the right way to version these sort of changes.

Bruce

   include/instrumentation/events/mm_vmscan.h | 10 +++++++++-
   1 file changed, 9 insertions(+), 1 deletion(-)
include/instrumentation/events/mm_vmscan.h +7 -1
index e7e9b613..a3e9ddf2 100644
@@ -343,12 +343,18 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate,
               unsigned long nr_scanned,
               unsigned long nr_skipped,
               unsigned long nr_taken,
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
               isolate_mode_t isolate_mode,
+#endif
               int lru
       ),
 
       TP_ARGS(classzone_idx, order, nr_requested, nr_scanned, nr_skipped,
-             nr_taken, isolate_mode, lru
+             nr_taken,
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
+             isolate_mode,
+#endif
+             lru
       ),
 
Quoted 14 lines
Quoted 11 lines

include/instrumentation/events/mm_vmscan.h LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate, · line 372

Quoted 11 lines
include/instrumentation/events/mm_vmscan.h +2 -0
       TP_FIELDS(
@@ -358,7 +364,9 @@ LTTNG_TRACEPOINT_EVENT(mm_vmscan_lru_isolate,
               ctf_integer(unsigned long, nr_scanned, nr_scanned)
               ctf_integer(unsigned long, nr_skipped, nr_skipped)
               ctf_integer(unsigned long, nr_taken, nr_taken)
+#if (LTTNG_LINUX_VERSION_CODE < LTTNG_KERNEL_VERSION(6,7,0))
               ctf_integer(isolate_mode_t, isolate_mode, isolate_mode)
+#endif
               ctf_integer(int, lru, lru)
       )
   )

_______________________________________________
lttng-dev mailing list
[email protected]
https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev