#ifndef TRAFGEN_PROTO_I_H #define TRAFGEN_PROTO_I_H #include #include #include struct proto_ctx { const char *dev; }; enum proto_id { PROTO_NONE, PROTO_ETH, PROTO_ARP, PROTO_IP4, PROTO_IP6, PROTO_UDP, PROTO_TCP, }; enum proto_layer { PROTO_L0, /* invalid layer */ PROTO_L2, PROTO_L3, PROTO_L4, }; struct proto_field { uint32_t id; size_t len; uint32_t shift; uint32_t mask; uint16_t offset; bool is_set; uint16_t pkt_offset; }; struct proto_hdr { enum proto_id id; enum proto_layer layer; struct proto_hdr *next; struct proto_ctx *ctx; uint16_t pkt_offset; struct proto_field *fields; size_t fields_count; void (*header_init)(struct proto_hdr *hdr); void (*header_finish)(struct proto_hdr *hdr); void (*packet_finish)(struct proto_hdr *hdr); }; extern void protos_init(const char *dev); extern void proto_header_register(struct proto_hdr *hdr); extern void proto_header_init(enum proto_id pid); extern void proto_header_finish(struct proto_hdr *hdr); extern void proto_packet_finish(void); extern void proto_lower_default_add(enum proto_id pid); extern struct proto_hdr *proto_current_header(void); extern struct proto_hdr *proto_lower_header(struct proto_hdr *hdr); extern uint8_t *proto_header_ptr(struct proto_hdr *hdr); extern void proto_header_fields_add(struct proto_hdr *hdr, struct proto_field *fields, size_t count); extern bool proto_field_is_set(struct proto_hdr *hdr, uint32_t fid); extern void proto_field_set_bytes(struct proto_hdr *hdr, uint32_t fid, uint8_t *bytes); extern void proto_field_set_u8(struct proto_hdr *hdr, uint32_t fid, uint8_t val); extern uint8_t proto_field_get_u8(struct proto_hdr *hdr, uint32_t fid); extern void proto_field_set_u16(struct proto_hdr *hdr, uint32_t fid, uint16_t val); extern uint16_t proto_field_get_u16(struct proto_hdr *hdr, uint32_t fid); extern void proto_field_set_u32(struct proto_hdr *hdr, uint32_t fid, uint32_t val); extern uint32_t proto_field_get_u32(struct proto_hdr *hdr, uint32_t fid); extern void proto_field_set_default_bytes(struct proto_hdr *hdr, uint32_t fid, uint8_t *bytes); extern void proto_field_set_default_u8(struct proto_hdr *hdr, uint32_t fid, uint8_t val); extern void proto_field_set_default_u16(struct proto_hdr *hdr, uint32_t fid, uint16_t val); extern void proto_field_set_default_u32(struct proto_hdr *hdr, uint32_t fid, uint32_t val); extern void proto_field_set_be16(struct proto_hdr *hdr, uint32_t fid, uint16_t val); extern void proto_field_set_be32(struct proto_hdr *hdr, uint32_t fid, uint32_t val); extern void proto_field_set_default_be16(struct proto_hdr *hdr, uint32_t fid, uint16_t val); extern void proto_field_set_default_be32(struct proto_hdr *hdr, uint32_t fid, uint32_t val); extern void proto_field_set_dev_mac(struct proto_hdr *hdr, uint32_t fid); extern void proto_field_set_default_dev_mac(struct proto_hdr *hdr, uint32_t fid); #endif /* TRAFGEN_PROTO_I_H */ fd749abab492ae02452cf675f7bc146814955'>drivers
diff options
context:
space:
mode:
authorJohan Hovold <johan@hovoldconsulting.com>2016-07-19 17:21:27 +0200
committerGreg Kroah-Hartman <gregkh@google.com>2016-07-19 18:27:35 -0700
commit042fd749abab492ae02452cf675f7bc146814955 (patch)
treec6af2bd1807bfd888816e8ebde4d9e3745acf0e7 /drivers
parentd53cc1c37e5a4006fb23df8e54dc4a50e01732d9 (diff)
greybus: connection: drop the svc quiescing operation
Connection tear down is being reworked, and the SVC quiescing operation is going away. Let's remove this operation now along with the coupled second ping from our intermediate tear down implementation. This both avoids unnecessary noise in the logs resulting from the fact that the SVC side of the quiescing operation was never merged, and speeds up connection tear down slightly. Testing done: Tested on EVT2 using runtime PM. Signed-off-by: Johan Hovold <johan@hovoldconsulting.com> Reviewed-by: Viresh Kumar <viresh.kumar@linaro.org> Acked-by: Sandeep Patil <sspatil@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/staging/greybus/connection.c19
-rw-r--r--drivers/staging/greybus/greybus_protocols.h12
-rw-r--r--drivers/staging/greybus/svc.c31
-rw-r--r--drivers/staging/greybus/svc.h2
4 files changed, 0 insertions, 64 deletions
diff --git a/drivers/staging/greybus/connection.c b/drivers/staging/greybus/connection.c