> From: Jakub Kicinski <k...@kernel.org> > Sent: Monday, July 13, 2020 5:31 PM > To: da...@davemloft.net > Cc: netdev@vger.kernel.org; oss-driv...@netronome.com; > simon.hor...@netronome.com; ajit.khapa...@broadcom.com; > sriharsha.basavapa...@broadcom.com; somnath.ko...@broadcom.com; > thomas.lenda...@amd.com; Ariel Elior <ael...@marvell.com>; Sudarsana > Reddy Kalluru <skall...@marvell.com>; vis...@chelsio.com; > be...@cisco.com; _gov...@gmx.com; Derek Chickles > <dchick...@marvell.com>; Satananda Burla <sbu...@marvell.com>; Felix > Manlunas <fmanlu...@marvell.com>; jeffrey.t.kirs...@intel.com; > anthony.l.ngu...@intel.com; GR-everest-linux-l2 <GR-everest-linux- > l...@marvell.com>; Shahed Shaikh <shsha...@marvell.com>; Manish Chopra > <mani...@marvell.com>; GR-Linux-NIC-Dev <GR-Linux-NIC- > d...@marvell.com>; Jakub Kicinski <k...@kernel.org> > Subject: [EXT] [PATCH net-next 08/12] liquidio: convert to new > udp_tunnel_nic infra > > This driver is just a super thin FW interface. Assume it wants 256 ports at > most. Not much we can do here.
It actually supports 1024. Can you change this patch accordingly? Same goes for lio_vf_main.c. Thanks, Derek > > Signed-off-by: Jakub Kicinski <k...@kernel.org> > --- > .../net/ethernet/cavium/liquidio/lio_main.c | 59 +++++++++++-------- > 1 file changed, 33 insertions(+), 26 deletions(-) > > diff --git a/drivers/net/ethernet/cavium/liquidio/lio_main.c > b/drivers/net/ethernet/cavium/liquidio/lio_main.c > index 19689d72bc4e..dc620cb78fd5 100644 > --- a/drivers/net/ethernet/cavium/liquidio/lio_main.c > +++ b/drivers/net/ethernet/cavium/liquidio/lio_main.c > @@ -2670,6 +2670,35 @@ static int liquidio_vxlan_port_command(struct > net_device *netdev, int command, > return ret; > } > > +static int liquidio_udp_tunnel_set_port(struct net_device *netdev, > + unsigned int table, unsigned int entry, > + struct udp_tunnel_info *ti) > +{ > + return liquidio_vxlan_port_command(netdev, > + > OCTNET_CMD_VXLAN_PORT_CONFIG, > + htons(ti->port), > + OCTNET_CMD_VXLAN_PORT_ADD); > +} > + > +static int liquidio_udp_tunnel_unset_port(struct net_device *netdev, > + unsigned int table, > + unsigned int entry, > + struct udp_tunnel_info *ti) > +{ > + return liquidio_vxlan_port_command(netdev, > + > OCTNET_CMD_VXLAN_PORT_CONFIG, > + htons(ti->port), > + OCTNET_CMD_VXLAN_PORT_DEL); > +} > + > +static const struct udp_tunnel_nic_info liquidio_udp_tunnels = { > + .set_port = liquidio_udp_tunnel_set_port, > + .unset_port = liquidio_udp_tunnel_unset_port, > + .tables = { > + { .n_entries = 256, .tunnel_types = > UDP_TUNNEL_TYPE_VXLAN, }, > + }, > +};