/* Copyright 2011-2014 Autronica Fire and Security AS
 *
 * This program is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License as published by the Free
 * Software Foundation; either version 2 of the License, or (at your option)
 * any later version.
 *
 * Author(s):
 *	2011-2014 Arvid Brodin, arvid.brodin@alten.se
 */

#ifndef __HSR_FRAMEREG_H
#define __HSR_FRAMEREG_H

#include "hsr_main.h"

struct hsr_node;

struct hsr_node *hsr_add_node(struct list_head *node_db, unsigned char addr[],
			      u16 seq_out);
struct hsr_node *hsr_get_node(struct list_head *node_db, struct sk_buff *skb,
			      bool is_sup);
void hsr_handle_sup_frame(struct sk_buff *skb, struct hsr_node *node_curr,
			  struct hsr_port *port);
bool hsr_addr_is_self(struct hsr_priv *hsr, unsigned char *addr);

void hsr_addr_subst_source(struct hsr_node *node, struct sk_buff *skb);
void hsr_addr_subst_dest(struct hsr_node *node_src, struct sk_buff *skb,
			 struct hsr_port *port);

void hsr_register_frame_in(struct hsr_node *node, struct hsr_port *port,
			   u16 sequence_nr);
int hsr_register_frame_out(struct hsr_port *port, struct hsr_node *node,
			   u16 sequence_nr);

void hsr_prune_nodes(unsigned long data);

int hsr_create_self_node(struct list_head *self_node_db,
			 unsigned char addr_a[ETH_ALEN],
			 unsigned char addr_b[ETH_ALEN]);

void *hsr_get_next_node(struct hsr_priv *hsr, void *_pos,
			unsigned char addr[ETH_ALEN]);

int hsr_get_node_data(struct hsr_priv *hsr,
		      const unsigned char *addr,
		      unsigned char addr_b[ETH_ALEN],
		      unsigned int *addr_b_ifindex,
		      int *if1_age,
		      u16 *if1_seq,
		      int *if2_age,
		      u16 *if2_seq);

