Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
vxge-config.c File Reference
#include <linux/vmalloc.h>
#include <linux/etherdevice.h>
#include <linux/pci.h>
#include <linux/pci_hotplug.h>
#include <linux/slab.h>
#include "vxge-traffic.h"
#include "vxge-config.h"
#include "vxge-main.h"

Go to the source code of this file.

Macros

#define VXGE_HW_VPATH_STATS_PIO_READ(offset)
 

Functions

int vxge_hw_vpath_wait_receive_idle (struct __vxge_hw_device *hldev, u32 vp_id)
 
void vxge_hw_device_wait_receive_idle (struct __vxge_hw_device *hldev)
 
enum vxge_hw_status vxge_hw_upgrade_read_version (struct __vxge_hw_device *hldev, u32 *major, u32 *minor, u32 *build)
 
enum vxge_hw_status vxge_hw_flash_fw (struct __vxge_hw_device *hldev)
 
enum vxge_hw_status vxge_update_fw_image (struct __vxge_hw_device *hldev, const u8 *fwdata, int size)
 
enum vxge_hw_status vxge_hw_vpath_eprom_img_ver_get (struct __vxge_hw_device *hldev, struct eprom_image *img)
 
enum vxge_hw_status __vxge_hw_device_is_privilaged (u32 host_type, u32 func_id)
 
enum vxge_hw_status __devinit vxge_hw_device_hw_info_get (void __iomem *bar0, struct vxge_hw_device_hw_info *hw_info)
 
enum vxge_hw_status __devinit vxge_hw_device_initialize (struct __vxge_hw_device **devh, struct vxge_hw_device_attr *attr, struct vxge_hw_device_config *device_config)
 
void vxge_hw_device_terminate (struct __vxge_hw_device *hldev)
 
enum vxge_hw_status vxge_hw_device_stats_get (struct __vxge_hw_device *hldev, struct vxge_hw_device_stats_hw_info *hw_stats)
 
enum vxge_hw_status vxge_hw_driver_stats_get (struct __vxge_hw_device *hldev, struct vxge_hw_device_stats_sw_info *sw_stats)
 
enum vxge_hw_status vxge_hw_mrpcim_stats_access (struct __vxge_hw_device *hldev, u32 operation, u32 location, u32 offset, u64 *stat)
 
enum vxge_hw_status vxge_hw_device_xmac_stats_get (struct __vxge_hw_device *hldev, struct vxge_hw_xmac_stats *xmac_stats)
 
void vxge_hw_device_debug_set (struct __vxge_hw_device *hldev, enum vxge_debug_level level, u32 mask)
 
u32 vxge_hw_device_error_level_get (struct __vxge_hw_device *hldev)
 
u32 vxge_hw_device_trace_level_get (struct __vxge_hw_device *hldev)
 
enum vxge_hw_status vxge_hw_device_getpause_data (struct __vxge_hw_device *hldev, u32 port, u32 *tx, u32 *rx)
 
enum vxge_hw_status vxge_hw_device_setpause_data (struct __vxge_hw_device *hldev, u32 port, u32 tx, u32 rx)
 
u16 vxge_hw_device_link_width_get (struct __vxge_hw_device *hldev)
 
enum vxge_hw_status vxge_hw_ring_replenish (struct __vxge_hw_ring *ring)
 
enum vxge_hw_status __devinit vxge_hw_device_config_default_get (struct vxge_hw_device_config *device_config)
 
enum vxge_hw_status vxge_hw_mgmt_reg_read (struct __vxge_hw_device *hldev, enum vxge_hw_mgmt_reg_type type, u32 index, u32 offset, u64 *value)
 
enum vxge_hw_status vxge_hw_vpath_strip_fcs_check (struct __vxge_hw_device *hldev, u64 vpath_mask)
 
enum vxge_hw_status vxge_hw_mgmt_reg_write (struct __vxge_hw_device *hldev, enum vxge_hw_mgmt_reg_type type, u32 index, u32 offset, u64 value)
 
enum vxge_hw_status vxge_hw_device_flick_link_led (struct __vxge_hw_device *hldev, u64 on_off)
 
enum vxge_hw_status __vxge_hw_vpath_rts_table_get (struct __vxge_hw_vpath_handle *vp, u32 action, u32 rts_table, u32 offset, u64 *data0, u64 *data1)
 
enum vxge_hw_status __vxge_hw_vpath_rts_table_set (struct __vxge_hw_vpath_handle *vp, u32 action, u32 rts_table, u32 offset, u64 steer_data0, u64 steer_data1)
 
enum vxge_hw_status vxge_hw_vpath_rts_rth_set (struct __vxge_hw_vpath_handle *vp, enum vxge_hw_rth_algoritms algorithm, struct vxge_hw_rth_hash_types *hash_type, u16 bucket_size)
 
enum vxge_hw_status vxge_hw_vpath_rts_rth_itable_set (struct __vxge_hw_vpath_handle **vpath_handles, u32 vpath_count, u8 *mtable, u8 *itable, u32 itable_size)
 
