From mboxrd@z Thu Jan 1 00:00:00 1970 From: Roberto Nibali Subject: [PATCH][RFC] Shrink ip_vs_*.c includes Date: Mon, 06 Feb 2006 01:48:33 +0100 Message-ID: <43E69CE1.2030204@drugphish.ch> Reply-To: "LinuxVirtualServer.org users mailing list." Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------090809030603060706050008" Return-path: To: netdev@vger.kernel.org, , Horms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: lvs-users-bounces@LinuxVirtualServer.org Errors-To: lvs-users-bounces@LinuxVirtualServer.org List-Id: netdev.vger.kernel.org This is a multi-part message in MIME format. --------------090809030603060706050008 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Hello, This patch against the latest GIT HEAD reduces the includes to the necessary ones. I've compile-tested it against following (and s/y/m/) configuration on x86: CONFIG_IP_VS=y CONFIG_IP_VS_DEBUG=y CONFIG_IP_VS_TAB_BITS=12 CONFIG_IP_VS_PROTO_TCP=y CONFIG_IP_VS_PROTO_UDP=y CONFIG_IP_VS_PROTO_ESP=y CONFIG_IP_VS_PROTO_AH=y CONFIG_IP_VS_RR=y CONFIG_IP_VS_WRR=y CONFIG_IP_VS_LC=y CONFIG_IP_VS_WLC=y CONFIG_IP_VS_LBLC=y CONFIG_IP_VS_LBLCR=y CONFIG_IP_VS_DH=y CONFIG_IP_VS_SH=y CONFIG_IP_VS_SED=y CONFIG_IP_VS_NQ=y CONFIG_IP_VS_FTP=y Please consider applying (but test it first on your local tree since we don't want stupid breakage resulting from such changes). Alternatively/additionally I could envision a patch on top of this one that completely removes the includes from the ../net/ipv4/ipvs/*.c except the ../include/net/ip_vs.h, which would carry all the needed header includes. Signed-off-by: Roberto Nibali Best regards, Roberto Nibali, ratz -- echo '[q]sa[ln0=aln256%Pln256/snlbx]sb3135071790101768542287578439snlbxq' | dc --------------090809030603060706050008 Content-Type: text/plain; name="ipvs_shrink_includes-2.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="ipvs_shrink_includes-2.diff" diff --git a/net/ipv4/ipvs/ip_vs_app.c b/net/ipv4/ipvs/ip_vs_app.c index 9b176a9..9f5676b 100644 --- a/net/ipv4/ipvs/ip_vs_app.c +++ b/net/ipv4/ipvs/ip_vs_app.c @@ -20,17 +20,9 @@ * */ -#include -#include #include -#include -#include -#include #include -#include -#include #include -#include #include diff --git a/net/ipv4/ipvs/ip_vs_conn.c b/net/ipv4/ipvs/ip_vs_conn.c index 87b8381..b3e8dc5 100644 --- a/net/ipv4/ipvs/ip_vs_conn.c +++ b/net/ipv4/ipvs/ip_vs_conn.c @@ -24,14 +24,11 @@ * */ -#include #include #include -#include -#include +#include #include -#include /* for proc_net_* */ -#include +#include #include #include diff --git a/net/ipv4/ipvs/ip_vs_core.c b/net/ipv4/ipvs/ip_vs_core.c index 3f47ad8..927fbc0 100644 --- a/net/ipv4/ipvs/ip_vs_core.c +++ b/net/ipv4/ipvs/ip_vs_core.c @@ -26,19 +26,13 @@ * */ -#include -#include -#include #include #include #include -#include -#include #include /* for icmp_send */ -#include +#include /* for inet_addr_type */ -#include #include #include diff --git a/net/ipv4/ipvs/ip_vs_ctl.c b/net/ipv4/ipvs/ip_vs_ctl.c index 7f0288b..a130c5f 100644 --- a/net/ipv4/ipvs/ip_vs_ctl.c +++ b/net/ipv4/ipvs/ip_vs_ctl.c @@ -20,26 +20,14 @@ * */ -#include -#include -#include -#include -#include -#include #include -#include -#include -#include -#include - -#include #include #include #include #include -#include +//#include #include diff --git a/net/ipv4/ipvs/ip_vs_dh.c b/net/ipv4/ipvs/ip_vs_dh.c index 9fee19c..e40998c 100644 --- a/net/ipv4/ipvs/ip_vs_dh.c +++ b/net/ipv4/ipvs/ip_vs_dh.c @@ -38,8 +38,6 @@ */ #include -#include -#include #include #include diff --git a/net/ipv4/ipvs/ip_vs_est.c b/net/ipv4/ipvs/ip_vs_est.c index c453e1e..ce3d3c3 100644 --- a/net/ipv4/ipvs/ip_vs_est.c +++ b/net/ipv4/ipvs/ip_vs_est.c @@ -13,12 +13,8 @@ * Changes: * */ -#include -#include #include #include -#include -#include #include diff --git a/net/ipv4/ipvs/ip_vs_ftp.c b/net/ipv4/ipvs/ip_vs_ftp.c index a19a33c..ab730b1 100644 --- a/net/ipv4/ipvs/ip_vs_ftp.c +++ b/net/ipv4/ipvs/ip_vs_ftp.c @@ -24,13 +24,7 @@ * */ -#include -#include -#include #include -#include -#include -#include #include #include diff --git a/net/ipv4/ipvs/ip_vs_lblc.c b/net/ipv4/ipvs/ip_vs_lblc.c index 6e5cb92..ae51ae8 100644 --- a/net/ipv4/ipvs/ip_vs_lblc.c +++ b/net/ipv4/ipvs/ip_vs_lblc.c @@ -42,14 +42,8 @@ */ #include -#include -#include #include -/* for sysctl */ -#include -#include - #include diff --git a/net/ipv4/ipvs/ip_vs_lblcr.c b/net/ipv4/ipvs/ip_vs_lblcr.c index 32ba37b..ebe05a8 100644 --- a/net/ipv4/ipvs/ip_vs_lblcr.c +++ b/net/ipv4/ipvs/ip_vs_lblcr.c @@ -40,16 +40,8 @@ */ #include -#include -#include #include -/* for sysctl */ -#include -#include -/* for proc_net_create/proc_net_remove */ -#include - #include diff --git a/net/ipv4/ipvs/ip_vs_lc.c b/net/ipv4/ipvs/ip_vs_lc.c index d88fef9..db63c0f 100644 --- a/net/ipv4/ipvs/ip_vs_lc.c +++ b/net/ipv4/ipvs/ip_vs_lc.c @@ -17,7 +17,6 @@ */ #include -#include #include diff --git a/net/ipv4/ipvs/ip_vs_nq.c b/net/ipv4/ipvs/ip_vs_nq.c index bc2a9e5..f1b4341 100644 --- a/net/ipv4/ipvs/ip_vs_nq.c +++ b/net/ipv4/ipvs/ip_vs_nq.c @@ -34,7 +34,6 @@ */ #include -#include #include diff --git a/net/ipv4/ipvs/ip_vs_proto.c b/net/ipv4/ipvs/ip_vs_proto.c index 867d4e9..9084338 100644 --- a/net/ipv4/ipvs/ip_vs_proto.c +++ b/net/ipv4/ipvs/ip_vs_proto.c @@ -15,17 +15,8 @@ * */ -#include -#include #include -#include -#include -#include #include -#include -#include -#include -#include #include diff --git a/net/ipv4/ipvs/ip_vs_proto_ah.c b/net/ipv4/ipvs/ip_vs_proto_ah.c index 8b0505b..cb95f58 100644 --- a/net/ipv4/ipvs/ip_vs_proto_ah.c +++ b/net/ipv4/ipvs/ip_vs_proto_ah.c @@ -14,9 +14,6 @@ #include #include -#include -#include -#include #include #include diff --git a/net/ipv4/ipvs/ip_vs_proto_esp.c b/net/ipv4/ipvs/ip_vs_proto_esp.c index c36ccf0..bcbad11 100644 --- a/net/ipv4/ipvs/ip_vs_proto_esp.c +++ b/net/ipv4/ipvs/ip_vs_proto_esp.c @@ -14,9 +14,6 @@ #include #include -#include -#include -#include #include #include diff --git a/net/ipv4/ipvs/ip_vs_proto_tcp.c b/net/ipv4/ipvs/ip_vs_proto_tcp.c index bc28b11..deb98e7 100644 --- a/net/ipv4/ipvs/ip_vs_proto_tcp.c +++ b/net/ipv4/ipvs/ip_vs_proto_tcp.c @@ -15,11 +15,7 @@ * */ -#include -#include -#include /* for tcphdr */ -#include -#include /* for csum_tcpudp_magic */ +#include #include #include diff --git a/net/ipv4/ipvs/ip_vs_proto_udp.c b/net/ipv4/ipvs/ip_vs_proto_udp.c index 89d9175..7ffd5c2 100644 --- a/net/ipv4/ipvs/ip_vs_proto_udp.c +++ b/net/ipv4/ipvs/ip_vs_proto_udp.c @@ -17,9 +17,8 @@ #include #include -#include -#include #include +#include #include diff --git a/net/ipv4/ipvs/ip_vs_rr.c b/net/ipv4/ipvs/ip_vs_rr.c index b23bab2..00ebed8 100644 --- a/net/ipv4/ipvs/ip_vs_rr.c +++ b/net/ipv4/ipvs/ip_vs_rr.c @@ -22,7 +22,6 @@ */ #include -#include #include diff --git a/net/ipv4/ipvs/ip_vs_sched.c b/net/ipv4/ipvs/ip_vs_sched.c index 8bc42b7..8abc2e9 100644 --- a/net/ipv4/ipvs/ip_vs_sched.c +++ b/net/ipv4/ipvs/ip_vs_sched.c @@ -20,11 +20,6 @@ */ #include -#include -#include -#include -#include -#include #include diff --git a/net/ipv4/ipvs/ip_vs_sed.c b/net/ipv4/ipvs/ip_vs_sed.c index ff366f7..8269e6c 100644 --- a/net/ipv4/ipvs/ip_vs_sed.c +++ b/net/ipv4/ipvs/ip_vs_sed.c @@ -38,7 +38,6 @@ */ #include -#include #include diff --git a/net/ipv4/ipvs/ip_vs_sh.c b/net/ipv4/ipvs/ip_vs_sh.c index 7775e6c..878c63f 100644 --- a/net/ipv4/ipvs/ip_vs_sh.c +++ b/net/ipv4/ipvs/ip_vs_sh.c @@ -35,8 +35,6 @@ */ #include -#include -#include #include #include diff --git a/net/ipv4/ipvs/ip_vs_sync.c b/net/ipv4/ipvs/ip_vs_sync.c index 1bca714..8d2dba4 100644 --- a/net/ipv4/ipvs/ip_vs_sync.c +++ b/net/ipv4/ipvs/ip_vs_sync.c @@ -19,20 +19,13 @@ * Justin Ossevoort : Fix endian problem on sync message size. */ -#include -#include #include -#include -#include #include -#include -#include #include /* for ip_mc_join_group */ #include +#include #include -#include -#include /* for get_fs and set_fs */ #include diff --git a/net/ipv4/ipvs/ip_vs_wlc.c b/net/ipv4/ipvs/ip_vs_wlc.c index 8a9d913..6d90a7c 100644 --- a/net/ipv4/ipvs/ip_vs_wlc.c +++ b/net/ipv4/ipvs/ip_vs_wlc.c @@ -22,7 +22,6 @@ */ #include -#include #include diff --git a/net/ipv4/ipvs/ip_vs_wrr.c b/net/ipv4/ipvs/ip_vs_wrr.c index 749fa04..bfcd5fb 100644 --- a/net/ipv4/ipvs/ip_vs_wrr.c +++ b/net/ipv4/ipvs/ip_vs_wrr.c @@ -21,7 +21,6 @@ */ #include -#include #include diff --git a/net/ipv4/ipvs/ip_vs_xmit.c b/net/ipv4/ipvs/ip_vs_xmit.c index 52c12e9..19d85e3 100644 --- a/net/ipv4/ipvs/ip_vs_xmit.c +++ b/net/ipv4/ipvs/ip_vs_xmit.c @@ -15,14 +15,9 @@ * */ -#include -#include -#include /* for tcphdr */ -#include /* for csum_tcpudp_magic */ -#include +#include #include /* for icmp_send */ #include /* for ip_route_output */ -#include #include #include --------------090809030603060706050008 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline --------------090809030603060706050008--