MOD aaa-12 桥模型代码上传

SOL  桥模型代码上传
修改人:zhangliang
检视人:zhangliang
This commit is contained in:
zhanglianghy 2019-08-02 17:47:38 +08:00
parent 5bc5658864
commit 5ea4f283da
9 changed files with 33 additions and 74 deletions

View File

@ -20,8 +20,6 @@ typedef enum {
BR_EVENT_INVALID
} BR_EVENT_TYPE;
typedef int (*BR_EVENT_FUNC)(BR_EVENT_TYPE event_type, br_event_t event_arg);
/************************************************************/
/* 结构体 */
/************************************************************/
@ -109,6 +107,8 @@ struct _br_fdb_status{
};
typedef struct _br_fdb_status br_fdb_status_t;
typedef int (*BR_EVENT_FUNC)(BR_EVENT_TYPE event_type, br_event_t event_arg);
/* **********************************************************/
/* 提供给其他模块调用的函数 */
/************************************************************/

View File

@ -4,15 +4,15 @@
#include <stdlib.h>
#include <errno.h>
#include <unistd.h>
#include "list.h"
#include "configm.h"
#include "brconfig.h"
#include "rpc.h"
#include "parsefile.h"
#include "libbridge.h"
#include "brnetlink.h"
#include "parsefile.h"
#include "list.h"
#include "libbridge.h"
#ifndef DESC("事件通知函数")
struct br_event_head_t br_event_tbl = {.lock = 0, .init = false};

View File

@ -12,6 +12,7 @@
#include <net/if.h>
#include "brnetlink.h"
#include "rpc_common.h"
#define BR_NLMSG_TAIL(nmsg) \
((struct rtattr *) (((void *) (nmsg)) + NLMSG_ALIGN((nmsg)->nlmsg_len)))

View File

@ -1,79 +1,80 @@
/* libbridge/config.h. Generated from config.h.in by configure. */
/* libbridge/config.h.in. Generated from configure.in by autoheader. */
/* Define to 1 if you have the `gethostname' function. */
#undef HAVE_GETHOSTNAME
#define HAVE_GETHOSTNAME 1
/* Define to 1 if you have the `if_indextoname' function. */
#undef HAVE_IF_INDEXTONAME
#define HAVE_IF_INDEXTONAME 1
/* Define to 1 if you have the `if_nametoindex' function. */
#undef HAVE_IF_NAMETOINDEX
#define HAVE_IF_NAMETOINDEX 1
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
#define HAVE_INTTYPES_H 1
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
#define HAVE_MEMORY_H 1
/* Define to 1 if you have the `socket' function. */
#undef HAVE_SOCKET
#define HAVE_SOCKET 1
/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H
#define HAVE_STDINT_H 1
/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H
#define HAVE_STDLIB_H 1
/* Define to 1 if you have the `strdup' function. */
#undef HAVE_STRDUP
#define HAVE_STRDUP 1
/* Define to 1 if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H
#define HAVE_STRINGS_H 1
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
#define HAVE_STRING_H 1
/* Define to 1 if you have the <sys/ioctl.h> header file. */
#undef HAVE_SYS_IOCTL_H
#define HAVE_SYS_IOCTL_H 1
/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
#define HAVE_SYS_STAT_H 1
/* Define to 1 if you have the <sys/time.h> header file. */
#undef HAVE_SYS_TIME_H
#define HAVE_SYS_TIME_H 1
/* Define to 1 if you have the <sys/types.h> header file. */
#undef HAVE_SYS_TYPES_H
#define HAVE_SYS_TYPES_H 1
/* Define to 1 if you have the `uname' function. */
#undef HAVE_UNAME
#define HAVE_UNAME 1
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
#define HAVE_UNISTD_H 1
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
#define PACKAGE_BUGREPORT ""
/* Define to the full name of this package. */
#undef PACKAGE_NAME
#define PACKAGE_NAME "bridge-utils"
/* Define to the full name and version of this package. */
#undef PACKAGE_STRING
#define PACKAGE_STRING "bridge-utils 1.6"
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
#define PACKAGE_TARNAME "bridge-utils"
/* Define to the home page for this package. */
#undef PACKAGE_URL
#define PACKAGE_URL ""
/* Define to the version of this package. */
#undef PACKAGE_VERSION
#define PACKAGE_VERSION "1.6"
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
#define STDC_HEADERS 1
/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
#undef TIME_WITH_SYS_TIME
#define TIME_WITH_SYS_TIME 1
/* Define to empty if `const' does not conform to ANSI C. */
#undef const
/* #undef const */

View File

@ -19,7 +19,7 @@
#ifndef _LIBBRIDGE_PRIVATE_H
#define _LIBBRIDGE_PRIVATE_H
#include "config.h"
#include "libbrconfig.h.h"
#include <linux/sockios.h>
#include <sys/time.h>

View File

@ -1,2 +0,0 @@
config.h
stamp-h1

View File

@ -1,41 +0,0 @@
KERNEL_HEADERS=-I@KERNEL_HEADERS@
AR=ar
RANLIB=@RANLIB@
CC=@CC@
CFLAGS = -Wall -g $(KERNEL_HEADERS)
prefix=@prefix@
exec_prefix=@exec_prefix@
includedir=@includedir@
libdir=@libdir@
libbridge_SOURCES= \
libbridge_devif.c \
libbridge_if.c \
libbridge_init.c \
libbridge_misc.c
libbridge_OBJECTS=$(libbridge_SOURCES:.c=.o)
all: libbridge.a
# At present there is no need for a bridge-utils-devel package
install:
clean:
rm -f *.o libbridge.a
libbridge.a: $(libbridge_OBJECTS)
$(AR) rcs $@ $(libbridge_OBJECTS)
$(RANLIB) $@
%.o: %.c libbridge.h libbridge_private.h
$(CC) $(CFLAGS) $(INCLUDE) -c $<
libbridge_compat.o: libbridge_compat.c if_index.c
$(CC) $(CFLAGS) -c libbridge_compat.c