* [PATCH] mlx5: remove usused static inlines
@ 2022-01-26 18:57 Jakub Kicinski
2022-01-26 21:33 ` Saeed Mahameed
0 siblings, 1 reply; 2+ messages in thread
From: Jakub Kicinski @ 2022-01-26 18:57 UTC (permalink / raw)
To: saeedm; +Cc: leon, tariqt, linux-rdma, netdev, Jakub Kicinski
mlx5 has some unused static inline helpers in include/
while at it also clean static inlines in the driver itself.
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
---
.../ethernet/mellanox/mlx5/core/en_accel/en_accel.h | 9 ---------
drivers/net/ethernet/mellanox/mlx5/core/lib/hv_vhca.h | 7 -------
include/linux/mlx5/driver.h | 10 ----------
3 files changed, 26 deletions(-)
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/en_accel.h b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/en_accel.h
index d964665eaa63..62cde3e87c2e 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/en_accel.h
+++ b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/en_accel.h
@@ -139,15 +139,6 @@ static inline bool mlx5e_accel_tx_begin(struct net_device *dev,
return true;
}
-static inline bool mlx5e_accel_tx_is_ipsec_flow(struct mlx5e_accel_tx_state *state)
-{
-#ifdef CONFIG_MLX5_EN_IPSEC
- return mlx5e_ipsec_is_tx_flow(&state->ipsec);
-#else
- return false;
-#endif
-}
-
static inline unsigned int mlx5e_accel_tx_ids_len(struct mlx5e_txqsq *sq,
struct mlx5e_accel_tx_state *state)
{
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/lib/hv_vhca.h b/drivers/net/ethernet/mellanox/mlx5/core/lib/hv_vhca.h
index 4bad6a5fde56..f240ffe5116c 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/lib/hv_vhca.h
+++ b/drivers/net/ethernet/mellanox/mlx5/core/lib/hv_vhca.h
@@ -92,13 +92,6 @@ mlx5_hv_vhca_agent_create(struct mlx5_hv_vhca *hv_vhca,
static inline void mlx5_hv_vhca_agent_destroy(struct mlx5_hv_vhca_agent *agent)
{
}
-
-static inline int
-mlx5_hv_vhca_write_agent(struct mlx5_hv_vhca_agent *agent,
- void *buf, int len)
-{
- return 0;
-}
#endif
#endif /* __LIB_HV_VHCA_H__ */
diff --git a/include/linux/mlx5/driver.h b/include/linux/mlx5/driver.h
index 78655d8d13a7..1b398c9e17b9 100644
--- a/include/linux/mlx5/driver.h
+++ b/include/linux/mlx5/driver.h
@@ -863,20 +863,10 @@ struct mlx5_hca_vport_context {
bool grh_required;
};
-static inline void *mlx5_buf_offset(struct mlx5_frag_buf *buf, int offset)
-{
- return buf->frags->buf + offset;
-}
-
#define STRUCT_FIELD(header, field) \
.struct_offset_bytes = offsetof(struct ib_unpacked_ ## header, field), \
.struct_size_bytes = sizeof((struct ib_unpacked_ ## header *)0)->field
-static inline struct mlx5_core_dev *pci2mlx5_core_dev(struct pci_dev *pdev)
-{
- return pci_get_drvdata(pdev);
-}
-
extern struct dentry *mlx5_debugfs_root;
static inline u16 fw_rev_maj(struct mlx5_core_dev *dev)
--
2.34.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] mlx5: remove usused static inlines
2022-01-26 18:57 [PATCH] mlx5: remove usused static inlines Jakub Kicinski
@ 2022-01-26 21:33 ` Saeed Mahameed
0 siblings, 0 replies; 2+ messages in thread
From: Saeed Mahameed @ 2022-01-26 21:33 UTC (permalink / raw)
To: Jakub Kicinski; +Cc: leon, tariqt, linux-rdma, netdev
On 26 Jan 10:57, Jakub Kicinski wrote:
>mlx5 has some unused static inline helpers in include/
>while at it also clean static inlines in the driver itself.
>
>Signed-off-by: Jakub Kicinski <kuba@kernel.org>
>---
> .../ethernet/mellanox/mlx5/core/en_accel/en_accel.h | 9 ---------
> drivers/net/ethernet/mellanox/mlx5/core/lib/hv_vhca.h | 7 -------
> include/linux/mlx5/driver.h | 10 ----------
LGTM, applied to mlx5-next.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-01-26 21:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-01-26 18:57 [PATCH] mlx5: remove usused static inlines Jakub Kicinski
2022-01-26 21:33 ` Saeed Mahameed
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).