Broadcom SDK and wireless driver: another attempt to update to ver. 5.10.147.0
[tomato.git] / release / src-rt / include / emf / igs / igsc_sdb.h
blob891779b00c05019d55f61f1ca40315983cdd6c56
1 /*
2 * Copyright (C) 2009, Broadcom Corporation
3 * All Rights Reserved.
4 *
5 * This is UNPUBLISHED PROPRIETARY SOURCE CODE of Broadcom Corporation;
6 * the contents of this file may not be disclosed to third parties, copied
7 * or duplicated in any form, in whole or in part, without the prior
8 * written permission of Broadcom Corporation.
10 * $Id: igsc_sdb.h,v 1.2 2008/08/12 17:50:33 Exp $
13 #ifndef _IGSC_SDB_H_
14 #define _IGSC_SDB_H_
16 #define IGSDB_MGRP_HASH(m) ((((m) >> 24) + ((m) >> 16) + \
17 ((m) >> 8) + ((m) & 0xff)) & 7)
20 * Group entry of IGSDB
22 typedef struct igsc_mgrp
24 clist_head_t mgrp_hlist; /* Multicast Groups hash list */
25 uint32 mgrp_ip; /* Multicast Group IP Address */
26 clist_head_t mh_head; /* List head of group members */
27 clist_head_t mi_head; /* List head of interfaces */
28 igsc_info_t *igsc_info; /* IGSC instance data */
29 } igsc_mgrp_t;
32 * Interface entry of IGSDB
34 typedef struct igsc_mi
36 clist_head_t mi_list; /* Multicast i/f list prev and next */
37 void *mi_ifp; /* Interface pointer */
38 int32 mi_ref; /* Ref count of hosts on the i/f */
39 } igsc_mi_t;
42 * Host entry of IGSDB
44 typedef struct igsc_mh
46 clist_head_t mh_list; /* Group members list prev and next */
47 uint32 mh_ip; /* Unicast IP address of host */
48 igsc_mgrp_t *mh_mgrp; /* Multicast forwarding entry for the
49 * group
51 osl_timer_t *mgrp_timer; /* Group Membership Interval timer */
52 igsc_mi_t *mh_mi; /* Interface connected to host */
53 } igsc_mh_t;
56 * Prototypes
58 int32 igsc_sdb_member_add(igsc_info_t *igsc_info, void *ifp, uint32 mgrp_ip,
59 uint32 mh_ip);
60 int32 igsc_sdb_member_del(igsc_info_t *igsc_info, void *ifp, uint32 mgrp_ip,
61 uint32 mh_ip);
62 void igsc_sdb_init(igsc_info_t *igsc_info);
64 #endif /* _IGSC_SDB_H_ */