Changes between Version 26 and Version 27 of kernel_syscalls
- Timestamp:
- Jan 4, 2015, 11:07:05 PM (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
kernel_syscalls
v26 v27 58 58 Returns the NIC channel index if success. Return -1 if no NIC channel available, or if no CMA channel available. 59 59 60 === 2) int '''_sys_nic_start'''( unsigned int is_rx ) ===60 === 2) int '''_sys_nic_start'''( unsigned int is_rx, unsigned int channel ) === 61 61 This function initializes the kernel chbuf allocated to the calling task. It allocates the distributed 4 Kbytes containers (one container per cluster) from the distributed kernel heap, and initializes the kernel chbuf describing the containers status. This chbuf descriptor is allocated in the seg_kernel_data segment in cluster [0,0]. 62 62 It starts the NIC channel allocated to the calling task, and starts the CMA transfer between the NIC chbuf and the distributed kernel chbuf. The CMA component is configured in OUT_OF_ORDER transfer mode (non blocking when a SRC or DST container is not available). 63 63 * '''is_rx''' : boolean (RX transfer if non zero) 64 * '''channel''' : RX or TX channel index 64 65 Returns 0 if success. Returns -1 if no NIC channel or no CMA channel allocated to the calling task. 65 66 66 === 3) int '''_sys_nic_move'''( unsigned int nic_channel, unsigned int is_rx, void* buffer ) === 67 This function moves one 4 Kbytes container from the kernel chbuf defined by the ''nic_channel'' argument, to an user buffer defined by the ''buffer'' argument. This blocking function enforces locality and parallelism: it scans the two containers located in the same cluster as the calling task, and returns only when a full container has been found. 68 * '''nic_channel''' : selected nic channel. 67 === 3) int '''_sys_nic_move'''( unsigned int is_rx, unsigned int channel, void* buffer ) === 68 This function moves one 4 Kbytes container from the kernel chbuf defined by the ''nic_channel'' argument, to an user buffer defined by the ''buffer'' argument. This blocking function enforces locality and parallelism: it scans the two containers located in the same cluster as the calling task, and returns only when a full container has been found. 69 69 * '''is_rx''' : boolean (RX transfer if non zero) 70 * '''channel''' : RX or TX channel index. 70 71 * '''buffer''' is the user buffer virtual base address. 71 72 Returns 0 if success, returns -1 if the user buffer address is illegal, or if the NIC channel is too large, or if the timeout is elapsed. 72 73 73 === 4) int '''_sys_nic_stop'''( unsigned int is_rx ) ===74 === 4) int '''_sys_nic_stop'''( unsigned int is_rx, unsigned int channel ) === 74 75 This function stops the NIC and the CMA channels allocated to the calling task. 75 76 * '''is_rx''' : boolean (RX transfer if non zero) 77 * '''channel''' : RX or TX channel index 76 78 Returns 0 if success. Returns -1 if no NIC channel or no CMA channel allocated to the calling task. 77 79 78 === 5) int '''_sys_nic_clear'''( unsigned int is_rx ) ===80 === 5) int '''_sys_nic_clear'''( unsigned int is_rx, unsigned int channel ) === 79 81 This function reset the NIC instrumentation registers (packet counters). 80 * '''is_isr''' : boolean (RX channels if non zero) 82 * '''is_rx''' : boolean (RX channels if non zero) 83 * '''channel''' : RX or TX channel index 81 84 82 === 6) int '''_sys_nic_stats'''( unsigned int is_rx ) ===85 === 6) int '''_sys_nic_stats'''( unsigned int is_rx, unsigned int channel ) === 83 86 This function displays on TTY0 the values stored in the NIC instrumentation registers (packet counters). 84 * '''is_isr''' : boolean (RX channels if non zero) 87 * '''is_rx''' : boolean (RX channels if non zero) 88 * '''channel''' : RX or TX channel index 85 89 86 90 == FBF related syscall handlers ==