mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-07-16 09:32:36 -04:00
net: stmmac: dwmac4: Allow platforms to specify some DMA/MTL offsets
Some platforms have dwmac4 implementations that have a different address space layout than the default, resulting in the need to define their own DMA/MTL offsets. Extend the functions to allow a platform driver to indicate what its addresses are, overriding the defaults. Signed-off-by: Andrew Halaney <ahalaney@redhat.com> Reviewed-by: Jesse Brandeburg <jesse.brandeburg@intel.com> Tested-by: Brian Masney <bmasney@redhat.com> Signed-off-by: Paolo Abeni <pabeni@redhat.com>
This commit is contained in:
committed by
Paolo Abeni
parent
1d84b487bc
commit
33719b57f5
@@ -186,6 +186,24 @@ struct stmmac_safety_feature_cfg {
|
||||
u32 tmouten;
|
||||
};
|
||||
|
||||
/* Addresses that may be customized by a platform */
|
||||
struct dwmac4_addrs {
|
||||
u32 dma_chan;
|
||||
u32 dma_chan_offset;
|
||||
u32 mtl_chan;
|
||||
u32 mtl_chan_offset;
|
||||
u32 mtl_ets_ctrl;
|
||||
u32 mtl_ets_ctrl_offset;
|
||||
u32 mtl_txq_weight;
|
||||
u32 mtl_txq_weight_offset;
|
||||
u32 mtl_send_slp_cred;
|
||||
u32 mtl_send_slp_cred_offset;
|
||||
u32 mtl_high_cred;
|
||||
u32 mtl_high_cred_offset;
|
||||
u32 mtl_low_cred;
|
||||
u32 mtl_low_cred_offset;
|
||||
};
|
||||
|
||||
struct plat_stmmacenet_data {
|
||||
int bus_id;
|
||||
int phy_addr;
|
||||
@@ -274,5 +292,6 @@ struct plat_stmmacenet_data {
|
||||
bool use_phy_wol;
|
||||
bool sph_disable;
|
||||
bool serdes_up_after_phy_linkup;
|
||||
const struct dwmac4_addrs *dwmac4_addrs;
|
||||
};
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user