lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250424132118.17074-2-shubhrajyoti.datta@amd.com>
Date: Thu, 24 Apr 2025 18:51:13 +0530
From: Shubhrajyoti Datta <shubhrajyoti.datta@....com>
To: <devicetree@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
	<linux-edac@...r.kernel.org>
CC: <git@....com>, <ptsm@...ux.microsoft.com>, <srivatsa@...il.mit.edu>,
	<shubhrajyoti.datta@...il.com>, Krzysztof Kozlowski <krzk@...nel.org>, "Rob
 Herring" <robh@...nel.org>, Conor Dooley <conor+dt@...nel.org>, "Borislav
 Petkov" <bp@...en8.de>, Tony Luck <tony.luck@...el.com>, James Morse
	<james.morse@....com>, Mauro Carvalho Chehab <mchehab@...nel.org>, "Robert
 Richter" <rric@...nel.org>, Shubhrajyoti Datta <shubhrajyoti.datta@....com>
Subject: [PATCH v6 1/6] cdx: add the cdx headers to include/linux

Move the header files from driver/cdx to the include/linux.
Adding the protocol, mcdi and bitfield header file to
include/linux. This is in preparation for VersalNET EDAC
driver that relies on it.

Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@....com>
---

Changes in v6:
 - Patch added
This patch is compile tested.

 drivers/cdx/controller/cdx_controller.c                       | 1 -
 drivers/cdx/controller/cdx_rpmsg.c                            | 1 -
 drivers/cdx/controller/mcdi.c                                 | 4 +---
 drivers/cdx/controller/mcdi_functions.c                       | 1 -
 drivers/cdx/controller/mcdi_functions.h                       | 2 +-
 .../cdx/controller/bitfield.h => include/linux/mc_bitfield.h  | 0
 {drivers/cdx/controller => include/linux}/mc_cdx_pcol.h       | 0
 {drivers/cdx/controller => include/linux}/mcdi.h              | 4 ++--
 8 files changed, 4 insertions(+), 9 deletions(-)
 rename drivers/cdx/controller/bitfield.h => include/linux/mc_bitfield.h (100%)
 rename {drivers/cdx/controller => include/linux}/mc_cdx_pcol.h (100%)
 rename {drivers/cdx/controller => include/linux}/mcdi.h (99%)

diff --git a/drivers/cdx/controller/cdx_controller.c b/drivers/cdx/controller/cdx_controller.c
index d623f9c7517a..4676adcef010 100644
--- a/drivers/cdx/controller/cdx_controller.c
+++ b/drivers/cdx/controller/cdx_controller.c
@@ -14,7 +14,6 @@
 #include "cdx_controller.h"
 #include "../cdx.h"
 #include "mcdi_functions.h"
-#include "mcdi.h"
 
 static unsigned int cdx_mcdi_rpc_timeout(struct cdx_mcdi *cdx, unsigned int cmd)
 {
diff --git a/drivers/cdx/controller/cdx_rpmsg.c b/drivers/cdx/controller/cdx_rpmsg.c
index 04b578a0be17..ad4a4602b367 100644
--- a/drivers/cdx/controller/cdx_rpmsg.c
+++ b/drivers/cdx/controller/cdx_rpmsg.c
@@ -15,7 +15,6 @@
 #include "../cdx.h"
 #include "cdx_controller.h"
 #include "mcdi_functions.h"
-#include "mcdi.h"
 
 static struct rpmsg_device_id cdx_rpmsg_id_table[] = {
 	{ .name = "mcdi_ipc" },
diff --git a/drivers/cdx/controller/mcdi.c b/drivers/cdx/controller/mcdi.c
index e760f8d347cc..600084e81a86 100644
--- a/drivers/cdx/controller/mcdi.c
+++ b/drivers/cdx/controller/mcdi.c
@@ -23,9 +23,7 @@
 #include <linux/log2.h>
 #include <linux/net_tstamp.h>
 #include <linux/wait.h>
-
-#include "bitfield.h"
-#include "mcdi.h"
+#include "linux/mcdi.h"
 
 static void cdx_mcdi_cancel_cmd(struct cdx_mcdi *cdx, struct cdx_mcdi_cmd *cmd);
 static void cdx_mcdi_wait_for_cleanup(struct cdx_mcdi *cdx);
diff --git a/drivers/cdx/controller/mcdi_functions.c b/drivers/cdx/controller/mcdi_functions.c
index 885c69e6ebe5..8ae2d99be81e 100644
--- a/drivers/cdx/controller/mcdi_functions.c
+++ b/drivers/cdx/controller/mcdi_functions.c
@@ -5,7 +5,6 @@
 
 #include <linux/module.h>
 
-#include "mcdi.h"
 #include "mcdi_functions.h"
 
 int cdx_mcdi_get_num_buses(struct cdx_mcdi *cdx)
diff --git a/drivers/cdx/controller/mcdi_functions.h b/drivers/cdx/controller/mcdi_functions.h
index b9942affdc6b..1b503f42dc40 100644
--- a/drivers/cdx/controller/mcdi_functions.h
+++ b/drivers/cdx/controller/mcdi_functions.h
@@ -8,7 +8,7 @@
 #ifndef CDX_MCDI_FUNCTIONS_H
 #define CDX_MCDI_FUNCTIONS_H
 
-#include "mcdi.h"
+#include "linux/mcdi.h"
 #include "../cdx.h"
 
 /**
diff --git a/drivers/cdx/controller/bitfield.h b/include/linux/mc_bitfield.h
similarity index 100%
rename from drivers/cdx/controller/bitfield.h
rename to include/linux/mc_bitfield.h
diff --git a/drivers/cdx/controller/mc_cdx_pcol.h b/include/linux/mc_cdx_pcol.h
similarity index 100%
rename from drivers/cdx/controller/mc_cdx_pcol.h
rename to include/linux/mc_cdx_pcol.h
diff --git a/drivers/cdx/controller/mcdi.h b/include/linux/mcdi.h
similarity index 99%
rename from drivers/cdx/controller/mcdi.h
rename to include/linux/mcdi.h
index 54a65e9760ae..abe691a501dd 100644
--- a/drivers/cdx/controller/mcdi.h
+++ b/include/linux/mcdi.h
@@ -11,8 +11,8 @@
 #include <linux/kref.h>
 #include <linux/rpmsg.h>
 
-#include "bitfield.h"
-#include "mc_cdx_pcol.h"
+#include "linux/mc_bitfield.h"
+#include "linux/mc_cdx_pcol.h"
 
 #ifdef DEBUG
 #define CDX_WARN_ON_ONCE_PARANOID(x) WARN_ON_ONCE(x)
-- 
2.17.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