transport: fix init_pollfd function parameter

The init_pollfd function parameter was declared as
pldm_transport_af_mctp, but it seems like it is intended to use
pldm_transport instead. The headers were not included in c files, so it
didn't cause conflicting types at compile time.

Change-Id: I54f1397efee0ae5e68a24f1473e0395f02d53eaf
Fixes: c1b66f4 ("requester: Add new APIs to support multiple transports")
Fixes: ba6971b ("requester: Add af_mctp transport")
Signed-off-by: Delphine CC Chiu <Delphine_CC_Chiu@wiwynn.com>
diff --git a/CHANGELOG.md b/CHANGELOG.md
index a3ffdfd..55155f4 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -32,6 +32,7 @@
 ### Fixed
 
 1. transport: register init_pollfd callback for af-mctp
+2. transport: fix init_pollfd function parameter
 
 ## [0.5.0] - 2023-08-09
 
diff --git a/include/libpldm/transport/af-mctp.h b/include/libpldm/transport/af-mctp.h
index 3908929..f0fa2b7 100644
--- a/include/libpldm/transport/af-mctp.h
+++ b/include/libpldm/transport/af-mctp.h
@@ -24,7 +24,7 @@
 #ifdef PLDM_HAS_POLL
 struct pollfd;
 /* Init pollfd for async calls */
-int pldm_transport_af_mctp_init_pollfd(struct pldm_transport_af_mctp *ctx,
+int pldm_transport_af_mctp_init_pollfd(struct pldm_transport *t,
 				       struct pollfd *pollfd);
 #endif
 
diff --git a/include/libpldm/transport/mctp-demux.h b/include/libpldm/transport/mctp-demux.h
index 78001a3..e912349 100644
--- a/include/libpldm/transport/mctp-demux.h
+++ b/include/libpldm/transport/mctp-demux.h
@@ -24,7 +24,7 @@
 #ifdef PLDM_HAS_POLL
 struct pollfd;
 /* Init pollfd for async calls */
-int pldm_transport_mctp_demux_init_pollfd(struct pldm_transport_mctp_demux *ctx,
+int pldm_transport_mctp_demux_init_pollfd(struct pldm_transport *t,
 					  struct pollfd *pollfd);
 #endif
 
diff --git a/src/transport/af-mctp.c b/src/transport/af-mctp.c
index ae00fe4..ab2cc1c 100644
--- a/src/transport/af-mctp.c
+++ b/src/transport/af-mctp.c
@@ -3,6 +3,7 @@
 #include "container-of.h"
 #include "libpldm/pldm.h"
 #include "libpldm/transport.h"
+#include "libpldm/transport/af-mctp.h"
 #include "socket.h"
 #include "transport.h"
 
diff --git a/src/transport/mctp-demux.c b/src/transport/mctp-demux.c
index 427c52a..25b1eb3 100644
--- a/src/transport/mctp-demux.c
+++ b/src/transport/mctp-demux.c
@@ -3,6 +3,7 @@
 #include "container-of.h"
 #include "libpldm/pldm.h"
 #include "libpldm/transport.h"
+#include "libpldm/transport/mctp-demux.h"
 #include "socket.h"
 #include "transport.h"