#endif /* __HSR_FRAMEREG_H */
'>log</a><a href='/cgit.cgi/linux/net-next.git/tree/net/x25/x25_in.c?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>tree</a><a class='active' href='/cgit.cgi/linux/net-next.git/commit/net/x25/x25_in.c?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>commit</a><a href='/cgit.cgi/linux/net-next.git/diff/net/x25/x25_in.c?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>diff</a></td><td class='form'><form class='right' method='get' action='/cgit.cgi/linux/net-next.git/log/net/x25/x25_in.c'>
<input type='hidden' name='id' value='3ddc76dfc786cc6f87852693227fb0b1f124f807'/><select name='qt'>
<option value='grep'>log msg</option>
<option value='author'>author</option>
<option value='committer'>committer</option>
<option value='range'>range</option>
</select>
<input class='txt' type='search' size='10' name='q' value=''/>
<input type='submit' value='search'/>
</form>
</td></tr></table>
<div class='path'>path: <a href='/cgit.cgi/linux/net-next.git/commit/?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>root</a>/<a href='/cgit.cgi/linux/net-next.git/commit/net?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>net</a>/<a href='/cgit.cgi/linux/net-next.git/commit/net/x25?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>x25</a>/<a href='/cgit.cgi/linux/net-next.git/commit/net/x25/x25_in.c?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>x25_in.c</a></div><div class='content'><div class='cgit-panel'><b>diff options</b><form method='get'><input type='hidden' name='id' value='3ddc76dfc786cc6f87852693227fb0b1f124f807'/><table><tr><td colspan='2'/></tr><tr><td class='label'>context:</td><td class='ctrl'><select name='context' onchange='this.form.submit();'><option value='1'>1</option><option value='2'>2</option><option value='3' selected='selected'>3</option><option value='4'>4</option><option value='5'>5</option><option value='6'>6</option><option value='7'>7</option><option value='8'>8</option><option value='9'>9</option><option value='10'>10</option><option value='15'>15</option><option value='20'>20</option><option value='25'>25</option><option value='30'>30</option><option value='35'>35</option><option value='40'>40</option></select></td></tr><tr><td class='label'>space:</td><td class='ctrl'><select name='ignorews' onchange='this.form.submit();'><option value='0' selected='selected'>include</option><option value='1'>ignore</option></select></td></tr><tr><td class='label'>mode:</td><td class='ctrl'><select name='dt' onchange='this.form.submit();'><option value='0' selected='selected'>unified</option><option value='1'>ssdiff</option><option value='2'>stat only</option></select></td></tr><tr><td/><td class='ctrl'><noscript><input type='submit' value='reload'/></noscript></td></tr></table></form></div><table summary='commit info' class='commit-info'>
<tr><th>author</th><td>Linus Torvalds &lt;torvalds@linux-foundation.org&gt;</td><td class='right'>2016-12-25 14:30:04 -0800</td></tr>
<tr><th>committer</th><td>Linus Torvalds &lt;torvalds@linux-foundation.org&gt;</td><td class='right'>2016-12-25 14:30:04 -0800</td></tr>
<tr><th>commit</th><td colspan='2' class='oid'><a href='/cgit.cgi/linux/net-next.git/commit/net/x25/x25_in.c?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>3ddc76dfc786cc6f87852693227fb0b1f124f807</a> (<a href='/cgit.cgi/linux/net-next.git/patch/net/x25/x25_in.c?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>patch</a>)</td></tr>
<tr><th>tree</th><td colspan='2' class='oid'><a href='/cgit.cgi/linux/net-next.git/tree/?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>8192b4721e05cf6823087f9696db8c0c8f144b02</a> /<a href='/cgit.cgi/linux/net-next.git/tree/net/x25/x25_in.c?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>net/x25/x25_in.c</a></td></tr>
<tr><th>parent</th><td colspan='2' class='oid'><a href='/cgit.cgi/linux/net-next.git/commit/net/x25/x25_in.c?id=b272f732f888d4cf43c943a40c9aaa836f9b7431'>b272f732f888d4cf43c943a40c9aaa836f9b7431</a> (<a href='/cgit.cgi/linux/net-next.git/diff/net/x25/x25_in.c?id=3ddc76dfc786cc6f87852693227fb0b1f124f807&amp;id2=b272f732f888d4cf43c943a40c9aaa836f9b7431'>diff</a>)</td></tr><tr><th>parent</th><td colspan='2' class='oid'><a href='/cgit.cgi/linux/net-next.git/commit/net/x25/x25_in.c?id=1f3a8e49d8f28f498b8694464623ac20aebfe62a'>1f3a8e49d8f28f498b8694464623ac20aebfe62a</a> (<a href='/cgit.cgi/linux/net-next.git/diff/net/x25/x25_in.c?id=3ddc76dfc786cc6f87852693227fb0b1f124f807&amp;id2=1f3a8e49d8f28f498b8694464623ac20aebfe62a'>diff</a>)</td></tr></table>
<div class='commit-subject'>Merge branch 'timers-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip</div><div class='commit-msg'>Pull timer type cleanups from Thomas Gleixner:
 "This series does a tree wide cleanup of types related to
  timers/timekeeping.

   - Get rid of cycles_t and use a plain u64. The type is not really
     helpful and caused more confusion than clarity

   - Get rid of the ktime union. The union has become useless as we use
     the scalar nanoseconds storage unconditionally now. The 32bit
     timespec alike storage got removed due to the Y2038 limitations
     some time ago.

     That leaves the odd union access around for no reason. Clean it up.

  Both changes have been done with coccinelle and a small amount of
  manual mopping up"

* 'timers-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  ktime: Get rid of ktime_equal()
  ktime: Cleanup ktime_set() usage
  ktime: Get rid of the union
  clocksource: Use a plain u64 instead of cycle_t
</div><div class='diffstat-header'><a href='/cgit.cgi/linux/net-next.git/diff/?id=3ddc76dfc786cc6f87852693227fb0b1f124f807'>Diffstat</a> (limited to 'net/x25/x25_in.c')</div><table summary='diffstat' class='diffstat'>