mirror of
https://github.com/rd-stuffs/msm-4.14.git
synced 2025-02-20 11:45:48 +08:00
msm: cleanup: union gsi_channel_scratch
Remove __packed from the usage of union gsi_channel_scratch. __packed is only needed in the union definition. include/linux/msm_gsi.h: union __packed gsi_channel_scratch { ... } Bug: 139442076 Bug: 139808631 Bug: 142366585 Change-Id: If59d3d217e6a4bae92b9931523e2f89a39a04be9 Signed-off-by: Petri Gynther <pgynther@google.com> (cherry picked from commit 54ace836af62b9fc1edff9c3a436064e177fe2e4)
This commit is contained in:
parent
e9857bbb8e
commit
a80d5abf06
@ -2503,7 +2503,7 @@ static int gsi_alloc_ap_channel(unsigned int chan_hdl)
|
||||
}
|
||||
|
||||
static void __gsi_write_channel_scratch(unsigned long chan_hdl,
|
||||
union __packed gsi_channel_scratch val)
|
||||
union gsi_channel_scratch val)
|
||||
{
|
||||
gsi_writel(val.data.word1, gsi_ctx->base +
|
||||
GSI_EE_n_GSI_CH_k_SCRATCH_0_OFFS(chan_hdl,
|
||||
@ -2593,7 +2593,7 @@ int gsi_write_channel_scratch2_reg(unsigned long chan_hdl,
|
||||
EXPORT_SYMBOL(gsi_write_channel_scratch2_reg);
|
||||
|
||||
static void __gsi_read_channel_scratch(unsigned long chan_hdl,
|
||||
union __packed gsi_channel_scratch * val)
|
||||
union gsi_channel_scratch *val)
|
||||
{
|
||||
val->data.word1 = gsi_readl(gsi_ctx->base +
|
||||
GSI_EE_n_GSI_CH_k_SCRATCH_0_OFFS(chan_hdl,
|
||||
@ -2623,10 +2623,10 @@ static void __gsi_read_wdi3_channel_scratch2_reg(unsigned long chan_hdl,
|
||||
}
|
||||
|
||||
|
||||
static union __packed gsi_channel_scratch __gsi_update_mhi_channel_scratch(
|
||||
static union gsi_channel_scratch __gsi_update_mhi_channel_scratch(
|
||||
unsigned long chan_hdl, struct __packed gsi_mhi_channel_scratch mscr)
|
||||
{
|
||||
union __packed gsi_channel_scratch scr;
|
||||
union gsi_channel_scratch scr;
|
||||
|
||||
/* below sequence is not atomic. assumption is sequencer specific fields
|
||||
* will remain unchanged across this sequence
|
||||
@ -2678,7 +2678,7 @@ static union __packed gsi_channel_scratch __gsi_update_mhi_channel_scratch(
|
||||
}
|
||||
|
||||
int gsi_write_channel_scratch(unsigned long chan_hdl,
|
||||
union __packed gsi_channel_scratch val)
|
||||
union gsi_channel_scratch val)
|
||||
{
|
||||
struct gsi_chan_ctx *ctx;
|
||||
|
||||
@ -2746,7 +2746,7 @@ EXPORT_SYMBOL(gsi_write_wdi3_channel_scratch2_reg);
|
||||
|
||||
|
||||
int gsi_read_channel_scratch(unsigned long chan_hdl,
|
||||
union __packed gsi_channel_scratch *val)
|
||||
union gsi_channel_scratch *val)
|
||||
{
|
||||
struct gsi_chan_ctx *ctx;
|
||||
|
||||
|
@ -150,7 +150,7 @@ struct gsi_chan_ctx {
|
||||
struct completion compl;
|
||||
bool allocated;
|
||||
atomic_t poll_mode;
|
||||
union __packed gsi_channel_scratch scratch;
|
||||
union gsi_channel_scratch scratch;
|
||||
struct gsi_chan_stats stats;
|
||||
bool enable_dp_stats;
|
||||
bool print_dp_stats;
|
||||
|
@ -2627,7 +2627,7 @@ bool ipa_has_open_aggr_frame(enum ipa_client_type client)
|
||||
|
||||
int ipa_mhi_resume_channels_internal(enum ipa_client_type client,
|
||||
bool LPTransitionRejected, bool brstmode_enabled,
|
||||
union __packed gsi_channel_scratch ch_scratch, u8 index,
|
||||
union gsi_channel_scratch ch_scratch, u8 index,
|
||||
bool is_switch_to_dbmode)
|
||||
{
|
||||
int ret;
|
||||
|
@ -306,7 +306,7 @@ struct ipa_api_controller {
|
||||
enum ipa_client_type client,
|
||||
bool LPTransitionRejected,
|
||||
bool brstmode_enabled,
|
||||
union __packed gsi_channel_scratch ch_scratch,
|
||||
union gsi_channel_scratch ch_scratch,
|
||||
u8 index,
|
||||
bool is_switch_to_dbmode);
|
||||
|
||||
|
@ -137,7 +137,7 @@ struct ipa_mhi_channel_ctx {
|
||||
u64 event_context_addr;
|
||||
struct ipa_mhi_ev_ctx ev_ctx_host;
|
||||
bool brstmode_enabled;
|
||||
union __packed gsi_channel_scratch ch_scratch;
|
||||
union gsi_channel_scratch ch_scratch;
|
||||
unsigned long cached_gsi_evt_ring_hdl;
|
||||
};
|
||||
|
||||
|
@ -383,7 +383,7 @@ int ipa_mhi_start_channel_internal(enum ipa_client_type client);
|
||||
bool ipa_mhi_sps_channel_empty(enum ipa_client_type client);
|
||||
int ipa_mhi_resume_channels_internal(enum ipa_client_type client,
|
||||
bool LPTransitionRejected, bool brstmode_enabled,
|
||||
union __packed gsi_channel_scratch ch_scratch, u8 index,
|
||||
union gsi_channel_scratch ch_scratch, u8 index,
|
||||
bool is_switch_to_dbmode);
|
||||
int ipa_mhi_handle_ipa_config_req(struct ipa_config_req_msg_v01 *config_req);
|
||||
int ipa_mhi_query_ch_info(enum ipa_client_type client,
|
||||
|
@ -677,7 +677,7 @@ int ipa3_request_gsi_channel(struct ipa_request_gsi_channel_params *params,
|
||||
}
|
||||
|
||||
memcpy(&ep->chan_scratch, ¶ms->chan_scratch,
|
||||
sizeof(union __packed gsi_channel_scratch));
|
||||
sizeof(union gsi_channel_scratch));
|
||||
|
||||
/*
|
||||
* Update scratch for MCS smart prefetch:
|
||||
|
@ -4641,7 +4641,7 @@ static int ipa_gsi_setup_transfer_ring(struct ipa3_ep_context *ep,
|
||||
u32 ring_size, struct ipa3_sys_context *user_data, gfp_t mem_flag)
|
||||
{
|
||||
dma_addr_t dma_addr;
|
||||
union __packed gsi_channel_scratch ch_scratch;
|
||||
union gsi_channel_scratch ch_scratch;
|
||||
struct gsi_chan_props gsi_channel_props;
|
||||
const struct ipa_gsi_ep_config *gsi_ep_info;
|
||||
int result;
|
||||
|
@ -930,7 +930,7 @@ struct ipa3_ep_context {
|
||||
unsigned long gsi_chan_hdl;
|
||||
unsigned long gsi_evt_ring_hdl;
|
||||
struct ipa_gsi_ep_mem_info gsi_mem_info;
|
||||
union __packed gsi_channel_scratch chan_scratch;
|
||||
union gsi_channel_scratch chan_scratch;
|
||||
struct gsi_chan_xfer_notify xfer_notify;
|
||||
bool xfer_notify_valid;
|
||||
struct ipa_ep_cfg cfg;
|
||||
@ -987,7 +987,7 @@ struct ipa_request_gsi_channel_params {
|
||||
struct gsi_evt_ring_props evt_ring_params;
|
||||
union __packed gsi_evt_scratch evt_scratch;
|
||||
struct gsi_chan_props chan_params;
|
||||
union __packed gsi_channel_scratch chan_scratch;
|
||||
union gsi_channel_scratch chan_scratch;
|
||||
};
|
||||
|
||||
enum ipa3_sys_pipe_policy {
|
||||
@ -2770,7 +2770,7 @@ bool ipa3_has_open_aggr_frame(enum ipa_client_type client);
|
||||
|
||||
int ipa3_mhi_resume_channels_internal(enum ipa_client_type client,
|
||||
bool LPTransitionRejected, bool brstmode_enabled,
|
||||
union __packed gsi_channel_scratch ch_scratch, u8 index,
|
||||
union gsi_channel_scratch ch_scratch, u8 index,
|
||||
bool is_switch_to_dbmode);
|
||||
|
||||
int ipa3_mhi_destroy_channel(enum ipa_client_type client);
|
||||
|
@ -195,8 +195,8 @@ static int ipa_mhi_start_gsi_channel(enum ipa_client_type client,
|
||||
struct gsi_evt_ring_props ev_props;
|
||||
struct ipa_mhi_msi_info *msi;
|
||||
struct gsi_chan_props ch_props;
|
||||
union __packed gsi_channel_scratch ch_scratch;
|
||||
union __packed gsi_channel_scratch ch_scratch1;
|
||||
union gsi_channel_scratch ch_scratch;
|
||||
union gsi_channel_scratch ch_scratch1;
|
||||
struct ipa3_ep_context *ep;
|
||||
const struct ipa_gsi_ep_config *ep_cfg;
|
||||
struct ipa_ep_cfg_ctrl ep_cfg_ctrl;
|
||||
@ -647,13 +647,13 @@ fail_reset_channel:
|
||||
|
||||
int ipa3_mhi_resume_channels_internal(enum ipa_client_type client,
|
||||
bool LPTransitionRejected, bool brstmode_enabled,
|
||||
union __packed gsi_channel_scratch ch_scratch, u8 index,
|
||||
union gsi_channel_scratch ch_scratch, u8 index,
|
||||
bool is_switch_to_dbmode)
|
||||
{
|
||||
int res;
|
||||
int ipa_ep_idx;
|
||||
struct ipa3_ep_context *ep;
|
||||
union __packed gsi_channel_scratch gsi_ch_scratch;
|
||||
union gsi_channel_scratch gsi_ch_scratch;
|
||||
|
||||
IPA_MHI_FUNC_ENTRY();
|
||||
|
||||
|
@ -1190,7 +1190,7 @@ int ipa3_connect_gsi_wdi_pipe(struct ipa_wdi_in_params *in,
|
||||
struct ipa_ep_cfg_ctrl ep_cfg_ctrl;
|
||||
struct gsi_chan_props gsi_channel_props;
|
||||
struct gsi_evt_ring_props gsi_evt_ring_props;
|
||||
union __packed gsi_channel_scratch gsi_scratch;
|
||||
union gsi_channel_scratch gsi_scratch;
|
||||
phys_addr_t pa;
|
||||
unsigned long va;
|
||||
unsigned long wifi_rx_ri_addr = 0;
|
||||
@ -2653,7 +2653,7 @@ int ipa3_resume_gsi_wdi_pipe(u32 clnt_hdl)
|
||||
struct ipa3_ep_context *ep;
|
||||
struct ipa_ep_cfg_ctrl ep_cfg_ctrl;
|
||||
struct gsi_chan_info chan_info;
|
||||
union __packed gsi_channel_scratch gsi_scratch;
|
||||
union gsi_channel_scratch gsi_scratch;
|
||||
struct IpaHwOffloadStatsAllocCmdData_t *pcmd_t = NULL;
|
||||
|
||||
IPADBG("ep=%d\n", clnt_hdl);
|
||||
@ -2790,7 +2790,7 @@ int ipa3_suspend_gsi_wdi_pipe(u32 clnt_hdl)
|
||||
struct ipahal_ep_cfg_ctrl_scnd ep_ctrl_scnd = { 0 };
|
||||
int retry_cnt = 0;
|
||||
struct gsi_chan_info chan_info;
|
||||
union __packed gsi_channel_scratch gsi_scratch;
|
||||
union gsi_channel_scratch gsi_scratch;
|
||||
struct IpaHwOffloadStatsAllocCmdData_t *pcmd_t = NULL;
|
||||
|
||||
ipa_ep_idx = ipa3_get_ep_mapping(ipa3_get_client_mapping(clnt_hdl));
|
||||
|
@ -75,7 +75,7 @@ static int ipa3_setup_wdi3_gsi_channel(u8 is_smmu_enabled,
|
||||
{
|
||||
struct gsi_evt_ring_props gsi_evt_ring_props;
|
||||
struct gsi_chan_props gsi_channel_props;
|
||||
union __packed gsi_channel_scratch ch_scratch;
|
||||
union gsi_channel_scratch ch_scratch;
|
||||
union __packed gsi_evt_scratch evt_scratch;
|
||||
const struct ipa_gsi_ep_config *gsi_ep_info;
|
||||
int result, len;
|
||||
@ -901,7 +901,7 @@ int ipa3_write_qmapid_wdi3_gsi_pipe(u32 clnt_hdl, u8 qmap_id)
|
||||
{
|
||||
int result = 0;
|
||||
struct ipa3_ep_context *ep;
|
||||
union __packed gsi_wdi3_channel_scratch2_reg scratch2_reg;
|
||||
union gsi_wdi3_channel_scratch2_reg scratch2_reg;
|
||||
|
||||
memset(&scratch2_reg, 0, sizeof(scratch2_reg));
|
||||
if (clnt_hdl >= ipa3_ctx->ipa_num_pipes ||
|
||||
|
@ -394,7 +394,7 @@ static int ipa3_wigig_config_gsi(bool Rx,
|
||||
{
|
||||
struct gsi_evt_ring_props evt_props;
|
||||
struct gsi_chan_props channel_props;
|
||||
union __packed gsi_channel_scratch gsi_scratch;
|
||||
union gsi_channel_scratch gsi_scratch;
|
||||
int gsi_res;
|
||||
struct ipa_wigig_pipe_setup_info_smmu *pipe_smmu;
|
||||
struct ipa_wigig_pipe_setup_info *pipe;
|
||||
|
@ -1403,7 +1403,7 @@ int gsi_alloc_channel(struct gsi_chan_props *props, unsigned long dev_hdl,
|
||||
* @Return gsi_status
|
||||
*/
|
||||
int gsi_write_channel_scratch(unsigned long chan_hdl,
|
||||
union __packed gsi_channel_scratch val);
|
||||
union gsi_channel_scratch val);
|
||||
|
||||
/**
|
||||
* gsi_write_channel_scratch3_reg - Peripheral should call this function to
|
||||
@ -1454,7 +1454,7 @@ int gsi_write_channel_scratch2_reg(unsigned long chan_hdl,
|
||||
* @Return gsi_status
|
||||
*/
|
||||
int gsi_read_channel_scratch(unsigned long chan_hdl,
|
||||
union __packed gsi_channel_scratch *val);
|
||||
union gsi_channel_scratch *val);
|
||||
|
||||
/**
|
||||
* gsi_read_wdi3_channel_scratch2_reg - Peripheral should call this function to
|
||||
@ -1928,7 +1928,7 @@ static inline int gsi_alloc_channel(struct gsi_chan_props *props,
|
||||
}
|
||||
|
||||
static inline int gsi_write_channel_scratch(unsigned long chan_hdl,
|
||||
union __packed gsi_channel_scratch val)
|
||||
union gsi_channel_scratch val)
|
||||
{
|
||||
return -GSI_STATUS_UNSUPPORTED_OP;
|
||||
}
|
||||
@ -1945,7 +1945,7 @@ static inline int gsi_write_channel_scratch2_reg(unsigned long chan_hdl,
|
||||
}
|
||||
|
||||
static inline int gsi_read_channel_scratch(unsigned long chan_hdl,
|
||||
union __packed gsi_channel_scratch *val)
|
||||
union gsi_channel_scratch *val)
|
||||
{
|
||||
return -GSI_STATUS_UNSUPPORTED_OP;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user