tech-net archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Restructuring ARP cache
On Tue, Aug 25, 2015 at 2:12 PM, Christos Zoulas <christos%zoulas.com@localhost> wrote:
> On Aug 24, 6:41pm, ozaki-r%netbsd.org@localhost (Ryota Ozaki) wrote:
> -- Subject: Re: Restructuring ARP cache
>
> | BTW, should I KNF the patch before committing whether they would
> | change soon?
>
> I think leave it as it is; it is a minor point...
Okay.
>
> | > - foo() {
> | > if (....) {
> | > ....
> | > ....
> | > }
> | > }
> | > instead:
> | > foo() {
> | > if (!....)
> | > return;
> | > ....
> | > ....
> | > }
> |
> | I prefer to the latter too. Which ones in the patch do you get worried?
>
> htable_unlink_entry more
> htable_prefix_free_cb less
>
> | > - why cast void *'s for example rif = (struct token_rif *)la->la_opaque;
> |
> | My fault. I'll fix it.
>
> There are others....
>
> struct in_ifinfo *ii = (struct in_ifinfo *)aux;
> pmd = (struct prefix_match_data *)farg;
> dchain = (struct llentries *)farg;
> la = (struct llentry *)rt->rt_llinfo;
> struct llentry *lle = (struct llentry *)arg;
>
> just to mention a few.
Thanks. I fixed many of them while I left some in if_llatbl.c
and in.c as is. I'll get them down once FreeBSD's work calms down.
The patch is updated:
http://www.netbsd.org/~ozaki-r/lltable-arpcache.diff
(https://github.com/ozaki-r/netbsd-src/tree/lltable-arpcache)
Thanks,
ozaki-r
Home |
Main Index |
Thread Index |
Old Index