X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=lib%2Fnetlink-notifier.h;h=4bd90f1dcde56748f919e91b6b1cdd6f5f95471b;hb=c5cf10598f8c9f4428291e9df3ecd72a05fb1ccf;hp=e3dacef0ad126e56edb7c0d84e502fb4af1d62d4;hpb=18a237816419e6f88ab0383b43d8060914d26a9a;p=sliver-openvswitch.git diff --git a/lib/netlink-notifier.h b/lib/netlink-notifier.h index e3dacef0a..4bd90f1dc 100644 --- a/lib/netlink-notifier.h +++ b/lib/netlink-notifier.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009 Nicira Networks. + * Copyright (c) 2009 Nicira, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -23,6 +23,8 @@ #include "list.h" struct nln; +struct nln_notifier; + struct nlattr; struct ofpbuf; @@ -37,18 +39,12 @@ typedef void nln_notify_func(const void *change, void *aux); * should be parsed into 'change' as specified in nln_create(). */ typedef bool nln_parse_func(struct ofpbuf *buf, void *change); -struct nln_notifier { - struct list node; - nln_notify_func *cb; - void *aux; -}; - struct nln *nln_create(int protocol, int multicast_group, nln_parse_func *, void *change); void nln_destroy(struct nln *); -int nln_notifier_register(struct nln *, struct nln_notifier *, - nln_notify_func *, void *aux); -void nln_notifier_unregister(struct nln *, struct nln_notifier *); +struct nln_notifier *nln_notifier_create(struct nln *, nln_notify_func *, + void *aux); +void nln_notifier_destroy(struct nln_notifier *); void nln_run(struct nln *); void nln_wait(struct nln *); #endif /* netlink-notifier.h */