Changeset 2be6d66b in rtems


Ignore:
Timestamp:
Jan 12, 2006, 6:13:03 AM (15 years ago)
Author:
Ralf Corsepius <ralf.corsepius@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
d623b59b
Parents:
525b1acb
Message:

2006-01-12 Ralf Corsepius <ralf.corsepius@…>

  • libchip/Makefile.am: Build libchip/network/smc91111.
  • libchip/network/smc91111.c, libchip/network/smc91111config.h: Eliminate cyg_int* crap.
Location:
c/src
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • c/src/ChangeLog

    r525b1acb r2be6d66b  
     12006-01-12      Ralf Corsepius <ralf.corsepius@rtems.org>
     2        * libchip/Makefile.am: Build libchip/network/smc91111.
     3        * libchip/network/smc91111.c, libchip/network/smc91111config.h:
     4        Eliminate cyg_int* crap.
     5
    162006-01-11      Ralf Corsepius <ralf.corsepius@rtems.org>
    27
  • c/src/libchip/Makefile.am

    r525b1acb r2be6d66b  
    3636    network/sonic.c network/if_fxp.c network/elnk.c network/open_eth.c \
    3737    network/if_dc.c
    38 # FIXME: These don't compile
    3938include_libchip_HEADERS += network/smc91111.h network/smc91111exp.h
    40 # libnetchip_a_SOURCES += network/smc91111.c network/smc91111config.h
     39libnetchip_a_SOURCES += network/smc91111.c network/smc91111config.h
    4140endif
    4241endif
  • c/src/libchip/network/smc91111.c

    r525b1acb r2be6d66b  
    6262
    6363int lan91cxx_hardware_init(struct lan91cxx_priv_data *cpd);
    64 static cyg_uint16 lan91cxx_read_phy(struct lan91cxx_priv_data *cpd,
    65                                     cyg_uint8 phyaddr, cyg_uint8 phyreg);
     64static uint16_t lan91cxx_read_phy(struct lan91cxx_priv_data *cpd,
     65                                    uint8_t phyaddr, uint8_t phyreg);
    6666static void lan91cxx_write_phy(struct lan91cxx_priv_data *cpd,
    67                                cyg_uint8 phyaddr, cyg_uint8 phyreg,
    68                                cyg_uint16 value);
     67                               uint8_t phyaddr, uint8_t phyreg,
     68                               uint16_t value);
    6969static void lan91cxx_start(struct ifnet *ifp);
    7070static void smc91111_start(struct ifnet *ifp);
     
    356356        struct ifnet *ifp = &cpd->arpcom.ac_if;
    357357#ifdef LAN91CXX_32BIT_RX
    358         cyg_uint32 val;
     358        uint32_t val;
    359359#endif
    360360
     
    487487        unsigned short *sdata = NULL;
    488488        unsigned short ints, control;
    489         cyg_uint16 packet, status;
     489        uint16_t packet, status;
    490490        dbg_prefix = ">";
    491491        DEBUG_FUNCTION();
     
    10791079        struct lan91cxx_priv_data *cpd = ifp->if_softc;
    10801080
    1081         cyg_uint16 intr;
    1082         cyg_uint16 phy_ctl;
     1081        uint16_t intr;
     1082        uint16_t phy_ctl;
    10831083        int delay;
    10841084        DEBUG_FUNCTION();
     
    14151415#endif
    14161416
    1417 static cyg_uint16
    1418 lan91cxx_read_phy(struct lan91cxx_priv_data *cpd, cyg_uint8 phyaddr,
    1419                   cyg_uint8 phyreg)
     1417static uint16_t
     1418lan91cxx_read_phy(struct lan91cxx_priv_data *cpd, uint8_t phyaddr,
     1419                  uint8_t phyreg)
    14201420{
    14211421        int i, mask, input_idx, clk_idx = 0;
    1422         cyg_uint16 mii_reg, value;
    1423         cyg_uint8 bits[64];
     1422        uint16_t mii_reg, value;
     1423        uint8_t bits[64];
    14241424
    14251425        /* 32 consecutive ones on MDO to establish sync */
     
    15041504
    15051505static void
    1506 lan91cxx_write_phy(struct lan91cxx_priv_data *cpd, cyg_uint8 phyaddr,
    1507                    cyg_uint8 phyreg, cyg_uint16 value)
     1506lan91cxx_write_phy(struct lan91cxx_priv_data *cpd, uint8_t phyaddr,
     1507                   uint8_t phyreg, uint16_t value)
    15081508{
    15091509        int i, mask, clk_idx = 0;
    1510         cyg_uint16 mii_reg;
    1511         cyg_uint8 bits[65];
     1510        uint16_t mii_reg;
     1511        uint8_t bits[65];
    15121512
    15131513        /* 32 consecutive ones on MDO to establish sync */
  • c/src/libchip/network/smc91111config.h

    r525b1acb r2be6d66b  
    4141/* ----------------- compat layer ----------------- */
    4242
    43 /* -------------------------------------------------------------------------
    44    Define basic types for using integers in memory and structures;
    45    depends on compiler defaults and CPU type. */
     43#include <rtems/stdint.h>
    4644
    47 typedef unsigned char    cyg_uint8  ;
    48 typedef   signed char    cyg_int8   ;
    49 typedef unsigned short   cyg_uint16 ;
    50 typedef   signed short   cyg_int16  ;
    51 typedef unsigned int     cyg_uint32 ;
    52 typedef   signed int     cyg_int32  ;
    53 typedef unsigned int     cyg_bool   ;
    54 
    55 typedef cyg_uint32  CYG_WORD;
    56 typedef cyg_uint8   CYG_BYTE;
    57 typedef cyg_uint16  CYG_WORD16;
    58 typedef cyg_uint32  CYG_WORD32;
     45typedef uint32_t  CYG_WORD;
     46typedef uint8_t   CYG_BYTE;
     47typedef uint16_t  CYG_WORD16;
     48typedef uint32_t  CYG_WORD32;
    5949
    6050#ifndef CYG_SWAP16
    6151# define CYG_SWAP16(_x_)                                        \
    62     ({ cyg_uint16 _x = (_x_); ((_x << 8) | (_x >> 8)); })
     52    ({ uint16_t _x = (_x_); ((_x << 8) | (_x >> 8)); })
    6353#endif
    6454
    6555#ifndef CYG_SWAP32
    6656# define CYG_SWAP32(_x_)                        \
    67     ({ cyg_uint32 _x = (_x_);                   \
     57    ({ uint32_t _x = (_x_);                   \
    6858       ((_x << 24) |                            \
    6959       ((0x0000FF00UL & _x) <<  8) |            \
Note: See TracChangeset for help on using the changeset viewer.