diff options
author | Quentin Young <qlyoung@cumulusnetworks.com> | 2017-05-02 02:37:45 +0200 |
---|---|---|
committer | Quentin Young <qlyoung@cumulusnetworks.com> | 2017-11-30 22:17:59 +0100 |
commit | 424ab01d0f69a71b865e5f2d817baea7ce263e44 (patch) | |
tree | 82f06cf1dae116f6db05cd5409475a6f8b6dcf1e /bgpd/bgp_packet.h | |
parent | bgpd: move bgp i/o to a separate source file (diff) | |
download | frr-424ab01d0f69a71b865e5f2d817baea7ce263e44.tar.xz frr-424ab01d0f69a71b865e5f2d817baea7ce263e44.zip |
bgpd: implement buffered reads
* Move and modify all network input related code to bgp_io.c
* Add a real input buffer to `struct peer`
* Move connection initialization to its own thread.c task instead of
piggybacking off of bgp_read()
* Tons of little fixups
Primary changes are in bgp_packet.[ch], bgp_io.[ch], bgp_fsm.[ch].
Changes made elsewhere are almost exclusively refactoring peer->ibuf to
peer->curr since peer->ibuf is now the true FIFO packet input buffer
while peer->curr represents the packet currently being processed by the
main pthread.
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
Diffstat (limited to 'bgpd/bgp_packet.h')
-rw-r--r-- | bgpd/bgp_packet.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/bgpd/bgp_packet.h b/bgpd/bgp_packet.h index d7080d7fb..502dbbdee 100644 --- a/bgpd/bgp_packet.h +++ b/bgpd/bgp_packet.h @@ -38,8 +38,6 @@ #define ORF_COMMON_PART_DENY 0x20 /* Packet send and receive function prototypes. */ -extern int bgp_read(struct thread *); - extern void bgp_keepalive_send(struct peer *); extern void bgp_open_send(struct peer *); extern void bgp_notify_send(struct peer *, u_int8_t, u_int8_t); @@ -68,5 +66,6 @@ extern int bgp_packet_set_size(struct stream *s); extern bool bgp_packet_writes_thread_run; extern int bgp_generate_updgrp_packets(struct thread *); +extern int bgp_process_packet(struct thread *); #endif /* _QUAGGA_BGP_PACKET_H */ |