RE: [patch] Problem with two NIC on same NET (in_scrubprefix:
Hi,=0A=
=0A=
>=0A=
> I've continued with work on two NIC on same NET. Now, with=0A=
> point-to-point interfaces too and I have more small fixes which I=0A=
> submitted today:=0A=
>=0A=
> http://www.freebsd.org/cgi/query-pr.cgi?pr=3D159600=0A=
>=0A=
=0A=
The fix is not entirely correct. The "rtinitflags()" could set RTF_HOS=
T flag when the interface=0A=
type is IFF_LOOPBACK, not necessarily a PPP llink. =0A=
=0A=
>=0A=
> http://www.freebsd.org/cgi/query-pr.cgi?pr=3D159601=0A=
> http://www.freebsd.org/cgi/query-pr.cgi?pr=3D159602=0A=
> http://www.freebsd.org/cgi/query-pr.cgi?pr=3D159603=0A=
>=0A=
=0A=
I need to run some tests on your patch, but keep in mind the LLE_STATI=
C is sort overloaded=0A=
to take care of the case where static routes are maintained in the rou=
ting table while dynamic =0A=
routes are removed when the interface is taken down.=0A=
=0A=
>=0A=
> I have one more related problem, but I'm not sure how complex the fix sho=
uld be.=0A=
>=0A=
> When an interface is marked down a network route is deleted (or=0A=
> replaced) and a loopback route persists in routing table. It is OK.=0A=
> However, when an interface is marked up again, then a network route is=0A=
> installed unconditionally (but error is ignored) and a loopbak route=0A=
> is deleted and added immediately and unconditionally too. IMHO, it is=0A=
> not correct behaviour. I think that a second half of in_ifinit()=0A=
> should be here starting by in_addprefix() call with some small or=0A=
> bigger changes.=0A=
>=0A=
=0A=
Unless you have a really good reason, other than code inspection, and=
have=0A=
a set of test cases, please leave this code alone for now. See below =
....=0A=
=0A=
>=0A=
> Maybe, adding network route and ignoring error could be OK, but=0A=
> deleting loopback route should be done under IFA_RTSELF flag is set=0A=
> condition (with existing route refcount check). V_useloopback should=0A=
> be check before re-adding the route and existing route must be check=0A=
> to evaluate refcount correctly. The proposed patch is attached.=0A=
>=0A=
=0A=
Did you read my code comment in "in.c", at line 1115 ?=0A=
=0A=
>=0A=
> However, I prefer to call in_addprefix() (which is static now) instead=0A=
> of rtinit() and add some more checks from in_ifinit(). Can you (or=0A=
> anyone) review the patch?=0A=
>=0A=
=0A=
There are quite a few cases to cover, including bootp, which takes a d=
ifferent code path=0A=
than DHCP through the routing code. I would appreciate that you test t=
hese cases before =0A=
making any code commits. It's taken some time to get the overall routi=
ng code stabilized. =0A=
There is still a bug in the Radix code that needs fixing.=0A=
=0A=
-- Qing=0A=
=0A=
=0A=
=0A=
_______________________________________________
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"
討論串 (同標題文章)
完整討論串 (本文為第 1 之 2 篇):