enum vxge_hw_status vxge_hw_vpath_check_leak (struct __vxge_hw_ring *ring)
 
enum vxge_hw_status vxge_hw_vpath_mtu_set (struct __vxge_hw_vpath_handle *vp, u32 new_mtu)
 
enum vxge_hw_status vxge_hw_vpath_open (struct __vxge_hw_device *hldev, struct vxge_hw_vpath_attr *attr, struct __vxge_hw_vpath_handle **vpath_handle)
 
void vxge_hw_vpath_rx_doorbell_init (struct __vxge_hw_vpath_handle *vp)
 
enum vxge_hw_status vxge_hw_vpath_close (struct __vxge_hw_vpath_handle *vp)
 
enum vxge_hw_status vxge_hw_vpath_reset (struct __vxge_hw_vpath_handle *vp)
 
enum vxge_hw_status vxge_hw_vpath_recover_from_reset (struct __vxge_hw_vpath_handle *vp)
 
void vxge_hw_vpath_enable (struct __vxge_hw_vpath_handle *vp)
 

Macro Definition Documentation

#define VXGE_HW_VPATH_STATS_PIO_READ (   offset)
Value:
{ \
status = __vxge_hw_vpath_stats_access(vpath, \
offset, \
&val64); \
if (status != VXGE_HW_OK) \
return status; \
}

Definition at line 24 of file vxge-config.c.

Function Documentation

enum vxge_hw_status __vxge_hw_device_is_privilaged ( u32  host_type,
u32  func_id 
)

Definition at line 690 of file vxge-config.c.

enum vxge_hw_status __vxge_hw_vpath_rts_table_get ( struct __vxge_hw_vpath_handle vp,
u32  action,
u32  rts_table,
u32  offset,
u64 data0,
u64 data1 
)

Definition at line 3652 of file vxge-config.c.

enum vxge_hw_status __vxge_hw_vpath_rts_table_set ( struct __vxge_hw_vpath_handle vp,
u32  action,
u32  rts_table,
u32  offset,
u64  steer_data0,
u64  steer_data1 
)

Definition at line 3692 of file vxge-config.c.

enum vxge_hw_status __devinit vxge_hw_device_config_default_get ( struct vxge_hw_device_config device_config)

Definition at line 2921 of file vxge-config.c.

void vxge_hw_device_debug_set ( struct __vxge_hw_device hldev,
enum vxge_debug_level  level,
u32  mask 
)

Definition at line 1852 of file vxge-config.c.

u32 vxge_hw_device_error_level_get ( struct __vxge_hw_device hldev)

Definition at line 1877 of file vxge-config.c.

enum vxge_hw_status vxge_hw_device_flick_link_led ( struct __vxge_hw_device hldev,
u64  on_off 
)

vxge_hw_device_flick_link_led - Flick (blink) link LED. : HW device. : TRUE if flickering to be on, FALSE to be off

Flicker the link LED.

Definition at line 3626 of file vxge-config.c.

enum vxge_hw_status vxge_hw_device_getpause_data ( struct __vxge_hw_device hldev,
u32  port,
u32 tx,
u32 rx 
)

Definition at line 1909 of file vxge-config.c.

enum vxge_hw_status __devinit vxge_hw_device_hw_info_get ( void __iomem bar0,
struct vxge_hw_device_hw_info hw_info 
)

vxge_hw_device_hw_info_get - Get the hw information Returns the vpath mask that has the bits set for each vpath allocated for the driver, FW version information, and the first mac address for each vpath

Definition at line 997 of file vxge-config.c.

enum vxge_hw_status __devinit vxge_hw_device_initialize ( struct __vxge_hw_device **  devh,
struct vxge_hw_device_attr attr,
struct vxge_hw_device_config device_config 
)

Definition at line 1314 of file vxge-config.c.

u16 vxge_hw_device_link_width_get ( struct __vxge_hw_device hldev)

Definition at line 1980 of file vxge-config.c.

enum vxge_hw_status vxge_hw_device_setpause_data ( struct __vxge_hw_device hldev,
u32  port,
u32  tx,
u32  rx 
)

Definition at line 1944 of file vxge-config.c.

enum vxge_hw_status vxge_hw_device_stats_get ( struct __vxge_hw_device hldev,
struct vxge_hw_device_stats_hw_info hw_stats 
)

Definition at line 1650 of file vxge-config.c.

void vxge_hw_device_terminate ( struct __vxge_hw_device hldev)

Definition at line 1400 of file vxge-config.c.

u32 vxge_hw_device_trace_level_get ( struct __vxge_hw_device hldev)

Definition at line 1893 of file vxge-config.c.

void vxge_hw_device_wait_receive_idle ( struct __vxge_hw_device hldev)

Definition at line 99 of file vxge-config.c.

