summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2020-02-12 10:36:57 +0100
committerThomas Haller <thaller@redhat.com>2020-02-14 09:48:37 +0100
commit098c0d50927830c9d02b4abc8a63da31276fb46f (patch)
tree677f72ea5ce5bc8c359360d4930d3fd39254d911
parent984e94f01d8e2febba79b0624cdb2576fe329cd7 (diff)
device: inline "struct Supplicant" to where it is used
-rw-r--r--src/devices/nm-device-ethernet.c25
-rw-r--r--src/devices/nm-device-macsec.c24
2 files changed, 24 insertions, 25 deletions
diff --git a/src/devices/nm-device-ethernet.c b/src/devices/nm-device-ethernet.c
index a87b772e8..f6dc70d4e 100644
--- a/src/devices/nm-device-ethernet.c
+++ b/src/devices/nm-device-ethernet.c
@@ -45,18 +45,6 @@ _LOG_DECLARE_SELF(NMDeviceEthernet);
/*****************************************************************************/
-typedef struct Supplicant {
- NMSupplicantManager *mgr;
- NMSupplicantInterface *iface;
-
- /* signal handler ids */
- gulong iface_state_id;
- gulong auth_state_id;
-
- /* Timeouts and idles */
- guint con_timeout_id;
-} Supplicant;
-
typedef enum {
DCB_WAIT_UNKNOWN = 0,
/* Ensure carrier is up before enabling DCB */
@@ -75,7 +63,18 @@ typedef struct _NMDeviceEthernetPrivate {
guint32 speed;
gulong carrier_id;
- Supplicant supplicant;
+ struct {
+ NMSupplicantManager *mgr;
+ NMSupplicantInterface *iface;
+
+ /* signal handler ids */
+ gulong iface_state_id;
+ gulong auth_state_id;
+
+ /* Timeouts and idles */
+ guint con_timeout_id;
+ } supplicant;
+
guint supplicant_timeout_id;
/* s390 */
diff --git a/src/devices/nm-device-macsec.c b/src/devices/nm-device-macsec.c
index dbb4ac8ef..b7c9e7728 100644
--- a/src/devices/nm-device-macsec.c
+++ b/src/devices/nm-device-macsec.c
@@ -23,17 +23,6 @@ _LOG_DECLARE_SELF(NMDeviceMacsec);
/*****************************************************************************/
-typedef struct Supplicant {
- NMSupplicantManager *mgr;
- NMSupplicantInterface *iface;
-
- /* signal handler ids */
- gulong iface_state_id;
-
- /* Timeouts and idles */
- guint con_timeout_id;
-} Supplicant;
-
NM_GOBJECT_PROPERTIES_DEFINE (NMDeviceMacsec,
PROP_SCI,
PROP_CIPHER_SUITE,
@@ -53,7 +42,18 @@ typedef struct {
NMPlatformLnkMacsec props;
gulong parent_state_id;
gulong parent_mtu_id;
- Supplicant supplicant;
+
+ struct {
+ NMSupplicantManager *mgr;
+ NMSupplicantInterface *iface;
+
+ /* signal handler ids */
+ gulong iface_state_id;
+
+ /* Timeouts and idles */
+ guint con_timeout_id;
+ } supplicant;
+
guint supplicant_timeout_id;
NMActRequestGetSecretsCallId *macsec_secrets_id;
} NMDeviceMacsecPrivate;