| /linux/drivers/net/ethernet/wangxun/libwx/ |
| H A D | wx_ptp.c | 34 static u64 wx_ptp_timecounter_cyc2time(struct wx *wx, u64 timestamp) in wx_ptp_timecounter_cyc2time() argument 40 seq = read_seqbegin(&wx->hw_tc_lock); in wx_ptp_timecounter_cyc2time() 41 ns = timecounter_cyc2time(&wx->hw_tc, timestamp); in wx_ptp_timecounter_cyc2time() 42 } while (read_seqretry(&wx->hw_tc_lock, seq)); in wx_ptp_timecounter_cyc2time() 47 static u64 wx_ptp_readtime(struct wx *wx, struct ptp_system_timestamp *sts) in wx_ptp_readtime() argument 51 timeh1 = rd32ptp(wx, WX_TSC_1588_SYSTIMH); in wx_ptp_readtime() 53 timel = rd32ptp(wx, WX_TSC_1588_SYSTIML); in wx_ptp_readtime() 55 timeh2 = rd32ptp(wx, WX_TSC_1588_SYSTIMH); in wx_ptp_readtime() 59 timel = rd32ptp(wx, WX_TSC_1588_SYSTIML); in wx_ptp_readtime() 67 struct wx *wx = container_of(ptp, struct wx, ptp_caps); in wx_ptp_adjfine() local [all …]
|
| H A D | wx_hw.c | 19 struct wx *wx = bus->priv; in wx_phy_read_reg_mdi() local 27 wr32(wx, WX_MSCA, command); in wx_phy_read_reg_mdi() 30 if (wx->mac.type == wx_mac_em) in wx_phy_read_reg_mdi() 32 wr32(wx, WX_MSCC, command); in wx_phy_read_reg_mdi() 36 100000, false, wx, WX_MSCC); in wx_phy_read_reg_mdi() 38 wx_err(wx, "Mdio read c22 command did not complete.\n"); in wx_phy_read_reg_mdi() 42 return (u16)rd32(wx, WX_MSCC); in wx_phy_read_reg_mdi() 48 struct wx *wx = bus->priv; in wx_phy_write_reg_mdi() local 56 wr32(wx, WX_MSCA, command); in wx_phy_write_reg_mdi() 59 if (wx->mac.type == wx_mac_em) in wx_phy_write_reg_mdi() [all …]
|
| H A D | wx_vf_common.c | 17 struct wx *wx = pci_get_drvdata(pdev); in wxvf_suspend() local 19 netif_device_detach(wx->netdev); in wxvf_suspend() 20 wx_clear_interrupt_scheme(wx); in wxvf_suspend() 36 struct wx *wx = pci_get_drvdata(pdev); in wxvf_resume() local 39 wx_init_interrupt_scheme(wx); in wxvf_resume() 40 netif_device_attach(wx->netdev); in wxvf_resume() 48 struct wx *wx = pci_get_drvdata(pdev); in wxvf_remove() local 51 netdev = wx->netdev; in wxvf_remove() 53 timer_shutdown_sync(&wx->service_timer); in wxvf_remove() 54 cancel_work_sync(&wx->service_task); in wxvf_remove() [all …]
|
| H A D | wx_err.c | 26 struct wx *wx = pci_get_drvdata(pdev); in wx_io_error_detected() local 29 if (!wx) in wx_io_error_detected() 32 netdev = wx->netdev; in wx_io_error_detected() 38 set_bit(WX_FLAG_NEED_PCIE_RECOVERY, wx->flags); in wx_io_error_detected() 39 wx_soft_quiesce(wx); in wx_io_error_detected() 46 if (!test_and_set_bit(WX_STATE_DISABLED, wx->state)) in wx_io_error_detected() 64 struct wx *wx = pci_get_drvdata(pdev); in wx_io_slot_reset() local 67 wx_err(wx, "Cannot re-enable PCI device after reset.\n"); in wx_io_slot_reset() 73 clear_bit(WX_STATE_DISABLED, wx->state); in wx_io_slot_reset() 74 clear_bit(WX_FLAG_NEED_PCIE_RECOVERY, wx->flags); in wx_io_slot_reset() [all …]
|
| H A D | wx_mbx.c | 15 static int wx_obtain_mbx_lock_pf(struct wx *wx, u16 vf) in wx_obtain_mbx_lock_pf() argument 22 wr32(wx, WX_PXMAILBOX(vf), WX_PXMAILBOX_PFU); in wx_obtain_mbx_lock_pf() 25 mailbox = rd32(wx, WX_PXMAILBOX(vf)); in wx_obtain_mbx_lock_pf() 31 wx_err(wx, "Failed to obtain mailbox lock for PF%d", vf); in wx_obtain_mbx_lock_pf() 36 static int wx_check_for_bit_pf(struct wx *wx, u32 mask, int index) in wx_check_for_bit_pf() argument 38 u32 mbvficr = rd32(wx, WX_MBVFICR(index)); in wx_check_for_bit_pf() 42 wr32(wx, WX_MBVFICR(index), mask); in wx_check_for_bit_pf() 54 int wx_check_for_ack_pf(struct wx *wx, u16 vf) in wx_check_for_ack_pf() argument 58 return wx_check_for_bit_pf(wx, in wx_check_for_ack_pf() 71 int wx_check_for_msg_pf(struct wx *wx, u16 vf) in wx_check_for_msg_pf() argument [all …]
|
| H A D | wx_vf.c | 12 static void wx_virt_clr_reg(struct wx *wx) in wx_virt_clr_reg() argument 22 wr32m(wx, WX_VXRXDCTL(i), in wx_virt_clr_reg() 26 rd32(wx, WX_VXSTATUS); in wx_virt_clr_reg() 35 void wx_init_hw_vf(struct wx *wx) in wx_init_hw_vf() argument 37 wx_get_mac_addr_vf(wx, wx->mac.addr); in wx_init_hw_vf() 41 static int wx_mbx_write_and_read_reply(struct wx *wx, u32 *req_buf, in wx_mbx_write_and_read_reply() argument 46 ret = wx_write_posted_mbx(wx, req_buf, size); in wx_mbx_write_and_read_reply() 50 return wx_read_posted_mbx(wx, resp_buf, size); in wx_mbx_write_and_read_reply() 62 int wx_reset_hw_vf(struct wx *wx) in wx_reset_hw_vf() argument 64 struct wx_mbx_info *mbx = &wx->mbx; in wx_reset_hw_vf() [all …]
|
| H A D | wx_ethtool.c | 23 .sizeof_stat = sizeof(((struct wx *)0)->m), \ 24 .stat_offset = offsetof(struct wx, m) } 79 struct wx *wx = netdev_priv(netdev); in wx_get_sset_count() local 84 if (test_bit(WX_FLAG_FDIR_CAPABLE, wx->flags)) in wx_get_sset_count() 86 if (test_bit(WX_FLAG_RSC_CAPABLE, wx->flags)) in wx_get_sset_count() 97 struct wx *wx = netdev_priv(netdev); in wx_get_strings() local 105 if (test_bit(WX_FLAG_FDIR_CAPABLE, wx->flags)) { in wx_get_strings() 109 if (test_bit(WX_FLAG_RSC_CAPABLE, wx->flags)) { in wx_get_strings() 129 struct wx *wx = netdev_priv(netdev); in wx_get_ethtool_stats() local 135 wx_update_stats(wx); in wx_get_ethtool_stats() [all …]
|
| H A D | wx_vf_lib.c | 15 struct wx *wx = q_vector->wx; in wx_write_eitr_vf() local 19 switch (wx->mac.type) { in wx_write_eitr_vf() 37 wr32(wx, WX_VXITR(v_idx), itr_reg); in wx_write_eitr_vf() 40 static void wx_set_ivar_vf(struct wx *wx, s8 direction, u8 queue, in wx_set_ivar_vf() argument 48 ivar = rd32(wx, WX_VXIVAR_MISC); in wx_set_ivar_vf() 51 wr32(wx, WX_VXIVAR_MISC, ivar); in wx_set_ivar_vf() 56 ivar = rd32(wx, WX_VXIVAR(queue >> 1)); in wx_set_ivar_vf() 59 wr32(wx, WX_VXIVAR(queue >> 1), ivar); in wx_set_ivar_vf() 63 void wx_configure_msix_vf(struct wx *wx) in wx_configure_msix_vf() argument 67 wx->eims_enable_mask = 0; in wx_configure_msix_vf() [all …]
|
| H A D | wx_lib.h | 15 void wx_napi_enable_all(struct wx *wx); 16 void wx_napi_disable_all(struct wx *wx); 17 void wx_reset_interrupt_capability(struct wx *wx); 18 void wx_clear_interrupt_scheme(struct wx *wx); 19 int wx_init_interrupt_scheme(struct wx *wx); 21 void wx_free_irq(struct wx *wx); 22 int wx_setup_isb_resources(struct wx *wx); 23 void wx_free_isb_resources(struct wx *wx); 24 u32 wx_misc_isb(struct wx *wx, enum wx_isb_idx idx); 26 void wx_configure_vectors(struct wx *wx); [all …]
|
| H A D | wx_lib.c | 400 struct wx *wx = rx_ring->q_vector->wx; in wx_is_non_eop() local 410 if (test_bit(WX_FLAG_RSC_ENABLED, wx->flags)) { in wx_is_non_eop() 591 ethertype = ring->q_vector->wx->tpid[idx]; in wx_rx_vlan() 638 struct wx *wx = netdev_priv(rx_ring->netdev); in wx_process_skb_fields() local 640 if (test_bit(WX_FLAG_RSC_CAPABLE, wx->flags)) in wx_process_skb_fields() 646 if (unlikely(test_bit(WX_FLAG_RX_HWTSTAMP_ENABLED, wx->flags)) && in wx_process_skb_fields() 648 wx_ptp_rx_hwtstamp(rx_ring->q_vector->wx, skb); in wx_process_skb_fields() 786 unsigned int budget = q_vector->wx->tx_work_limit; in wx_clean_tx_irq() 788 struct wx *wx = netdev_priv(tx_ring->netdev); in wx_clean_tx_irq() local 835 if (unlikely(test_bit(WX_STATE_PTP_TX_IN_PROGRESS, wx->state)) && in wx_clean_tx_irq() [all …]
|
| H A D | wx_mbx.h | 85 int wx_write_mbx_pf(struct wx *wx, u32 *msg, u16 size, u16 vf); 86 int wx_read_mbx_pf(struct wx *wx, u32 *msg, u16 size, u16 vf); 87 int wx_check_for_rst_pf(struct wx *wx, u16 mbx_id); 88 int wx_check_for_msg_pf(struct wx *wx, u16 mbx_id); 89 int wx_check_for_ack_pf(struct wx *wx, u16 mbx_id); 91 int wx_read_posted_mbx(struct wx *wx, u32 *msg, u16 size); 92 int wx_write_posted_mbx(struct wx *wx, u32 *msg, u16 size); 93 int wx_check_for_rst_vf(struct wx *wx); 94 int wx_check_for_msg_vf(struct wx *wx); 95 int wx_read_mbx_vf(struct wx *wx, u32 *msg, u16 size); [all …]
|
| H A D | wx_ptp.h | 7 void wx_ptp_check_pps_event(struct wx *wx); 8 void wx_ptp_reset_cyclecounter(struct wx *wx); 9 void wx_ptp_reset(struct wx *wx); 10 void wx_ptp_init(struct wx *wx); 11 void wx_ptp_suspend(struct wx *wx); 12 void wx_ptp_stop(struct wx *wx); 13 void wx_ptp_quiesce(struct wx *wx); 14 void wx_ptp_rx_hwtstamp(struct wx *wx, struct sk_buff *skb);
|
| H A D | wx_vf.h | 111 void wx_init_hw_vf(struct wx *wx); 112 int wx_reset_hw_vf(struct wx *wx); 113 void wx_get_mac_addr_vf(struct wx *wx, u8 *mac_addr); 114 void wx_stop_adapter_vf(struct wx *wx); 115 int wx_get_fw_version_vf(struct wx *wx); 116 int wx_set_rar_vf(struct wx *wx, u32 index, u8 *addr, u32 enable_addr); 117 int wx_update_mc_addr_list_vf(struct wx *wx, struct net_device *netdev); 118 int wx_set_uc_addr_vf(struct wx *wx, u32 index, u8 *addr); 119 int wx_rlpml_set_vf(struct wx *wx, u16 max_size); 120 int wx_negotiate_api_version(struct wx *wx, int api); [all …]
|
| H A D | wx_vf_common.h | 11 int wx_request_msix_irqs_vf(struct wx *wx); 12 void wx_negotiate_api_vf(struct wx *wx); 13 void wx_reset_vf(struct wx *wx); 15 void wx_configure_vf(struct wx *wx); 17 void wxvf_watchdog_update_link(struct wx *wx); 18 void wxvf_up_complete(struct wx *wx); 20 void wxvf_down(struct wx *wx); 22 void wxvf_init_service(struct wx *wx);
|
| H A D | wx_err.h | 12 void wx_check_err_subtask(struct wx *wx); 13 int wx_init_err_task(struct wx *wx); 14 void wx_check_hang_subtask(struct wx *wx);
|
| /linux/drivers/net/ethernet/wangxun/ngbe/ |
| H A D | ngbe_main.c | 50 static void ngbe_down_suspend(struct wx *wx) in ngbe_down_suspend() argument 52 if (test_and_set_bit(WX_STATE_RES_FREED, wx->state)) in ngbe_down_suspend() 55 phylink_stop(wx->phylink); in ngbe_down_suspend() 56 phylink_disconnect_phy(wx->phylink); in ngbe_down_suspend() 57 wx_clean_all_tx_rings(wx); in ngbe_down_suspend() 58 wx_clean_all_rx_rings(wx); in ngbe_down_suspend() 59 wx_free_irq(wx); in ngbe_down_suspend() 60 wx_free_isb_resources(wx); in ngbe_down_suspend() 61 wx_free_resources(wx); in ngbe_down_suspend() 68 static void ngbe_init_type_code(struct wx *wx) in ngbe_init_type_code() argument [all …]
|
| H A D | ngbe_hw.c | 13 int ngbe_eeprom_chksum_hostif(struct wx *wx) in ngbe_eeprom_chksum_hostif() argument 28 status = wx_host_interface_command(wx, (u32 *)&buffer, sizeof(buffer), in ngbe_eeprom_chksum_hostif() 33 tmp = rd32a(wx, WX_MNG_MBOX, 1); in ngbe_eeprom_chksum_hostif() 39 static int ngbe_reset_misc(struct wx *wx) in ngbe_reset_misc() argument 41 wx_reset_misc(wx); in ngbe_reset_misc() 42 if (wx->gpio_ctrl) { in ngbe_reset_misc() 44 wr32(wx, NGBE_GPIO_DDR, 0x1); in ngbe_reset_misc() 45 ngbe_sfp_modules_txrx_powerctl(wx, false); in ngbe_reset_misc() 50 void ngbe_sfp_modules_txrx_powerctl(struct wx *wx, bool swi) in ngbe_sfp_modules_txrx_powerctl() argument 53 wr32(wx, NGBE_GPIO_DR, swi ? 0 : NGBE_GPIO_DR_0); in ngbe_sfp_modules_txrx_powerctl() [all …]
|
| H A D | ngbe_ethtool.c | 20 struct wx *wx = netdev_priv(netdev); in ngbe_set_ringparam() local 31 if (new_tx_count == wx->tx_ring_count && in ngbe_set_ringparam() 32 new_rx_count == wx->rx_ring_count) in ngbe_set_ringparam() 35 mutex_lock(&wx->reset_lock); in ngbe_set_ringparam() 36 set_bit(WX_STATE_RESETTING, wx->state); in ngbe_set_ringparam() 38 if (!netif_running(wx->netdev)) { in ngbe_set_ringparam() 39 for (i = 0; i < wx->num_tx_queues; i++) in ngbe_set_ringparam() 40 wx->tx_ring[i]->count = new_tx_count; in ngbe_set_ringparam() 41 for (i = 0; i < wx->num_rx_queues; i++) in ngbe_set_ringparam() 42 wx->rx_ring[i]->count = new_rx_count; in ngbe_set_ringparam() [all …]
|
| H A D | ngbe_hw.h | 10 int ngbe_eeprom_chksum_hostif(struct wx *wx); 11 void ngbe_sfp_modules_txrx_powerctl(struct wx *wx, bool swi); 12 int ngbe_reset_hw(struct wx *wx);
|
| /linux/drivers/net/ethernet/wangxun/txgbe/ |
| H A D | txgbe_main.c | 55 static void txgbe_check_minimum_link(struct wx *wx) in txgbe_check_minimum_link() argument 59 pdev = wx->pdev; in txgbe_check_minimum_link() 72 static int txgbe_enumerate_functions(struct wx *wx) in txgbe_enumerate_functions() argument 74 struct pci_dev *entry, *pdev = wx->pdev; in txgbe_enumerate_functions() 93 static void txgbe_module_detection_subtask(struct wx *wx) in txgbe_module_detection_subtask() argument 97 if (test_bit(WX_STATE_DOWN, wx->state) || in txgbe_module_detection_subtask() 98 test_bit(WX_STATE_RESETTING, wx->state)) in txgbe_module_detection_subtask() 101 if (!test_and_clear_bit(WX_FLAG_NEED_MODULE_RESET, wx->flags)) in txgbe_module_detection_subtask() 111 if (test_bit(WX_STATE_DOWN, wx->state) || in txgbe_module_detection_subtask() 112 test_bit(WX_STATE_RESETTING, wx->state)) in txgbe_module_detection_subtask() [all …]
|
| H A D | txgbe_hw.c | 23 int txgbe_disable_sec_tx_path(struct wx *wx) in txgbe_disable_sec_tx_path() argument 27 wr32m(wx, WX_TSC_CTL, WX_TSC_CTL_TX_DIS, WX_TSC_CTL_TX_DIS); in txgbe_disable_sec_tx_path() 29 1000, 20000, false, wx, WX_TSC_ST); in txgbe_disable_sec_tx_path() 38 void txgbe_enable_sec_tx_path(struct wx *wx) in txgbe_enable_sec_tx_path() argument 40 wr32m(wx, WX_TSC_CTL, WX_TSC_CTL_TX_DIS, 0); in txgbe_enable_sec_tx_path() 41 WX_WRITE_FLUSH(wx); in txgbe_enable_sec_tx_path() 51 static void txgbe_init_thermal_sensor_thresh(struct wx *wx) in txgbe_init_thermal_sensor_thresh() argument 53 struct wx_thermal_sensor_data *data = &wx->mac.sensor; in txgbe_init_thermal_sensor_thresh() 58 if (wx->bus.func) in txgbe_init_thermal_sensor_thresh() 61 wr32(wx, TXGBE_TS_CTL, TXGBE_TS_CTL_EVAL_MD); in txgbe_init_thermal_sensor_thresh() [all …]
|
| H A D | txgbe_aml.c | 18 void txgbe_gpio_init_aml(struct wx *wx) in txgbe_gpio_init_aml() argument 22 if (wx->mac.type == wx_mac_aml40) in txgbe_gpio_init_aml() 27 wr32(wx, WX_GPIO_INTTYPE_LEVEL, mod_rst); in txgbe_gpio_init_aml() 28 wr32(wx, WX_GPIO_INTEN, mod_rst); in txgbe_gpio_init_aml() 30 status = rd32(wx, WX_GPIO_INTSTATUS); in txgbe_gpio_init_aml() 33 wr32(wx, WX_GPIO_EOI, BIT(i)); in txgbe_gpio_init_aml() 40 struct wx *wx = txgbe->wx; in txgbe_gpio_irq_handler_aml() local 43 if (wx->mac.type == wx_mac_aml40) in txgbe_gpio_irq_handler_aml() 48 wr32(wx, WX_GPIO_INTMASK, 0xFF); in txgbe_gpio_irq_handler_aml() 49 status = rd32(wx, WX_GPIO_INTSTATUS); in txgbe_gpio_irq_handler_aml() [all …]
|
| H A D | txgbe_fdir.h | 10 int txgbe_fdir_set_input_mask(struct wx *wx, union txgbe_atr_input *input_mask); 11 int txgbe_fdir_write_perfect_filter(struct wx *wx, 14 int txgbe_fdir_erase_perfect_filter(struct wx *wx, 17 void txgbe_configure_fdir(struct wx *wx); 18 void txgbe_fdir_filter_exit(struct wx *wx);
|
| H A D | txgbe_hw.h | 7 int txgbe_disable_sec_tx_path(struct wx *wx); 8 void txgbe_enable_sec_tx_path(struct wx *wx); 9 int txgbe_validate_eeprom_checksum(struct wx *wx, u16 *checksum_val); 10 int txgbe_reset_hw(struct wx *wx);
|
| /linux/tools/perf/scripts/python/Perf-Trace-Util/lib/Perf/Trace/ |
| H A D | SchedGui.py | 12 import wx 17 class RootFrame(wx.Frame): 24 wx.Frame.__init__(self, parent, id, title) 26 (self.screen_width, self.screen_height) = wx.GetDisplaySize() 39 self.panel = wx.Panel(self, size=(self.screen_width, self.screen_height)) 42 self.scroll = wx.ScrolledWindow(self.panel) 48 self.scroll_panel = wx.Panel(self.scroll, size=(self.screen_width - 15, self.screen_height / 2)) 49 self.scroll_panel.Bind(wx.EVT_PAINT, self.on_paint) 50 self.scroll_panel.Bind(wx.EVT_KEY_DOWN, self.on_key_press) 51 self.scroll_panel.Bind(wx.EVT_LEFT_DOWN, self.on_mouse_down) [all …]
|