Blame SOURCES/bcc-0.24.0-tools-mdflush-include-blkdev.h-instead-of-genhd.h.patch

ddf812
From 93a464e2ef05b7ef78b5679e366b89fcddf6a575 Mon Sep 17 00:00:00 2001
ddf812
From: Jerome Marchand <jmarchan@redhat.com>
ddf812
Date: Mon, 1 Aug 2022 11:45:41 +0200
ddf812
Subject: [PATCH] tools/mdflush: include blkdev.h instead of genhd.h
ddf812
ddf812
In recent kernels, i.e. since commit 322cbb50de71 ("block: remove
ddf812
genhd.h"), genhd.h header has been removed and its content moved to
ddf812
blkdev.h. Since genhd.h has been included in blkdev.h since forever,
ddf812
including blkdev instead of genhd in the mdflush tool works for both
ddf812
older and newer kernel.
ddf812
---
ddf812
 tools/mdflush.py | 2 +-
ddf812
 1 file changed, 1 insertion(+), 1 deletion(-)
ddf812
ddf812
diff --git a/tools/mdflush.py b/tools/mdflush.py
ddf812
index 3581d1bf..6741d563 100755
ddf812
--- a/tools/mdflush.py
ddf812
+++ b/tools/mdflush.py
ddf812
@@ -19,7 +19,7 @@ from time import strftime
ddf812
 b = BPF(text="""
ddf812
 #include <uapi/linux/ptrace.h>
ddf812
 #include <linux/sched.h>
ddf812
-#include <linux/genhd.h>
ddf812
+#include <linux/blkdev.h>
ddf812
 #include <linux/bio.h>
ddf812
 
ddf812
 struct data_t {
ddf812
-- 
ddf812
2.37.1
ddf812