Changeset 803ea87 for lib/libtrace.h


Ignore:
Timestamp:
11/01/05 14:51:44 (16 years ago)
Author:
Shane Alcock <salcock@…>
Branches:
4.0.1-hotfixes, cachetimestamps, develop, dpdk-ndag, etsilive, getfragoff, help, libtrace4, master, ndag_format, pfring, rc-4.0.1, rc-4.0.2, rc-4.0.3, rc-4.0.4, ringdecrementfix, ringperformance, ringtimestampfixes
Children:
44c6c85
Parents:
77509e9
Message:

Removed rt_protocol entirely as it was becoming a real nuisance.
Critical rt_protocol components have been moved to libtrace.h

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/libtrace.h

    r8013711 r803ea87  
    3131#ifndef LIBTRACE_H
    3232#define LIBTRACE_H
    33 
    34 #include <sys/types.h>
    35 #include <netinet/in.h>
    36 #include "rt_protocol.h"
    37 /** API version as 2 byte hex digits, eg 0xXXYYZZ */
    38 #define LIBTRACE_API_VERSION 0x020016  /* 2.0.22 */
    39 
    40 #ifdef __cplusplus
    41 extern "C" {
    42 #endif
    43 
    44 /* Function does not depend on anything but its
    45  * parameters, used to hint gcc's optimisations
    46  */
    47 #if __GNUC__ >= 3
    48 #  define SIMPLE_FUNCTION __attribute__((pure))
    49 #else
    50 #  define SIMPLE_FUNCTION
    51 #endif
    52        
    5333
    5434/** @file
     
    7656 */
    7757
    78 #define COLLECTOR_PORT 3435
     58#include <sys/types.h>
     59#include <netinet/in.h>
     60/** API version as 2 byte hex digits, eg 0xXXYYZZ */
     61#define LIBTRACE_API_VERSION 0x020017  /* 2.0.23 */
     62
     63#ifdef __cplusplus
     64extern "C" {
     65#endif
     66
     67/* Function does not depend on anything but its
     68 * parameters, used to hint gcc's optimisations
     69 */
     70#if __GNUC__ >= 3
     71#  define SIMPLE_FUNCTION __attribute__((pure))
     72#else
     73#  define SIMPLE_FUNCTION
     74#endif
     75       
     76#define RT_DATA 1
     77#define RT_MSG 2
    7978
    8079       
     
    9594        char buffer[LIBTRACE_PACKET_BUFSIZE];
    9695        size_t size;
    97         rt_status_t status;
    98 };
     96        struct {
     97                uint8_t type;
     98                uint8_t reserved;
     99                uint16_t message;
     100        } status;
     101} __attribute__ ((packed));
    99102                     
    100103
Note: See TracChangeset for help on using the changeset viewer.