enum vxge_hw_status vxge_hw_device_xmac_stats_get ( struct __vxge_hw_device hldev,
struct vxge_hw_xmac_stats xmac_stats 
)

Definition at line 1803 of file vxge-config.c.

enum vxge_hw_status vxge_hw_driver_stats_get ( struct __vxge_hw_device hldev,
struct vxge_hw_device_stats_sw_info sw_stats 
)

Definition at line 1681 of file vxge-config.c.

enum vxge_hw_status vxge_hw_flash_fw ( struct __vxge_hw_device hldev)

Definition at line 247 of file vxge-config.c.

enum vxge_hw_status vxge_hw_mgmt_reg_read ( struct __vxge_hw_device hldev,
enum vxge_hw_mgmt_reg_type  type,
u32  index,
u32  offset,
u64 value 
)

Definition at line 3123 of file vxge-config.c.

enum vxge_hw_status vxge_hw_mgmt_reg_write ( struct __vxge_hw_device hldev,
enum vxge_hw_mgmt_reg_type  type,
u32  index,
u32  offset,
u64  value 
)

Definition at line 3250 of file vxge-config.c.

enum vxge_hw_status vxge_hw_mrpcim_stats_access ( struct __vxge_hw_device hldev,
u32  operation,
u32  location,
u32  offset,
u64 stat 
)

Definition at line 1699 of file vxge-config.c.

enum vxge_hw_status vxge_hw_ring_replenish ( struct __vxge_hw_ring ring)

Definition at line 2152 of file vxge-config.c.

enum vxge_hw_status vxge_hw_upgrade_read_version ( struct __vxge_hw_device hldev,
u32 major,
u32 minor,
u32 build 
)

Definition at line 223 of file vxge-config.c.

enum vxge_hw_status vxge_hw_vpath_check_leak ( struct __vxge_hw_ring ring)

vxge_hw_vpath_check_leak - Check for memory leak : Handle to the ring object used for receive

If PRC_RXD_DOORBELL_VPn.NEW_QW_CNT is larger or equal to PRC_CFG6_VPn.RXD_SPAT then a leak has occurred. Returns: VXGE_HW_FAIL, if leak has occurred.

Definition at line 3953 of file vxge-config.c.

enum vxge_hw_status vxge_hw_vpath_close ( struct __vxge_hw_vpath_handle vp)

Definition at line 4981 of file vxge-config.c.

void vxge_hw_vpath_enable ( struct __vxge_hw_vpath_handle vp)

Definition at line 5110 of file vxge-config.c.

enum vxge_hw_status vxge_hw_vpath_eprom_img_ver_get ( struct __vxge_hw_device hldev,
struct eprom_image img 
)

Definition at line 374 of file vxge-config.c.

enum vxge_hw_status vxge_hw_vpath_mtu_set ( struct __vxge_hw_vpath_handle vp,
u32  new_mtu 
)

Definition at line 4718 of file vxge-config.c.

enum vxge_hw_status vxge_hw_vpath_open ( struct __vxge_hw_device hldev,
struct vxge_hw_vpath_attr attr,
struct __vxge_hw_vpath_handle **  vpath_handle 
)

Definition at line 4813 of file vxge-config.c.

enum vxge_hw_status vxge_hw_vpath_recover_from_reset ( struct __vxge_hw_vpath_handle vp)

Definition at line 5058 of file vxge-config.c.

enum vxge_hw_status vxge_hw_vpath_reset ( struct __vxge_hw_vpath_handle vp)

Definition at line 5032 of file vxge-config.c.

enum vxge_hw_status vxge_hw_vpath_rts_rth_itable_set ( struct __vxge_hw_vpath_handle **  vpath_handles,
u32  vpath_count,
u8 mtable,
u8 itable,
u32  itable_size 
)

Definition at line 3814 of file vxge-config.c.

enum vxge_hw_status vxge_hw_vpath_rts_rth_set ( struct __vxge_hw_vpath_handle vp,
enum vxge_hw_rth_algoritms  algorithm,
struct vxge_hw_rth_hash_types hash_type,
u16  bucket_size 
)

Definition at line 3720 of file vxge-config.c.

void vxge_hw_vpath_rx_doorbell_init ( struct __vxge_hw_vpath_handle vp)

vxge_hw_vpath_rx_doorbell_post - Close the handle got from previous vpath (vpath) open : Handle got from previous vpath open

This function is used to close access to virtual path opened earlier.

Definition at line 4918 of file vxge-config.c.

enum vxge_hw_status vxge_hw_vpath_strip_fcs_check ( struct __vxge_hw_device hldev,
u64  vpath_mask 
)

Definition at line 3228 of file vxge-config.c.

int vxge_hw_vpath_wait_receive_idle ( struct __vxge_hw_device hldev,
u32  vp_id 
)

Definition at line 47 of file vxge-config.c.

enum vxge_hw_status vxge_update_fw_image ( struct __vxge_hw_device hldev,
const u8 fwdata,
int  size 
)

Definition at line 278 of file vxge-config.c.