FreeBSD kernel iwm device code
if_iwm_pcie_trans.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

uint32_t iwm_read_prph (struct iwm_softc *sc, uint32_t addr)
 
void iwm_write_prph (struct iwm_softc *sc, uint32_t addr, uint32_t val)
 
void iwm_write_prph64 (struct iwm_softc *sc, uint64_t addr, uint64_t val)
 
int iwm_poll_prph (struct iwm_softc *sc, uint32_t addr, uint32_t bits, uint32_t mask, int timeout)
 
int iwm_read_mem (struct iwm_softc *sc, uint32_t addr, void *buf, int dwords)
 
int iwm_write_mem (struct iwm_softc *sc, uint32_t addr, const void *buf, int dwords)
 
int iwm_write_mem32 (struct iwm_softc *sc, uint32_t addr, uint32_t val)
 
int iwm_poll_bit (struct iwm_softc *sc, int reg, uint32_t bits, uint32_t mask, int timo)
 
int iwm_nic_lock (struct iwm_softc *sc)
 
void iwm_nic_unlock (struct iwm_softc *sc)
 
void iwm_set_bits_mask_prph (struct iwm_softc *sc, uint32_t reg, uint32_t bits, uint32_t mask)
 
void iwm_set_bits_prph (struct iwm_softc *sc, uint32_t reg, uint32_t bits)
 
void iwm_clear_bits_prph (struct iwm_softc *sc, uint32_t reg, uint32_t bits)
 
void iwm_enable_rfkill_int (struct iwm_softc *sc)
 
int iwm_check_rfkill (struct iwm_softc *sc)
 
int iwm_set_hw_ready (struct iwm_softc *sc)
 
int iwm_prepare_card_hw (struct iwm_softc *sc)
 
void iwm_apm_config (struct iwm_softc *sc)
 
int iwm_apm_init (struct iwm_softc *sc)
 
void iwm_apm_stop (struct iwm_softc *sc)
 
int iwm_start_hw (struct iwm_softc *sc)
 
void iwm_set_pwr (struct iwm_softc *sc)
 
int iwm_pcie_rx_stop (struct iwm_softc *sc)
 
int iwm_pcie_set_cmd_in_flight (struct iwm_softc *sc)
 
void iwm_pcie_clear_cmd_in_flight (struct iwm_softc *sc)
 

Function Documentation

◆ iwm_apm_config()

void iwm_apm_config ( struct iwm_softc sc)

Definition at line 432 of file if_iwm_pcie_trans.c.

References IWM_CLRBITS, IWM_CSR_GIO_REG, IWM_CSR_GIO_REG_VAL_L0S_ENABLED, IWM_DPRINTF, IWM_SETBITS, iwm_softc::sc_dev, and iwm_softc::sc_ltr_enabled.

Referenced by iwm_apm_init().

Here is the caller graph for this function:

◆ iwm_apm_init()

◆ iwm_apm_stop()

◆ iwm_check_rfkill()

int iwm_check_rfkill ( struct iwm_softc sc)

Definition at line 354 of file if_iwm_pcie_trans.c.

References IWM_CSR_GP_CNTRL, IWM_CSR_GP_CNTRL_REG_FLAG_HW_RF_KILL_SW, IWM_FLAG_RFKILL, IWM_READ, and iwm_softc::sc_flags.

Referenced by iwm_parent(), iwm_rftoggle_task(), iwm_start_hw(), and iwm_stop_device().

Here is the caller graph for this function:

◆ iwm_clear_bits_prph()

void iwm_clear_bits_prph ( struct iwm_softc sc,
uint32_t  reg,
uint32_t  bits 
)

Definition at line 335 of file if_iwm_pcie_trans.c.

References iwm_set_bits_mask_prph().

Referenced by iwm_enable_txq(), iwm_pcie_load_section(), and iwm_trans_pcie_fw_alive().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ iwm_enable_rfkill_int()

void iwm_enable_rfkill_int ( struct iwm_softc sc)

◆ iwm_nic_lock()

◆ iwm_nic_unlock()

◆ iwm_pcie_clear_cmd_in_flight()

void iwm_pcie_clear_cmd_in_flight ( struct iwm_softc sc)

◆ iwm_pcie_rx_stop()

◆ iwm_pcie_set_cmd_in_flight()

◆ iwm_poll_bit()

int iwm_poll_bit ( struct iwm_softc sc,
int  reg,
uint32_t  bits,
uint32_t  mask,
int  timo 
)

Definition at line 259 of file if_iwm_pcie_trans.c.

References IWM_READ.

