Changeset b0a26ddd in rtems


Ignore:
Timestamp:
10/20/00 13:07:29 (23 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
84ab6601
Parents:
9142bf39
Message:

2000-10-20 Joel Sherrill <joel@…>

  • include/bsp.h: Cleaned up network driver name and attach defines.
Location:
c/src/lib/libbsp/i386/pc386
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/i386/pc386/ChangeLog

    r9142bf39 rb0a26ddd  
     12000-10-20      Joel Sherrill <joel@OARcorp.com>
     2
     3        * include/bsp.h: Cleaned up network driver name and attach defines.
     4
     52000-10-20      Dmitry Kargapolov <dk@gentex.ru>
     6
     7        * ne2000/ne2000.c: Fix some errors in the driver. 
     8        1. There was no sufficient check of data in ethernet header.
     9        The code in ne_rx_daemon() was:
     10            inport_word (dport, len);
     11            ...
     12            len -= 4;
     13              ...
     14            if (len > 0)
     15              ne_read_data (sc, startaddr, len, p);
     16        Unfortunately, sometimes my NIC gave me too big len value,
     17        the result was memory override.  To fix this, I added ethernet
     18        header data checking.
     19
     20        2. The way overrides were serviced was not good.  It was complex
     21        but sometimes did not provide reliable continuing of NIC working.
     22        I had the situation of an endless loop in ne_check_status()
     23        after override processing.
     24
     25        3. There was conceptual error of porting.  The old method of
     26        overrides curing was ported from the OS-s, where override-processing
     27        did start immediately.  But RTEMS-version uses events, and cleaning
     28        of the overrides can start later.
     29
     30        I selected the way of ne2000 programming that is used
     31        in freebsd kernel (v4.0).
     32
     33        Because of both problems, incorrect data in header of raw packet
     34        and receiver override, it went through ne_reset() and fully
     35        reset the ne2000.
     36
     37        So, in summary
     38        - added detecting of the incorrect data in ethernet header;
     39        - replaced handling of receiver overrides with new scheme,
     40        via resetting of NIC, this method is used also in case of
     41        invalid header detecting.
     42
    1432000-10-18       Charles-Antoine Gauthier <charles.gauthier@nrc.ca>
    244
  • c/src/lib/libbsp/i386/pc386/include/bsp.h

    r9142bf39 rb0a26ddd  
    7373
    7474struct rtems_bsdnet_ifconfig;
    75 extern int rtems_wd_driver_attach (struct rtems_bsdnet_ifconfig *config);
    76 extern int rtems_dec21140_driver_attach (struct rtems_bsdnet_ifconfig *config);
    77 
    78 #if 0
    79 #define RTEMS_BSP_NETWORK_DRIVER_NAME "wd1"
    80 #define RTEMS_BSP_NETWORK_DRIVER_ATTACH       rtems_wd_driver_attach
    81 #endif
    82 
    83 #if 1
    84 #define RTEMS_BSP_NETWORK_DRIVER_NAME "dc1"
    85 #define RTEMS_BSP_NETWORK_DRIVER_ATTACH       rtems_dec21140_driver_attach
    86 #endif
    87 
     75
     76extern int rtems_ne_driver_attach(struct rtems_bsdnet_ifconfig *, int);
     77#define BSP_NE2000_NETWORK_DRIVER_NAME      "ne1"
     78#define BSP_NE2000_NETWORK_DRIVER_ATTACH    rtems_ne_driver_attach
     79
     80extern int rtems_wd_driver_attach(struct rtems_bsdnet_ifconfig *, int);
     81#define BSP_WD8003_NETWORK_DRIVER_NAME      "wd1"
     82#define BSP_WD8003_NETWORK_DRIVER_ATTACH    rtems_wd_driver_attach
     83
     84extern int rtems_dec21140_driver_attach(struct rtems_bsdnet_ifconfig *, int);
     85#define BSP_DEC21140_NETWORK_DRIVER_NAME    "dc1"
     86#define BSP_DEC21140_NETWORK_DRIVER_ATTACH  rtems_dec21140_driver_attach
     87
     88#define RTEMS_BSP_NETWORK_DRIVER_NAME   BSP_DEC21140_NETWORK_DRIVER_NAME
     89#define RTEMS_BSP_NETWORK_DRIVER_ATTACH BSP_DEC21140_NETWORK_DRIVER_ATTACH
    8890
    8991/*-------------------------------------------------------------------------+
Note: See TracChangeset for help on using the changeset viewer.