2
0
mirror of https://github.com/openvswitch/ovs synced 2025-10-17 14:28:02 +00:00
Commit Graph

12 Commits

Author SHA1 Message Date
Ben Pfaff
a46c577af5 ofpbuf: New function ofpbuf_clone_data_with_headroom().
This new function is a simple helper that creates a new ofpbuf with some
initial contents plus a caller-specified amount of headroom.

This will be used in upcoming commits.

Acked-by: Jesse Gross <jesse@nicira.com>
2011-01-27 09:26:05 -08:00
Ben Pfaff
31ac1e590b ofpbuf: New function ofpbuf_use_stack().
This new function is useful in a situation where a small stack-allocated
buffer is usually appropriate but occasionally it must be expanded.

Acked-by: Jesse Gross <jesse@nicira.com>
2011-01-27 09:26:05 -08:00
Ben Pfaff
78090f6300 ofpbuf: New function ofpbuf_put_hex().
This commit converts nx_match_from_string() to use this new function.  The
new function will also have another user in an upcoming commit.
2010-12-09 14:51:31 -08:00
Ben Pfaff
0bc9407dbb ofpbuf: New function ofpbuf_use_const().
This is a code cleanup.

Suggested-by: Justin Pettit <jpettit@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2010-12-07 13:44:17 -08:00
Ben Pfaff
b3907fbc6c queue: Get rid of ovs_queue data structure.
ovs_queue doesn't seem very useful; it's just a singly-linked list.  It's
more generally useful to use a general-purpose "struct list" for lists of
packets, so this commit adds such a member to "struct ofpbuf" and shifts
the existing users to use it.
2010-12-06 10:03:31 -08:00
Ben Pfaff
68efcbec41 ofpbuf: Add ofpbuf_new_with_headroom(), ofpbuf_clone_with_headroom().
These new functions simplify an increasingly common usage pattern.

Suggested-by: Jesse Gross <jesse@nicira.com>
2010-09-01 12:55:50 -07:00
Ben Pfaff
30f07f1a5e ofpbuf: New function ofpbuf_push_zeros(). 2010-04-26 14:57:49 -07:00
Ben Pfaff
0ab8e15fd7 ofpbuf: New function ofpbuf_to_string().
Useful for debugging.

From Jean Tourrilhes <jt@hpl.hp.com>.
2010-02-12 13:55:46 -08:00
Ben Pfaff
5019f688d4 ofpbuf: Mark ofpbuf_headroom(), ofpbuf_tailroom() parameters const. 2010-02-12 13:55:46 -08:00
Ben Pfaff
d45e9c65c6 ofpbuf: Rename ofpbuf "private" member for C++ header compatibility.
From partner.
2010-02-01 09:46:31 -08:00
Ben Pfaff
a14bc59fb8 Update primary code license to Apache 2.0. 2009-06-15 15:11:30 -07:00
Ben Pfaff
064af42167 Import from old repository commit 61ef2b42a9c4ba8e1600f15bb0236765edc2ad45. 2009-07-08 13:19:16 -07:00