]> git.karo-electronics.de Git - linux-beck.git/log
linux-beck.git
9 years agoMerge tag 'ipvs2-for-v4.4' of https://git.kernel.org/pub/scm/linux/kernel/git/horms...
Pablo Neira Ayuso [Thu, 24 Sep 2015 23:37:21 +0000 (01:37 +0200)]
Merge tag 'ipvs2-for-v4.4' of https://git.kernel.org/pub/scm/linux/kernel/git/horms/ipvs-next

Simon Horman says:

====================
Second Round of IPVS Updates for v4.4

please consider these bug fixes and extensive clean-ups of IPVS
from Eric Biederman for v4.4.

His excellent description of the changes, which is part of an even larger
set of clean-up work, is as follows:

  I am gradually working my way through the netfilter stack passing struct
  down into the netfilter hooks and from the netfilter hooks and from there
  down into the functions that actually care.  This removes the need for
  netfilter functions to guess how to figure out how to compute which
  network namespace they are in and instead provides a simple and reliable
  method to do so.

  The cleanups stand on their own but this is part of a larger effort to
  have routes with an output device that is not in the current network
  namespace.

  The IPVS code has been a bit more of a challenge than most.  Just passing
  struct net through to where it is needed did not feel clean to me.  The
  practical issue is that the ipvs code in most places actually wants
  struct netns_ipvs and not struct net.

  So as part of this process I have turned the relationship between struct
  net and the structs netns_ipvs, ip_vs_conn_param, ip_vs_conn, and
  ip_vs_service inside out.  I have modified the ipvs functions to take a
  struct netns_ipvs not a struct net.  The net is code with fewer
  conversions from one type of structure to another.  I did wind up adding
  a struct netns_ipvs parameter to quite a few functions that did not have
  it before so I could pass the structure down from the netfilter hooks to
  where it is actually needed to avoid guessing.

  I have broken up the work in a bunch of small patches so there is at
  least a chance and reviewing that each step I took is correct.  The
  series compiles at each step so bisecting it should not be a problem if
  something weird comes up.

  The first two changes in this series are actually bug fixes.  The first
  is a compile fix for a bug in sctp that came in, in the last round of
  ipvs changes merged into nf-next.  The second fixes an older bug where in
  pathological circumstances the wrong network namespace could be used when
  a proc file is written to.

  The rest of the patchset is a bunch of boring changes getting pushing
  struct netns_ipvs (and by extension ipvs->net) where it needs to be.
  Either by replacing struct net pointers or adding new struct netns_ipvs
  pointers.  With a handful of other minor cleanups (like removing
  skb_net).

I have decided include the bug fixes in this pull request. Patch one
relates to a bug that was added to nf-next recently and is thus not
applicable to nf . Patch two could arguably be promoted to a fix for v4.3
and stable though it does not appear to be severe enough to warrant that
course of action; let me know if you would like me to reconsider.
====================

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
9 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next...
David S. Miller [Thu, 24 Sep 2015 22:39:09 +0000 (15:39 -0700)]
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue

Jeff Kirsher says:

====================
Intel Wired LAN Driver Updates 2015-09-23

This series contains updates to ixgbe only.

Mark provides all the changes in this series, first clears the destination
location for I2C data initially so that the received data will not be
corrupted by previous attempts.  Then reduced the pauses/delays in the
PHY detection when no SFP is present by reducing the number of retires,
once an SFP is detected, the "normal" number of retries in PHY detection
will be used.  Added support for X55EM_x SFP+ dual-speed, and fixed 1G and
10G link stability for X550EM_x by configuring the CS4227 correctly by
moving code to ixgbe_setup_mac_link_sfp_x550em().  Added functionality to
reset CS4227, since on some platforms the CS4227 does not initialize
properly.  Next reduces the SFP polling rate, due to when an SFP is not
present, the I2C timeouts that result are very costly.  So prevent the
SFP polling from being done more than once every two seconds.  Added
support for I2C bus MUX.  Fixed the setting of RDRXCTL register which
should fall through X540 and 82599, not 82598.  In addition, added small
packet padding support in X550 by setting RDRXCTL.PSP when the driver is
in SRIOV mode.  Fixed a known hardware issue where the PCI transactions
pending bit sticks high when there are pending transactions, so
workaround the issue by wait and then continue with our reset flow.
Added a new device ID for X550EM device with SFPs.  Provided a fix with
the DCA setup, which was suggested by Alex Duyck <aduyck@mirantis.com>,
by making it so that we always set the relaxed ordering bits related to
the DCA registers even if DCA is not enbaled.  Then moves the
configuration out of the ixgbe_down() and into ixgbe_configure() before
enabling the transmit and receive rings.  This ensures that DCA is
configured correctly before starting the processing of packets.
Fixed VM-to-VM loopback mode which requires that FCRTH be set, but
the datasheets did not specify what the value should be.  It has now
been determined that the correct value should be RXPBSIZE - (24*1024).
====================