Referenced by iwm_apm_init(), iwm_apm_stop(), iwm_attach(), iwm_nic_lock(), iwm_pcie_rx_stop(), iwm_pcie_set_cmd_in_flight(), iwm_set_hw_ready(), and iwm_stop_device().

Here is the caller graph for this function:

◆ iwm_poll_prph()

int iwm_poll_prph ( struct iwm_softc sc,
uint32_t  addr,
uint32_t  bits,
uint32_t  mask,
int  timeout 
)

Definition at line 196 of file if_iwm_pcie_trans.c.

References iwm_read_prph().

Referenced by iwm_pcie_rx_stop().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ iwm_prepare_card_hw()

int iwm_prepare_card_hw ( struct iwm_softc sc)

Definition at line 400 of file if_iwm_pcie_trans.c.

References IWM_CSR_DBG_LINK_PWR_MGMT_REG, IWM_CSR_HW_IF_CONFIG_REG, IWM_CSR_HW_IF_CONFIG_REG_PREPARE, IWM_CSR_RESET_LINK_PWR_MGMT_DISABLED, IWM_DPRINTF, iwm_set_hw_ready(), and IWM_SETBITS.

Referenced by iwm_attach(), iwm_start_fw(), iwm_start_hw(), and iwm_stop_device().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ iwm_read_mem()

int iwm_read_mem ( struct iwm_softc sc,
uint32_t  addr,
void *  buf,
int  dwords 
)

◆ iwm_read_prph()

uint32_t iwm_read_prph ( struct iwm_softc sc,
uint32_t  addr 
)

◆ iwm_set_bits_mask_prph()

void iwm_set_bits_mask_prph ( struct iwm_softc sc,
uint32_t  reg,
uint32_t  bits,
uint32_t  mask 
)

Definition at line 314 of file if_iwm_pcie_trans.c.

References iwm_nic_lock(), iwm_nic_unlock(), iwm_read_prph(), and iwm_write_prph().

Referenced by iwm_clear_bits_prph(), iwm_nic_config(), iwm_set_bits_prph(), and iwm_set_pwr().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ iwm_set_bits_prph()

void iwm_set_bits_prph ( struct iwm_softc sc,
uint32_t  reg,
uint32_t  bits 
)

Definition at line 329 of file if_iwm_pcie_trans.c.

References iwm_set_bits_mask_prph().

Referenced by iwm_apm_init(), iwm_nic_tx_init(), and iwm_pcie_load_section().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ iwm_set_hw_ready()

int iwm_set_hw_ready ( struct iwm_softc sc)

Definition at line 380 of file if_iwm_pcie_trans.c.

References IWM_CSR_HW_IF_CONFIG_REG, IWM_CSR_HW_IF_CONFIG_REG_BIT_NIC_READY, IWM_CSR_MBOX_SET_REG, IWM_CSR_MBOX_SET_REG_OS_ALIVE, IWM_HW_READY_TIMEOUT, iwm_poll_bit(), and IWM_SETBITS.

Referenced by iwm_prepare_card_hw().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ iwm_set_pwr()

void iwm_set_pwr ( struct iwm_softc sc)

Definition at line 653 of file if_iwm_pcie_trans.c.

References IWM_APMG_PS_CTRL_MSK_PWR_SRC, IWM_APMG_PS_CTRL_REG, IWM_APMG_PS_CTRL_VAL_PWR_SRC_VMAIN, and iwm_set_bits_mask_prph().

Referenced by iwm_nic_init().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ iwm_start_hw()

int iwm_start_hw ( struct iwm_softc sc)

◆ iwm_write_mem()

int iwm_write_mem ( struct iwm_softc sc,
uint32_t  addr,
const void *  buf,
int  dwords 
)

Definition at line 231 of file if_iwm_pcie_trans.c.

References IWM_DPRINTF, IWM_HBUS_TARG_MEM_WADDR, IWM_HBUS_TARG_MEM_WDAT, iwm_nic_lock(), iwm_nic_unlock(), and IWM_WRITE.

Referenced by iwm_trans_pcie_fw_alive(), and iwm_write_mem32().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ iwm_write_mem32()

int iwm_write_mem32 ( struct iwm_softc sc,
uint32_t  addr,
uint32_t  val 
)

Definition at line 253 of file if_iwm_pcie_trans.c.

References iwm_write_mem().

Referenced by iwm_enable_txq().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ iwm_write_prph()

◆ iwm_write_prph64()

void iwm_write_prph64 ( struct iwm_softc sc,
uint64_t  addr,
uint64_t  val 
)

Definition at line 189 of file if_iwm_pcie_trans.c.

References iwm_write_prph().

Referenced by iwm_nic_rx_mq_init().

Here is the call graph for this function:
Here is the caller graph for this function: