Commit 34bacf73 authored by Luciano Coelho's avatar Luciano Coelho

wlcore/wl18xx: the conf structs must be packed so they can be exported

Since we are now going to export the conf structure and read it from a
file, it should be packed to avoid surprises with padding bytes.
Signed-off-by: default avatarLuciano Coelho <coelho@ti.com>
parent b551a3c9
...@@ -48,10 +48,10 @@ struct wl18xx_conf_phy { ...@@ -48,10 +48,10 @@ struct wl18xx_conf_phy {
s8 low_power_val; s8 low_power_val;
s8 med_power_val; s8 med_power_val;
s8 high_power_val; s8 high_power_val;
}; } __packed;
struct wl18xx_priv_conf { struct wl18xx_priv_conf {
struct wl18xx_conf_phy phy; struct wl18xx_conf_phy phy;
}; } __packed;
#endif /* __WL18XX_CONF_H__ */ #endif /* __WL18XX_CONF_H__ */
...@@ -318,7 +318,7 @@ enum { ...@@ -318,7 +318,7 @@ enum {
struct conf_sg_settings { struct conf_sg_settings {
u32 params[CONF_SG_PARAMS_MAX]; u32 params[CONF_SG_PARAMS_MAX];
u8 state; u8 state;
}; } __packed;
enum conf_rx_queue_type { enum conf_rx_queue_type {
CONF_RX_QUEUE_TYPE_LOW_PRIORITY, /* All except the high priority */ CONF_RX_QUEUE_TYPE_LOW_PRIORITY, /* All except the high priority */
...@@ -402,7 +402,7 @@ struct conf_rx_settings { ...@@ -402,7 +402,7 @@ struct conf_rx_settings {
* Range: RX_QUEUE_TYPE_RX_LOW_PRIORITY, RX_QUEUE_TYPE_RX_HIGH_PRIORITY, * Range: RX_QUEUE_TYPE_RX_LOW_PRIORITY, RX_QUEUE_TYPE_RX_HIGH_PRIORITY,
*/ */
u8 queue_type; u8 queue_type;
}; } __packed;
#define CONF_TX_MAX_RATE_CLASSES 10 #define CONF_TX_MAX_RATE_CLASSES 10
...@@ -501,7 +501,7 @@ struct conf_tx_rate_class { ...@@ -501,7 +501,7 @@ struct conf_tx_rate_class {
* the policy (0 - long preamble, 1 - short preamble. * the policy (0 - long preamble, 1 - short preamble.
*/ */
u8 aflags; u8 aflags;
}; } __packed;
#define CONF_TX_MAX_AC_COUNT 4 #define CONF_TX_MAX_AC_COUNT 4
...@@ -558,7 +558,7 @@ struct conf_tx_ac_category { ...@@ -558,7 +558,7 @@ struct conf_tx_ac_category {
* Range: u16 * Range: u16
*/ */
u16 tx_op_limit; u16 tx_op_limit;
}; } __packed;
#define CONF_TX_MAX_TID_COUNT 8 #define CONF_TX_MAX_TID_COUNT 8
...@@ -592,7 +592,7 @@ struct conf_tx_tid { ...@@ -592,7 +592,7 @@ struct conf_tx_tid {
u8 ps_scheme; u8 ps_scheme;
u8 ack_policy; u8 ack_policy;
u32 apsd_conf[2]; u32 apsd_conf[2];
}; } __packed;
struct conf_tx_settings { struct conf_tx_settings {
/* /*
...@@ -678,7 +678,7 @@ struct conf_tx_settings { ...@@ -678,7 +678,7 @@ struct conf_tx_settings {
/* Time in ms for Tx watchdog timer to expire */ /* Time in ms for Tx watchdog timer to expire */
u32 tx_watchdog_timeout; u32 tx_watchdog_timeout;
}; } __packed;
enum { enum {
CONF_WAKE_UP_EVENT_BEACON = 0x01, /* Wake on every Beacon*/ CONF_WAKE_UP_EVENT_BEACON = 0x01, /* Wake on every Beacon*/
...@@ -725,7 +725,7 @@ struct conf_bcn_filt_rule { ...@@ -725,7 +725,7 @@ struct conf_bcn_filt_rule {
* Version for the vendor specifie IE (221) * Version for the vendor specifie IE (221)
*/ */
u8 version[CONF_BCN_IE_VER_LEN]; u8 version[CONF_BCN_IE_VER_LEN];
}; } __packed;
#define CONF_MAX_RSSI_SNR_TRIGGERS 8 #define CONF_MAX_RSSI_SNR_TRIGGERS 8
...@@ -776,7 +776,7 @@ struct conf_sig_weights { ...@@ -776,7 +776,7 @@ struct conf_sig_weights {
* Range: u8 * Range: u8
*/ */
u8 snr_pkt_avg_weight; u8 snr_pkt_avg_weight;
}; } __packed;
enum conf_bcn_filt_mode { enum conf_bcn_filt_mode {
CONF_BCN_FILT_MODE_DISABLED = 0, CONF_BCN_FILT_MODE_DISABLED = 0,
...@@ -951,7 +951,7 @@ struct conf_conn_settings { ...@@ -951,7 +951,7 @@ struct conf_conn_settings {
* Range: u16 * Range: u16
*/ */
u8 max_listen_interval; u8 max_listen_interval;
}; } __packed;
enum { enum {
CONF_REF_CLK_19_2_E, CONF_REF_CLK_19_2_E,
...@@ -979,7 +979,7 @@ struct conf_itrim_settings { ...@@ -979,7 +979,7 @@ struct conf_itrim_settings {
/* moderation timeout in microsecs from the last TX */ /* moderation timeout in microsecs from the last TX */
u32 timeout; u32 timeout;
}; } __packed;
enum conf_fast_wakeup { enum conf_fast_wakeup {
CONF_FAST_WAKEUP_ENABLE, CONF_FAST_WAKEUP_ENABLE,
...@@ -1000,7 +1000,7 @@ struct conf_pm_config_settings { ...@@ -1000,7 +1000,7 @@ struct conf_pm_config_settings {
* Range: enum conf_fast_wakeup * Range: enum conf_fast_wakeup
*/ */
u8 host_fast_wakeup_support; u8 host_fast_wakeup_support;
}; } __packed;
struct conf_roam_trigger_settings { struct conf_roam_trigger_settings {
/* /*
...@@ -1037,7 +1037,7 @@ struct conf_roam_trigger_settings { ...@@ -1037,7 +1037,7 @@ struct conf_roam_trigger_settings {
* Range: 0 - 255 * Range: 0 - 255
*/ */
u8 avg_weight_snr_data; u8 avg_weight_snr_data;
}; } __packed;
struct conf_scan_settings { struct conf_scan_settings {
/* /*
...@@ -1083,7 +1083,7 @@ struct conf_scan_settings { ...@@ -1083,7 +1083,7 @@ struct conf_scan_settings {
* Range: u32 Microsecs * Range: u32 Microsecs
*/ */
u32 split_scan_timeout; u32 split_scan_timeout;
}; } __packed;
struct conf_sched_scan_settings { struct conf_sched_scan_settings {
/* /*
...@@ -1121,7 +1121,7 @@ struct conf_sched_scan_settings { ...@@ -1121,7 +1121,7 @@ struct conf_sched_scan_settings {
/* SNR threshold to be used for filtering */ /* SNR threshold to be used for filtering */
s8 snr_threshold; s8 snr_threshold;
}; } __packed;
struct conf_ht_setting { struct conf_ht_setting {
u8 rx_ba_win_size; u8 rx_ba_win_size;
...@@ -1130,7 +1130,7 @@ struct conf_ht_setting { ...@@ -1130,7 +1130,7 @@ struct conf_ht_setting {
/* bitmap of enabled TIDs for TX BA sessions */ /* bitmap of enabled TIDs for TX BA sessions */
u8 tx_ba_tid_bitmap; u8 tx_ba_tid_bitmap;
}; } __packed;
struct conf_memory_settings { struct conf_memory_settings {
/* Number of stations supported in IBSS mode */ /* Number of stations supported in IBSS mode */
...@@ -1170,7 +1170,7 @@ struct conf_memory_settings { ...@@ -1170,7 +1170,7 @@ struct conf_memory_settings {
* Range: 0-120 * Range: 0-120
*/ */
u8 tx_min; u8 tx_min;
}; } __packed;
struct conf_fm_coex { struct conf_fm_coex {
u8 enable; u8 enable;
...@@ -1183,7 +1183,7 @@ struct conf_fm_coex { ...@@ -1183,7 +1183,7 @@ struct conf_fm_coex {
u16 ldo_stabilization_time; u16 ldo_stabilization_time;
u8 fm_disturbed_band_margin; u8 fm_disturbed_band_margin;
u8 swallow_clk_diff; u8 swallow_clk_diff;
}; } __packed;
struct conf_rx_streaming_settings { struct conf_rx_streaming_settings {
/* /*
...@@ -1212,7 +1212,7 @@ struct conf_rx_streaming_settings { ...@@ -1212,7 +1212,7 @@ struct conf_rx_streaming_settings {
* enable rx streaming also when there is no coex activity * enable rx streaming also when there is no coex activity
*/ */
u8 always; u8 always;
}; } __packed;
struct conf_fwlog { struct conf_fwlog {
/* Continuous or on-demand */ /* Continuous or on-demand */
...@@ -1236,7 +1236,7 @@ struct conf_fwlog { ...@@ -1236,7 +1236,7 @@ struct conf_fwlog {
/* Regulates the frequency of log messages */ /* Regulates the frequency of log messages */
u8 threshold; u8 threshold;
}; } __packed;
#define ACX_RATE_MGMT_NUM_OF_RATES 13 #define ACX_RATE_MGMT_NUM_OF_RATES 13
struct conf_rate_policy_settings { struct conf_rate_policy_settings {
...@@ -1255,7 +1255,7 @@ struct conf_rate_policy_settings { ...@@ -1255,7 +1255,7 @@ struct conf_rate_policy_settings {
u8 rate_check_up; u8 rate_check_up;
u8 rate_check_down; u8 rate_check_down;
u8 rate_retry_policy[ACX_RATE_MGMT_NUM_OF_RATES]; u8 rate_retry_policy[ACX_RATE_MGMT_NUM_OF_RATES];
}; } __packed;
struct conf_hangover_settings { struct conf_hangover_settings {
u32 recover_time; u32 recover_time;
...@@ -1269,7 +1269,7 @@ struct conf_hangover_settings { ...@@ -1269,7 +1269,7 @@ struct conf_hangover_settings {
u8 quiet_time; u8 quiet_time;
u8 increase_time; u8 increase_time;
u8 window_size; u8 window_size;
}; } __packed;
struct wlcore_conf { struct wlcore_conf {
struct conf_sg_settings sg; struct conf_sg_settings sg;
...@@ -1288,6 +1288,6 @@ struct wlcore_conf { ...@@ -1288,6 +1288,6 @@ struct wlcore_conf {
struct conf_fwlog fwlog; struct conf_fwlog fwlog;
struct conf_rate_policy_settings rate; struct conf_rate_policy_settings rate;
struct conf_hangover_settings hangover; struct conf_hangover_settings hangover;
}; } __packed;
#endif #endif
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment