openbcm

Git mirror of https://github.com/Broadcom-Network-Switching-Software/OpenBCM
git clone git://git.finwo.net/mirror/broadcom/openbcm
Log | Files | Refs | README

phymod_sim.h (1317B)


      1 /*
      2  * 
      3  * This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file.
      4  * 
      5  * Copyright 2007-2019 Broadcom Inc. All rights reserved.
      6  *
      7  * PHY Simulator (requires PHYMOD library)
      8  */
      9 
     10 #ifndef __PHY_PHYMOD_SIM_H__
     11 #define __PHY_PHYMOD_SIM_H__
     12 
     13 #include <soc/defs.h>
     14 
     15 #ifdef PHYMOD_SUPPORT
     16 
     17 #include <phymod/phymod_sim.h>
     18 #include <phymod/phymod.h>
     19 
     20 extern int
     21 soc_physim_add(int unit, uint32 phy_id,
     22                phymod_sim_drv_t *pms_drv);
     23 
     24 #endif
     25 
     26 extern int
     27 soc_physim_wrmask(int unit, uint32 phy_id,
     28                   uint32 phy_reg_addr, uint16 phy_wr_data, uint16 wr_mask);
     29 
     30 extern int
     31 soc_physim_write(int unit, uint32 phy_id,
     32                  uint32 phy_reg_addr, uint16 phy_wr_data);
     33 
     34 extern int
     35 soc_physim_read(int unit, uint32 phy_id,
     36                 uint32 phy_reg_addr, uint16 *phy_rd_data);
     37 
     38 #ifdef PORTMOD_SUPPORT
     39 
     40 extern int
     41 soc_physim_check_sim(int unit, phymod_dispatch_type_t type,
     42                       phymod_access_t* access, uint32 addr_ident, int* is_sim);
     43 extern int soc_physim_scache_allocate(int unit);
     44 extern int soc_physim_scache_sync(int unit);
     45 extern int soc_physim_scache_recovery(int unit);
     46 extern void
     47 soc_physim_enable_get(int unit, int* is_sim);
     48 #endif /* PORTMOD_SUPPORT */
     49 
     50 #endif /*__PHY_PHYMOD_SIM_H__*/
     51