Signed-off-by: David S. Miller <davem@davemloft.net>
9 years agotcp: factorize sk_txhash init
Eric Dumazet [Wed, 23 Sep 2015 03:44:17 +0000 (20:44 -0700)]
tcp: factorize sk_txhash init

Neal suggested to move sk_txhash init into tcp_create_openreq_child(),
called both from IPv4 and IPv6.

This opportunity was missed in commit 58d607d3e52f ("tcp: provide
skb->hash to synack packets")

Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: Neal Cardwell <ncardwell@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
9 years agonet: axinet: Use of_property_read_u32 instead of open-coding it
Tobias Klauser [Wed, 23 Sep 2015 07:20:55 +0000 (09:20 +0200)]
net: axinet: Use of_property_read_u32 instead of open-coding it

Use of_property_read_u32 instead of of_get_property with return value
checks and endianness conversion.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Reviewed-by: Sören Brinkmann <soren.brinkmann@xilinx.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
9 years agonet: ll_temac: Use of_property_read_u32 instead of open-coding it
Tobias Klauser [Wed, 23 Sep 2015 07:20:02 +0000 (09:20 +0200)]
net: ll_temac: Use of_property_read_u32 instead of open-coding it

Use of_property_read_u32 to read the "clock-frequency" property instead
of using of_get_property with return value checks.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Reviewed-by: Sören Brinkmann <soren.brinkmann@xilinx.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
9 years agoipv6: remove unused neigh parameter from ndisc functions
Jiri Benc [Tue, 22 Sep 2015 16:57:13 +0000 (18:57 +0200)]
ipv6: remove unused neigh parameter from ndisc functions

Since commit 12fd84f4383b1 ("ipv6: Remove unused neigh argument for
icmp6_dst_alloc() and its callers."), the neigh parameter of ndisc_send_na
and ndisc_send_ns is unused.

CC: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: Jiri Benc <jbenc@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
9 years agogenetlink: simplify genl_notify
Jiri Benc [Tue, 22 Sep 2015 16:56:43 +0000 (18:56 +0200)]
genetlink: simplify genl_notify

The genl_notify function has too many arguments for no real reason - all
callers use genl_info to get them anyway. Just pass the genl_info down to
genl_notify.

Signed-off-by: Jiri Benc <jbenc@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
9 years agoixgbe: Advance version to 4.2.1
Mark Rustad [Tue, 11 Aug 2015 20:11:58 +0000 (13:11 -0700)]
ixgbe: Advance version to 4.2.1

With the addition of X550em_x SFP+ support, the driver is now
functionally equivalent to what will be the 4.2.1 driver when
released, so change the version to match.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Krishneil Singh <krishneil.k.singh@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: X540 thermal warning interrupt not a GPI
Mark Rustad [Sat, 8 Aug 2015 23:27:56 +0000 (16:27 -0700)]
ixgbe: X540 thermal warning interrupt not a GPI

The X540 thermal interrupt (IXGBE_EIMS_TS) is not an SDP, so it
doesn't need to be enabled in ixgbe_setup_gpie(). In fact the
value is simply not for the GPIE register at all.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Fix FCRTH value in VM-to-VM loopback mode
Mark Rustad [Sat, 8 Aug 2015 23:27:51 +0000 (16:27 -0700)]
ixgbe: Fix FCRTH value in VM-to-VM loopback mode

The 82599 and X540 datasheets require that FCRTH be "set" for Tx
switching (VM-to-VM loopback) but it did not previously specify what
the value should be set to. It has now been determined that
the correct value is RXPBSIZE - (24*1024).

This setting is also required for later devices.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Only clear adapter_stopped if ixgbe_setup_fc succeeded
Mark Rustad [Sat, 8 Aug 2015 23:27:46 +0000 (16:27 -0700)]
ixgbe: Only clear adapter_stopped if ixgbe_setup_fc succeeded

A logic error here results in the adapter_stopped flag only being
cleared when ixgbe_setup_fc returns an error. Correct the logic.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Correct several flaws with with DCA setup
Mark Rustad [Sat, 8 Aug 2015 23:27:41 +0000 (16:27 -0700)]
ixgbe: Correct several flaws with with DCA setup

This change does two things. First, it makes it so that we always
set the relaxed ordering bits related to the DCA registers even if
DCA is not enabled. Second, it moves the configuration out of the
ixgbe_down function and into the ixgbe_configure function before
enabling the Rx and Tx rings. This ensures that DCA is configured
correctly before starting to process packets.

Thanks to Alex Duyck for this fix.

CC: Alex Duyck <aduyck@mirantis.com>
Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Add new X550EM SFP+ device ID
Mark Rustad [Sat, 8 Aug 2015 23:19:19 +0000 (16:19 -0700)]
ixgbe: Add new X550EM SFP+ device ID

Add new device ID for X550EM device with SFPs.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Update ixgbe_disable_pcie_master flow for X550*
Mark Rustad [Sat, 8 Aug 2015 23:19:14 +0000 (16:19 -0700)]
ixgbe: Update ixgbe_disable_pcie_master flow for X550*

This patch skips the PCI transactions pending check in
ixgbe_disable_pcie_master. This is done to addresses a known HW
issue where the PCI transactions pending bit sticks high when there
are pending transactions. HW engineering instructed to workaround
this issue by wait and then continue with our reset flow.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Add small packet padding support for X550
Mark Rustad [Sat, 8 Aug 2015 23:19:09 +0000 (16:19 -0700)]
ixgbe: Add small packet padding support for X550

This patch sets RDRXCTL.PSP when the driver is in SRIOV mode which
enables padding of small packets.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Correct setting of RDRXCTL register for X550* devices
Mark Rustad [Sat, 8 Aug 2015 23:19:04 +0000 (16:19 -0700)]
ixgbe: Correct setting of RDRXCTL register for X550* devices

Setting the X550* RDRXCTL register should fall through into X540
and 82599, not 82598.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Correct error path in semaphore handling
Mark Rustad [Sat, 8 Aug 2015 23:18:59 +0000 (16:18 -0700)]
ixgbe: Correct error path in semaphore handling

The timeout path is supposed to release the semaphore, so do that.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Add I2C bus mux support
Mark Rustad [Sat, 8 Aug 2015 23:18:53 +0000 (16:18 -0700)]
ixgbe: Add I2C bus mux support

Take control of an I2C mux that selects which SFP is attached to
the I2C bus. The control of the mux is captured in the taking and
releasing of the related semaphore. Because only port 1 can control
the mux, port 1 always leaves the mux set to select port 0.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Limit SFP polling rate
Mark Rustad [Sat, 8 Aug 2015 23:18:48 +0000 (16:18 -0700)]
ixgbe: Limit SFP polling rate

Reduce the frequency of polling for SFP modules. Because the
service task sometimes runs at high rates, we can poll for
SFPs too often. When an SFP is not present, the I2C timeouts
that result are very costly. So, prevent SFP polling from
being done more than once every two seconds. To reduce latency,
the poll time is cleared in a couple of cases to permit the
next service task execution to poll the SFP module.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Allow SFP+ on more than 82598 and 82599
Mark Rustad [Sat, 8 Aug 2015 23:18:43 +0000 (16:18 -0700)]
ixgbe: Allow SFP+ on more than 82598 and 82599

Since SFP+ can be used with some X550 devices, permit them to be
detected.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Add logic to reset CS4227 when needed
Mark Rustad [Sat, 8 Aug 2015 23:18:38 +0000 (16:18 -0700)]
ixgbe: Add logic to reset CS4227 when needed

On some hardware platforms, the CS4227 does not initialize properly.
Detect those cases and reset it appropriately.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Fix 1G and 10G link stability for X550EM_x SFP+
Mark Rustad [Sat, 8 Aug 2015 23:18:33 +0000 (16:18 -0700)]
ixgbe: Fix 1G and 10G link stability for X550EM_x SFP+

Configures the CS4227 correctly for both 1G and 10G operation,
by moving the code to ixgbe_setup_mac_link_sfp_x550em(). It
needs to be in this function because we need both the module
type and the speed, and this is the only function in the init
flow that knows the speed. In contrast,
ixgbe_setup_sfp_modules_X550em() does not know the speed, so we
can't do anything useful here. This is a fundamental difference
from the previous flow, and is due to the way the CS4227 is
implemented.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Add X550EM_x dual-speed SFP+ support
Mark Rustad [Sat, 8 Aug 2015 23:18:28 +0000 (16:18 -0700)]
ixgbe: Add X550EM_x dual-speed SFP+ support

This patch adds X550EM_x SFP+ dual-speed support. 82599 fiber link
code was moved from ixgbe_82599.c to ixgbe_common.c for use by
X550EM. SFP MAC link code is added to x550EM.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Allow reduced delays during SFP detection
Mark Rustad [Sat, 8 Aug 2015 23:18:22 +0000 (16:18 -0700)]
ixgbe: Allow reduced delays during SFP detection

Reduce the number of retries during PHY detection. This reduces
pauses when no SFP is present. Once an SFP is detected, the normal
retry count will be used.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoixgbe: Clear I2C destination location
Mark Rustad [Sat, 8 Aug 2015 23:18:17 +0000 (16:18 -0700)]
ixgbe: Clear I2C destination location

Clear the destination location for I2C data initially so that
the received data will not be affected by previous attempts.
This could have returned wrong data in certain retry sequences.

Signed-off-by: Mark Rustad <mark.d.rustad@intel.com>
Tested-by: Phil Schmitt <phillip.j.schmitt@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
9 years agoipvs: Pass ipvs into ip_vs_gather_frags
Eric W. Biederman [Mon, 21 Sep 2015 18:03:01 +0000 (13:03 -0500)]
ipvs: Pass ipvs into ip_vs_gather_frags

This will be needed later when the network namespace guessing is
removed from ip_defrag.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Remove skb_sknet
Eric W. Biederman [Mon, 21 Sep 2015 18:03:00 +0000 (13:03 -0500)]
ipvs: Remove skb_sknet

This function adds no real value and it obscures what the code is doing.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Remove skb_net
Eric W. Biederman [Mon, 21 Sep 2015 18:02:59 +0000 (13:02 -0500)]
ipvs: Remove skb_net

This hack has no more users so remove it.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_protocol_net_(init|cleanup)
Eric W. Biederman [Mon, 21 Sep 2015 18:02:58 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_protocol_net_(init|cleanup)

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Remove net argument from ip_vs_tcp_conn_listen
Eric W. Biederman [Mon, 21 Sep 2015 18:02:57 +0000 (13:02 -0500)]
ipvs: Remove net argument from ip_vs_tcp_conn_listen

The argument is unnecessary and in practice confusing,
and has caused the callers to do all manner of silly things.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs through ip_vs_route_me_harder into sysctl_snat_reroute
Eric W. Biederman [Mon, 21 Sep 2015 18:02:56 +0000 (13:02 -0500)]
ipvs: Pass ipvs through ip_vs_route_me_harder into sysctl_snat_reroute

This removes the need to use the hack skb_net.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs into ip_vs_out_icmp and ip_vs_out_icmp_v6
Eric W. Biederman [Mon, 21 Sep 2015 18:02:55 +0000 (13:02 -0500)]
ipvs: Pass ipvs into ip_vs_out_icmp and ip_vs_out_icmp_v6

This removes the need to compute ipvs with the hack "net_ipvs(skb_net(skb))"

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs into ip_vs_in_icmp and ip_vs_in_icmp_v6
Eric W. Biederman [Mon, 21 Sep 2015 18:02:54 +0000 (13:02 -0500)]
ipvs: Pass ipvs into ip_vs_in_icmp and ip_vs_in_icmp_v6

With ipvs passed into ip_vs_in_icmp and ip_vs_in_icmp_v6
they no longer need to call the hack that is skb_net.

Additionally ipvs_in_icmp no longer needs to call dev_net(skb->dev)
and can use the ipvs->net instead.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs into ip_vs_in
Eric W. Biederman [Mon, 21 Sep 2015 18:02:53 +0000 (13:02 -0500)]
ipvs: Pass ipvs into ip_vs_in

Derive ipvs from state->net in the callers of ip_vs_in and pass it
into ip_vs_out.  Removing the need to use the hack skb_net.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs into ip_vs_out
Eric W. Biederman [Mon, 21 Sep 2015 18:02:52 +0000 (13:02 -0500)]
ipvs: Pass ipvs into ip_vs_out

Derive ipvs from state->net in the callers of ip_vs_out and pass it
into ip_vs_out.  Removing the need to use the hack skb_net.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net into sysctl_nat_icmp_send
Eric W. Biederman [Mon, 21 Sep 2015 18:02:51 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net into sysctl_nat_icmp_send

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Simplify ipvs and net access in ip_vs_leave
Eric W. Biederman [Mon, 21 Sep 2015 18:02:50 +0000 (13:02 -0500)]
ipvs: Simplify ipvs and net access in ip_vs_leave

Stop using the hack skb_net(skb) to compute the network namespace.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Wrap sysctl_cache_bypass and remove ifdefs in ip_vs_leave
Eric W. Biederman [Mon, 21 Sep 2015 18:02:49 +0000 (13:02 -0500)]
ipvs: Wrap sysctl_cache_bypass and remove ifdefs in ip_vs_leave

With sysctl_cache_bypass now a compile time constant the compiler can
figue out that it can elimiate all of the code that depends on
sysctl_cache_bypass being true.

Also remove the duplicate computation of net previously necessitated
by #ifdef CONFIG_SYSCTL

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Better derivation of ipvs in ip_vs_in_stats and ip_vs_out_stats
Eric W. Biederman [Mon, 21 Sep 2015 18:02:48 +0000 (13:02 -0500)]
ipvs: Better derivation of ipvs in ip_vs_in_stats and ip_vs_out_stats

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs into ensure_mtu_is adequate
Eric W. Biederman [Mon, 21 Sep 2015 18:02:47 +0000 (13:02 -0500)]
ipvs: Pass ipvs into ensure_mtu_is adequate

This allows two different ways for computing/guessing net to be
removed from ensure_mtu_is_adequate.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs into __ip_vs_get_out_rt_v6
Eric W. Biederman [Mon, 21 Sep 2015 18:02:46 +0000 (13:02 -0500)]
ipvs: Pass ipvs into __ip_vs_get_out_rt_v6

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs into __ip_vs_get_out_rt
Eric W. Biederman [Mon, 21 Sep 2015 18:02:45 +0000 (13:02 -0500)]
ipvs: Pass ipvs into __ip_vs_get_out_rt

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Better derivation of ipvs in ip_vs_tunnel_xmit
Eric W. Biederman [Mon, 21 Sep 2015 18:02:44 +0000 (13:02 -0500)]
ipvs: Better derivation of ipvs in ip_vs_tunnel_xmit

Don't use "net_ipvs(skb_net(skb))" as skb_net is a bad hack.  Instead
use cp->ipvs and ipvs->net for the net.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs into .conn_schedule and ip_vs_try_to_schedule
Eric W. Biederman [Mon, 21 Sep 2015 18:02:43 +0000 (13:02 -0500)]
ipvs: Pass ipvs into .conn_schedule and ip_vs_try_to_schedule

This moves the hack "net_ipvs(skb_net(skb))" up one level where it
will be easier to remove.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net into ip_vs_conn_net_init and ip_vs_conn_net_cleanup
Eric W. Biederman [Mon, 21 Sep 2015 18:02:42 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net into ip_vs_conn_net_init and ip_vs_conn_net_cleanup

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net into ip_vs_conn_net_flush
Eric W. Biederman [Mon, 21 Sep 2015 18:02:41 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net into ip_vs_conn_net_flush

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_conn_hashkey
Eric W. Biederman [Mon, 21 Sep 2015 18:02:40 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_conn_hashkey

Use the address of struct netns_ipvs in the hash not the address of
struct net.  Both addresses are equally valid candidates and by using
the address of struct netns_ipvs there becomes no need deal with
struct net in this part of the code.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs into conn_out_get
Eric W. Biederman [Mon, 21 Sep 2015 18:02:39 +0000 (13:02 -0500)]
ipvs: Pass ipvs into conn_out_get

Move the hack of relying on "net_ipvs(skb_net(skb))" to derive the
ipvs up a layer.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs into .conn_in_get and ip_vs_conn_in_get_proto
Eric W. Biederman [Mon, 21 Sep 2015 18:02:38 +0000 (13:02 -0500)]
ipvs: Pass ipvs into .conn_in_get and ip_vs_conn_in_get_proto

Stop relying on "net_ipvs(skb_net(skb))" to derive the ipvs as
skb_net is a hack.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs into ip_vs_conn_fill_param_proto
Eric W. Biederman [Mon, 21 Sep 2015 18:02:37 +0000 (13:02 -0500)]
ipvs: Pass ipvs into ip_vs_conn_fill_param_proto

Move the ugly hack net_ipvs(skb_net(skb)) up a layer in the call stack
so it is easier to remove.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net into init_netns and exit_netns
Eric W. Biederman [Mon, 21 Sep 2015 18:02:36 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net into init_netns and exit_netns

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net into [un]register_ip_vs_proto_netns
Eric W. Biederman [Mon, 21 Sep 2015 18:02:35 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net into [un]register_ip_vs_proto_netns

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net into ip_vs_app_net_init and ip_vs_app_net_cleanup
Eric W. Biederman [Mon, 21 Sep 2015 18:02:34 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net into ip_vs_app_net_init and ip_vs_app_net_cleanup

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net into ip_vs_app_inc_release
Eric W. Biederman [Mon, 21 Sep 2015 18:02:33 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net into ip_vs_app_inc_release

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to register_ip_vs_app and unregister_ip_vs_app
Eric W. Biederman [Mon, 21 Sep 2015 18:02:32 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to register_ip_vs_app and unregister_ip_vs_app

Also move the tests for net_ipvs being NULL into __ip_vs_ftp_init
and __ip_vs_ftp_exit.  The only places where they possibly make
sense.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to register_ip_vs_app_inc
Eric W. Biederman [Mon, 21 Sep 2015 18:02:31 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to register_ip_vs_app_inc

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net into ip_vs_app_inc_new
Eric W. Biederman [Mon, 21 Sep 2015 18:02:30 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net into ip_vs_app_inc_new

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net into register_app and unregister_app
Eric W. Biederman [Mon, 21 Sep 2015 18:02:29 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net into register_app and unregister_app

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_estimator_net_init and ip_vs_estimator_cleanup
Eric W. Biederman [Mon, 21 Sep 2015 18:02:28 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_estimator_net_init and ip_vs_estimator_cleanup

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to estimation_timer
Eric W. Biederman [Mon, 21 Sep 2015 18:02:27 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to estimation_timer

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net into ip_vs_control_net_(init|cleanup)
Eric W. Biederman [Mon, 21 Sep 2015 18:02:26 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net into ip_vs_control_net_(init|cleanup)

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_control_net_(init|cleanup)_sysctl
Eric W. Biederman [Mon, 21 Sep 2015 18:02:25 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_control_net_(init|cleanup)_sysctl

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_random_drop_entry
Eric W. Biederman [Mon, 21 Sep 2015 18:02:24 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_random_drop_entry

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_start_estimator aned ip_vs_stop_estimator
Eric W. Biederman [Mon, 21 Sep 2015 18:02:23 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_start_estimator aned ip_vs_stop_estimator

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_genl_set_config
Eric W. Biederman [Mon, 21 Sep 2015 18:02:22 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_genl_set_config

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_sync_net_cleanup
Eric W. Biederman [Mon, 21 Sep 2015 18:02:21 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_sync_net_cleanup

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_sync_net_init
Eric W. Biederman [Mon, 21 Sep 2015 18:02:20 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_sync_net_init

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_proc_sync_conn
Eric W. Biederman [Mon, 21 Sep 2015 18:02:19 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_proc_sync_conn

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_proc_conn
Eric W. Biederman [Mon, 21 Sep 2015 18:02:18 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_proc_conn

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_sync_conn
Eric W. Biederman [Mon, 21 Sep 2015 18:02:17 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_sync_conn

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_sync_conn_v0
Eric W. Biederman [Mon, 21 Sep 2015 18:02:16 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_sync_conn_v0

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_process_message
Eric W. Biederman [Mon, 21 Sep 2015 18:02:15 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_process_message

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Store ipvs not net in struct ip_vs_sync_thread_data
Eric W. Biederman [Mon, 21 Sep 2015 18:02:14 +0000 (13:02 -0500)]
ipvs: Store ipvs not net in struct ip_vs_sync_thread_data

In practice struct netns_ipvs is as meaningful as struct net and more
useful as it holds the ipvs specific data.  So store a pointer to
struct netns_ipvs.

Update the accesses of tinfo->net to access tinfo->ipvs->net instead.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to make_receive_sock
Eric W. Biederman [Mon, 21 Sep 2015 18:02:13 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to make_receive_sock

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to make_send_sock
Eric W. Biederman [Mon, 21 Sep 2015 18:02:12 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to make_send_sock

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to stop_sync_thread
Eric W. Biederman [Mon, 21 Sep 2015 18:02:11 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to stop_sync_thread

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to start_sync_thread
Eric W. Biederman [Mon, 21 Sep 2015 18:02:10 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to start_sync_thread

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_genl_del_daemon
Eric W. Biederman [Mon, 21 Sep 2015 18:02:09 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_genl_del_daemon

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_genl_new_daemon
Eric W. Biederman [Mon, 21 Sep 2015 18:02:08 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_genl_new_daemon

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_genl_find_service
Eric W. Biederman [Mon, 21 Sep 2015 18:02:07 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_genl_find_service

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_genl_parse_service
Eric W. Biederman [Mon, 21 Sep 2015 18:02:06 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_genl_parse_service

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to __ip_vs_get_timeouts
Eric W. Biederman [Mon, 21 Sep 2015 18:02:05 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to __ip_vs_get_timeouts

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to __ip_vs_get_dest_entries
Eric W. Biederman [Mon, 21 Sep 2015 18:02:04 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to __ip_vs_get_dest_entries

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to __ip_vs_get_service_entries
Eric W. Biederman [Mon, 21 Sep 2015 18:02:03 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to __ip_vs_get_service_entries

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_set_timeout
Eric W. Biederman [Mon, 21 Sep 2015 18:02:02 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_set_timeout

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_proto_data_get
Eric W. Biederman [Mon, 21 Sep 2015 18:02:01 +0000 (13:02 -0500)]
ipvs: Pass ipvs not net to ip_vs_proto_data_get

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Cache ipvs in ip_vs_in_icmp and ip_vs_in_icmp_v6
Eric W. Biederman [Mon, 21 Sep 2015 18:02:00 +0000 (13:02 -0500)]
ipvs: Cache ipvs in ip_vs_in_icmp and ip_vs_in_icmp_v6

Storte the value of net_ipvs in a variable named ipvs so that when
there are more users struct netns_ipvs in ip_vs_in_cmp and
ip_vs_in_icmp_v6 they won't need to compute the value again.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_zero_all
Eric W. Biederman [Mon, 21 Sep 2015 18:01:59 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to ip_vs_zero_all

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_service_net_cleanup
Eric W. Biederman [Mon, 21 Sep 2015 18:01:58 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to ip_vs_service_net_cleanup

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_flush
Eric W. Biederman [Mon, 21 Sep 2015 18:01:57 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to ip_vs_flush

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_add_service
Eric W. Biederman [Mon, 21 Sep 2015 18:01:56 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to ip_vs_add_service

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Cache ipvs in ip_vs_genl_set_cmd
Eric W. Biederman [Mon, 21 Sep 2015 18:01:55 +0000 (13:01 -0500)]
ipvs: Cache ipvs in ip_vs_genl_set_cmd

Compute ipvs early in ip_vs_genl_set_cmd and use the cached value to
access ipvs->sync_state.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_dest_trash_expire
Eric W. Biederman [Mon, 21 Sep 2015 18:01:54 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to ip_vs_dest_trash_expire

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to __ip_vs_del_dest
Eric W. Biederman [Mon, 21 Sep 2015 18:01:53 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to __ip_vs_del_dest

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_trash_cleanup
Eric W. Biederman [Mon, 21 Sep 2015 18:01:52 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to ip_vs_trash_cleanup

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_find_dest
Eric W. Biederman [Mon, 21 Sep 2015 18:01:51 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to ip_vs_find_dest

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_has_real_service
Eric W. Biederman [Mon, 21 Sep 2015 18:01:50 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to ip_vs_has_real_service

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_service_find
Eric W. Biederman [Mon, 21 Sep 2015 18:01:49 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to ip_vs_service_find

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to __ip_vs_service_find
Eric W. Biederman [Mon, 21 Sep 2015 18:01:48 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to __ip_vs_service_find

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
9 years agoipvs: Pass ipvs not net to ip_vs_svc_hashkey
Eric W. Biederman [Mon, 21 Sep 2015 18:01:47 +0000 (13:01 -0500)]
ipvs: Pass ipvs not net to ip_vs_svc_hashkey

Use the address of ipvs not the address of net when computing the
hash value.  This removes an unncessary dependency on struct net.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>