From owner-freebsd-mobile Wed Sep 5 5:35:38 2001 Delivered-To: freebsd-mobile@freebsd.org Received: from air.linkclub.or.jp (air.linkclub.or.jp [210.250.19.40]) by hub.freebsd.org (Postfix) with ESMTP id AF19137B406 for ; Wed, 5 Sep 2001 05:35:32 -0700 (PDT) Received: from localhost.jp.FreeBSD.org (1Cust71.tnt1.hanno.jp.da.uu.net [63.12.195.71]) by air.linkclub.or.jp (8.11.4/8.11.4) with ESMTP id f85CXYW61877 for ; Wed, 5 Sep 2001 21:33:37 +0900 (JST) (envelope-from toshi@jp.FreeBSD.org) Date: Wed, 5 Sep 2001 21:30:16 +0900 (JST) Message-Id: <200109051230.f85CUGQ39840.toshi@jp.FreeBSD.org> From: Toshihiko ARAI To: nate@yogotech.com (Nate Williams) Cc: freebsd-mobile@FreeBSD.org Subject: Re: [PATCH] pccard_ether and removable_* variables In-Reply-To: <15253.10889.977127.513674@nomad.yogotech.com> References: <15245.13394.275183.61715@nomad.yogotech.com> <200109011153.f81BrZL93078.toshi@jp.FreeBSD.org> <15253.10889.977127.513674@nomad.yogotech.com> X-Mailer: VM 5.96 (beta) / Mule 2.3 (SUETSUMUHANA) based on 19.34.1 Mime-Version: 1.0 (generated by tm-edit 7.106) Content-Type: text/plain; charset=US-ASCII Sender: owner-freebsd-mobile@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org + <15253.10889.977127.513674@nomad.yogotech.com>, Nate Williams wrote: >> I ask for a review of the following patches. >> >> A summary of a patch, >> >> * Delete removable_interfaces and pccard_ifconfig. However, >> pccard_ifconfig is kept for compatibility in pccard_ether. >> * Documentation of removable_route_flush and static_routes_. >> * Modification of sysinstall, deleted a pccard_ifconfig, added >> some entry to a menu, and some corrections. >> >> http://home.jp.FreeBSD.org/~toshi/pccard-current-20010901.diff > What's the purpose of the following lines of code: > # Clean the routing table > case ${removable_route_flush} in > - [Nn][Oo]) > + [Nn][Oo] | '') > ;; > *) > - # flush beforehand, just in case.... > - route -n flush -inet > + case ${gateway_enable} in > + [Yy][Ee][Ss]) > + ;; > + *) > + route -n flush -inet > + ;; > + esac > ;; > esac > ;; > In particular, why don't we flush the routing table if gateway_enable is > set? That's seems counter-productive. No. This condition is reverse semantics. Therefore setting of removable_route_flush is ignored if gateway_enable is YES. This is a safe step for 'route flush' not to be executed carelessly. > Also, as I've mentioned before, is there anyway we can have the routes > added via 'static_routes_' flushed when the interface is > removed? This seems to be a step in the right direction, and may > obviate the need for removable_route_flush completely. You may be just right. However, 'static_routes_' is null and void with DHCP. Implementation of dhclient seems to surely deal with 'dhclient-script', but I don't so know a lot about DHCP. In addition, I do ease with this code personally. I will want to keep this mechanism if you forgive me. -- Toshihiko ARAI To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-mobile" in the body of the message