aboutsummaryrefslogtreecommitdiff
path: root/sys/netgraph/ng_message.h
Commit message (Collapse)AuthorAgeFilesLines
* net: clean up empty lines in .c and .h filesMateusz Guzik2020-09-011-1/+0
| | | | Notes: svn path=/head/; revision=365071
* World now builds without these defines, so eliminate them.Warner Losh2009-06-091-9/+0
| | | | | | | Approved by: julian@ Notes: svn path=/head/; revision=193812
* Retire the MALLOC and FREE macros. They are an abomination unto style(9).Dag-Erling Smørgrav2008-10-231-4/+4
| | | | | | | MFC after: 3 months Notes: svn path=/head/; revision=184205
* Make ng_ID_t fixed size, so that its maximum value is platform independent.Gleb Smirnoff2006-10-171-2/+2
| | | | | | | This will be important in future. Notes: svn path=/head/; revision=163461
* In the splnet(9) times netgraph(4) was synchronous and if a messageGleb Smirnoff2006-01-121-17/+31
| | | | | | | | | | | | | | | | | | | | | had been replied, the reply was always delivered to the originator synchronously. With introduction of netgraph item callbacks and a wait channel with mutex in ng_socket(4), we have fixed the problem with ngctl(8) returning earlier than the command has been proceeded by target node. But still ngctl(8) can return prior to the reply has arrived to its node. To fix this: - Introduce a new flag for netgraph(4) messages - NGM_HASREPLY. This flag is or'ed with message like NGM_READONLY. - In netgraph userland library if we have sent a message with NGM_HASREPLY flag, then select(2) until reply comes. - Mark appropriate generic commands with NGM_HASREPLY flag, gathering them into one enum {}. Bump generic cookie. Notes: svn path=/head/; revision=154265
* Add macro NG_COPYMESSAGE(), which allocates memory and creates aGleb Smirnoff2005-04-201-1/+22
| | | | | | | copy of given control message. Notes: svn path=/head/; revision=145324
* Increase size of arglen to uint32_t, since uint16_t proved to beGleb Smirnoff2005-02-051-7/+7
| | | | | | | | | not enough (e.g. listing 911 nodes). Bump NG_VERSION. Reviewed by: julian, archie, ru Notes: svn path=/head/; revision=141375
* /* -> /*- for license, minor formatting changesWarner Losh2005-01-071-2/+3
| | | | Notes: svn path=/head/; revision=139823
* Align netgraph message fields ready for 64-bit (and 128 bit :-) machines.Julian Elischer2004-08-201-3/+5
| | | | | | | | | | | | | requires a recompile of netgraph users. Also change the size of a field in the bluetooth code that was waiting for the next change that needed recompiles so it could piggyback its way in. Submitted by: jdp, maksim MFC after: 2 days Notes: svn path=/head/; revision=134057
* Now that mbufs are allocated using uma,Julian Elischer2004-06-071-4/+0
| | | | | | | | don't check for accidental usage of mbuf 'how' flags as they are the same thing. Notes: svn path=/head/; revision=130215
* Get rid of the deprecated *LEN constants in favour of the newHartmut Brandt2004-01-261-15/+15
| | | | | | | *SIZ constants that include the trailing \0 byte. Notes: svn path=/head/; revision=125028
* Bump the netgraph header version to 6 for the change of the nameHartmut Brandt2003-11-121-1/+1
| | | | | | | | | length definitions. Reminded by: jdp Notes: svn path=/head/; revision=122566
* Double length of node names, hook names, command strings and types. AddHartmut Brandt2003-11-121-5/+15
| | | | | | | | | | | | | defines for these constants that include the trailing NUL byte. These new constants have SIZ in their name instead of LEN. As soon as all consumers in the tree are converted to use the new defines the old defines will be put under BURN_BRIDGES. Reviewed by: archie, julian, ru Approved by: re (in principle) Notes: svn path=/head/; revision=122548
* Use a single style of multiple inclusion protection for Netgraph headers.Ruslan Ermilov2003-11-111-1/+1
| | | | | | | Reviewed by: archie, harti, emax Notes: svn path=/head/; revision=122481
* Remove a gcc-ism: declaring a variable array at the end of a structureHartmut Brandt2003-10-221-4/+4
| | | | | | | | as [0] and replace it with the ISO way of writing []. This has caused warnings with WARNS=6. Notes: svn path=/head/; revision=121325
* KASSERT that NG_MKMESSAGE() is not called with mbuf flags.Poul-Henning Kamp2003-04-181-0/+4
| | | | Notes: svn path=/head/; revision=113663
* Fix GCC warnings caused by initializing a zero length array. In the process,Archie Cobbs2002-05-311-42/+14
| | | | | | | | | | simply things a bit by getting rid of 'struct ng_parse_struct_info' which was useless because it only contained one field. MFC after: 2 weeks Notes: svn path=/head/; revision=97685
* Clean up reference counting with relation to queued packets and the worklist,Julian Elischer2001-02-011-5/+5
| | | | | | | | | and while I'm there, clean up the worklist insertion and removal. Inspired by: Harti Brandt <brandt@fokus.gmd.de> Notes: svn path=/head/; revision=71902
* Implement direct support for semipersistant nodes.Julian Elischer2001-01-301-2/+1
| | | | | | | | | | | | | | | | (e.g. ethernet nodes are persistent until you rip out the hardware) Use this support in the ethernet and sample nodes. Add some more abstraction on the 'item's so that node and hook reference counting can be checked easier. Slight man page correction. Make pppoe type dependent on ethernet type. Clean up node shutdown a little. Move a mutex from MTX_SPIN to MTX_DEF (oops) Fix small ref-counting bug. remove warning on one2many type. Notes: svn path=/head/; revision=71849
* Rewrite of netgraph to start getting ready for SMP.Julian Elischer2001-01-061-22/+25
| | | | | | | | | | | This version is functional and is aproaching solid.. notice I said APROACHING. There are many node types I cannot test I have tested: echo hole ppp socket vjc iface tee bpf async tty The rest compile and "Look" right. More changes to follow. DEBUGGING is enabled in this code to help if people have problems. Notes: svn path=/head/; revision=70700
* Divorce the kernel binary ABI version number from the messageJulian Elischer2000-12-181-2/+7
| | | | | | | | | | | | format version number. (userland programs should not need to be recompiled when the netgraph kernel internal ABI is changed. Also fix modules that don;t handle the fact that a caller may not supply a return message pointer. (benign at the moment because the calling code checks, but that will change) Notes: svn path=/head/; revision=70159
* Reviewed by: Archie@freebsd.orgJulian Elischer2000-12-121-1/+92
| | | | | | | | | | | | | | | | This clears out my outstanding netgraph changes. There is a netgraph change of design in the offing and this is to some extent a superset of soem of the new functionality and some of the old functionality that may be removed. This code works as before, but allows some new features that I want to work with and evaluate. It is the basis for a version of netgraph with integral locking for SMP use. This is running on my test machine with no new problems :-) Notes: svn path=/head/; revision=69922
* Add the use of M_ZERO to netgraph.David Malone2000-11-181-4/+2
| | | | | | | | | | Submitted by: josh@zipperup.org Submitted by: Robert Drehmel <robd@gmx.net> Submitted by: archie Approved by: archie Notes: svn path=/head/; revision=68876
* Since neither archie nor I work at Whistle any more, change our emailJulian Elischer2000-10-241-1/+1
| | | | | | | | | addresses to be the more usefu @freebsd.org ones so we can keep getting bug-reports. - man pages to follow.. Notes: svn path=/head/; revision=67506
* Take advantage of the new unsigned and hex integer types.Archie Cobbs2000-08-101-12/+12
| | | | Notes: svn path=/head/; revision=64508
* Experiemntal ascii based device configuration mechanism.Poul-Henning Kamp2000-07-031-0/+1
| | | | | | | This may or may not survive, decision will be made well before 5.0-R Notes: svn path=/head/; revision=62471
* Use 'type_name' structure field instead of 'typename', which isArchie Cobbs2000-05-011-1/+1
| | | | | | | | | a C++ reserved work. Add a ng_copy_meta() function. Notes: svn path=/head/; revision=59879
* Two simple changes to the kernel internal API for netgraph modules,Julian Elischer2000-04-281-1/+1
| | | | | | | | | | to support future work in flow-control and 'packet reject/replace' processing modes. reviewed by: phk, archie Notes: svn path=/head/; revision=59728
* Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL"Peter Wemm1999-12-291-2/+2
| | | | | | | | | is an application space macro and the applications are supposed to be free to use it as they please (but cannot). This is consistant with the other BSD's who made this change quite some time ago. More commits to come. Notes: svn path=/head/; revision=55205
* Add two new generic control messages, NGM_ASCII2BINARY andArchie Cobbs1999-11-301-20/+139
| | | | | | | | | | | | | | | | | | | | | | | | | | NGM_BINARY2ASCII, which convert control messages to ASCII and back. This allows control messages to be sent and received in ASCII form using ngctl(8), which makes ngctl a lot more useful. This also allows all the type-specific debugging code in libnetgraph to go away -- instead, we just ask the node itself to do the ASCII translation for us. Currently, all generic control messages are supported, as well as messages associated with the following node types: async, cisco, ksocket, and ppp. See /usr/share/examples/netgraph/ngctl for an example of using this. Also give ngctl(8) the ability to print out incoming data and control messages at any time. Eventually nghook(8) may be subsumed. Several other misc. bug fixes. Reviewed by: julian Notes: svn path=/head/; revision=53913
* Start making the contents of the generic framework opaque to the nodes.Julian Elischer1999-11-011-1/+2
| | | | | | | | This step: IDs are no-longer the address of the node. Reviewd by: Archie@freebsd.org Notes: svn path=/head/; revision=52722
* Whistle's Netgraph link-layer (sometimes more) networking infrastructure.Julian Elischer1999-10-211-0/+209
Been in production for 3 years now. Gives Instant Frame relay to if_sr and if_ar drivers, and PPPOE support soon. See: ftp://ftp.whistle.com/pub/archie/netgraph/index.html for on-line manual pages. Reviewed by: Doug Rabson (dfr@freebsd.org) Obtained from: Whistle CVS tree Notes: svn path=/head/; revision=52419