Changes between Version 20 and Version 21 of kernel_syscalls


Ignore:
Timestamp:
Nov 26, 2014, 6:36:59 PM (10 years ago)
Author:
alain
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • kernel_syscalls

    v20 v21  
    5656This function allocates a private NIC_RX or NIC_TX channel, the associated chbuf, and a private CMA channel to the calling task. It register these channel indexes in the task context.
    5757 * '''is_isr''' : boolean (RX transfer if non zero)
    58 Returns 0 if success. Return -1 if no NIC channel available, or if no CMA channel available.
     58Returns the NIC channel index if success. Return -1 if no NIC channel available, or if no CMA channel available.
    5959
    6060=== 2) int '''_sys_nic_start'''( unsigned int is_rx ) ===
    6161This function starts the NIC channel allocated to the calling task, and starts the CMA transfer between the internal NIC chbuf and the kernel chbuf allocated to the calling task.
    6262 * '''is_isr''' : boolean (RX transfer if non zero)
    63  * '''mac4''' : 32 LSB bits of the MAC address
    64  * '''mac4''' : 16 MSB bits of the MAC address
    6563Returns 0 if success. Returns -1 if no NIC channel or no CMA channel allocated to the calling task.
    6664
    67 === 3) int '''_sys_nic_move'''(  unsigned int is_rx,  void* buffer ) ===
    68 This function moves one 4kbytes container between the kernel chbuf allocated to the calling task, and an user buffer.
     65=== 3) int '''_sys_nic_move'''(  unsigned int nic_channel,  unsigned int is_rx,  void* buffer ) ===
     66This function moves one 4kbytes container between the kernel chbuf defined by the nic_channel argument, and an user buffer.
     67 * '''nic_channel''' : selected nic_chbuf channel.
    6968 * '''is_isr''' : boolean (RX transfer if non zero)
    7069 * '''buffer''' is the user buffer virtual base address.
     
    7271It is blocking if the kernel chbuf is empty (for an RX transfer) or full (for a TX transfer). The bloking situation
    7372is bounded by a timeout defined by the GIET_NIC_TIMEOUT parameter defined in the ''giet_config.h'' file.
    74 Returns 0 if success, returns -1 if the user buffer address is illegal, or if there is no  NIC_RX channel allocated to the calling task, or if the timeout is elapsed.
     73Returns 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.
    7574
    7675=== 4) int '''_sys_nic_stop'''( unsigned int is_rx ) ===