Hi rishi,

here are the rest of my comments:

trill.c:

178:
is the tsp->ts_link->bl_mh check necessary?
seems like a ts_link should always have a non-NULL bl_mh.

440:
could use sizeof (struct ether_vlan_extinfo).

888:
why not just 'return' here instead of creating a wrong kstat?

1099:
is it possible to bound this to a reasonable number like 1Mb?
(to avoid erroneously consuming too much memory)

1116:
what if tn_tsp is NULL?
what if the same nick is added twice? I don't see duplicate checks.

1148:
do you need to check that the flags in the array are valid before
passing to bridge_trill_setvlans()?

1179:
this should return an error if the nick doesn't exist.

1195:
could use VALID_NICK to check treeroot.

1525:
it may be better to do the privilege check at trill_create(). this
ensures non-privileged users cannot use AF_TRILL.

270,1511:
do you need to increment tks_drops for these error cases?
this is done in 567.

1051,1069,1246:
could use VALID_NICK for these checks.
also, it may be safer to change VALID_NICK to
((n) > RBRIDGE_NICKNAME_NONE && (n) < RBRIDGE_NICKNAME_MAX)


eric
_______________________________________________
networking-discuss mailing list
[email protected]

Reply via email to