1. 19 Sep, 2020 21 commits
  2. 18 Sep, 2020 19 commits
    • Wang Hai's avatar
      net: tipc: Supply missing udp_media.h include file · 5f3666e8
      Wang Hai authored
      If the header file containing a function's prototype isn't included by
      the sourcefile containing the associated function, the build system
      complains of missing prototypes.
      
      Fixes the following W=1 kernel build warning(s):
      
      net/tipc/udp_media.c:446:5: warning: no previous prototype for ‘tipc_udp_nl_dump_remoteip’ [-Wmissing-prototypes]
      net/tipc/udp_media.c:532:5: warning: no previous prototype for ‘tipc_udp_nl_add_bearer_data’ [-Wmissing-prototypes]
      net/tipc/udp_media.c:614:5: warning: no previous prototype for ‘tipc_udp_nl_bearer_add’ [-Wmissing-prototypes]
      Signed-off-by: default avatarWang Hai <wanghai38@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      5f3666e8
    • YueHaibing's avatar
      tipc: Remove unused macro CF_SERVER · 7eae7f72
      YueHaibing authored
      It is no used any more, so can remove it.
      Signed-off-by: default avatarYueHaibing <yuehaibing@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      7eae7f72
    • Wang Hai's avatar
      net: hns3: Supply missing hclge_dcb.h include file · a61432d4
      Wang Hai authored
      If the header file containing a function's prototype isn't included by
      the sourcefile containing the associated function, the build system
      complains of missing prototypes.
      
      Fixes the following W=1 kernel build warning(s):
      
      drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_dcb.c:453:6: warning: no previous prototype for ‘hclge_dcb_ops_set’ [-Wmissing-prototypes]
      Signed-off-by: default avatarWang Hai <wanghai38@huawei.com>
      Reviewed-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a61432d4
    • Wang Hai's avatar
      net/appletalk: Supply missing net/Space.h include file · b77f3ce0
      Wang Hai authored
      If the header file containing a function's prototype isn't included by
      the sourcefile containing the associated function, the build system
      complains of missing prototypes.
      
      Fixes the following W=1 kernel build warning(s):
      
      drivers/net/appletalk/cops.c:213:28: warning: no previous prototype for ‘cops_probe’ [-Wmissing-prototypes]
      drivers/net/appletalk/ltpc.c:1014:28: warning: no previous prototype for ‘ltpc_probe’ [-Wmissing-prototypes]
      Signed-off-by: default avatarWang Hai <wanghai38@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b77f3ce0
    • Wang Hai's avatar
      liquidio: Fix -Wmissing-prototypes warnings for liquidio · 98cf1c67
      Wang Hai authored
      If the header file containing a function's prototype isn't included by
      the sourcefile containing the associated function, the build system
      complains of missing prototypes.
      
      Fixes the following W=1 kernel build warning(s):
      
      drivers/net/ethernet/cavium/liquidio/cn68xx_device.c:124:5: warning: no previous prototype for ‘lio_setup_cn68xx_octeon_device’ [-Wmissing-prototypes]
      drivers/net/ethernet/cavium/liquidio/octeon_mem_ops.c:159:1: warning: no previous prototype for ‘octeon_pci_read_core_mem’ [-Wmissing-prototypes]
      drivers/net/ethernet/cavium/liquidio/octeon_mem_ops.c:168:1: warning: no previous prototype for ‘octeon_pci_write_core_mem’ [-Wmissing-prototypes]
      drivers/net/ethernet/cavium/liquidio/octeon_mem_ops.c:176:5: warning: no previous prototype for ‘octeon_read_device_mem64’ [-Wmissing-prototypes]
      drivers/net/ethernet/cavium/liquidio/octeon_mem_ops.c:185:5: warning: no previous prototype for ‘octeon_read_device_mem32’ [-Wmissing-prototypes]
      drivers/net/ethernet/cavium/liquidio/octeon_mem_ops.c:194:6: warning: no previous prototype for ‘octeon_write_device_mem32’ [-Wmissing-prototypes]
      Signed-off-by: default avatarWang Hai <wanghai38@huawei.com>
      Reviewed-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      98cf1c67
    • Tom Parkin's avatar
      l2tp: fix up inconsistent rx/tx statistics · f52e4b27
      Tom Parkin authored
      Historically L2TP core statistics count the L2TP header in the
      per-session and per-tunnel byte counts tracked for transmission and
      receipt.
      
      Now that l2tp_xmit_skb updates tx stats, it is necessary for
      l2tp_xmit_core to pass out the length of the transmitted packet so that
      the statistics can be updated correctly.
      Signed-off-by: default avatarTom Parkin <tparkin@katalix.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f52e4b27
    • Luo bin's avatar
      hinic: modify irq name · a9fd686a
      Luo bin authored
      Make a distinction between different irqs by netdev name or pci name.
      Signed-off-by: default avatarLuo bin <luobin9@huawei.com>
      Reviewed-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a9fd686a
    • Zheng Yongjun's avatar
      net: cortina: Remove set but not used variable · f313edfe
      Zheng Yongjun authored
      Fixes gcc '-Wunused-but-set-variable' warning:
      
      drivers/net/ethernet/cortina/gemini.c: In function gmac_get_ringparam:
      drivers/net/ethernet/cortina/gemini.c:2125:21: warning: variable ‘config0’ set but not used [-Wunused-but-set-variable]
      
      drivers/net/ethernet/cortina/gemini.c: In function gmac_init:
      drivers/net/ethernet/cortina/gemini.c:512:6: warning: variable ‘val’ set but not used [-Wunused-but-set-variable]
      
      these variable is never used, so remove it.
      Signed-off-by: default avatarZheng Yongjun <zhengyongjun3@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f313edfe
    • David S. Miller's avatar
      Merge branch 'dpaa2_eth-support-1588-one-step-timestamping' · a9609d79
      David S. Miller authored
      Yangbo Lu says:
      
      ====================
      dpaa2_eth: support 1588 one-step timestamping
      
      This patch-set is to add MC APIs of 1588 one-step timestamping, and
      support one-step timestamping for PTP Sync packet on DPAA2.
      
      Before egress, one-step timestamping enablement needs,
      
      - Enabling timestamp and FAS (Frame Annotation Status) in
        dpni buffer layout.
      
      - Write timestamp to frame annotation and set PTP bit in
        FAS to mark as one-step timestamping event.
      
      - Enabling one-step timestamping by dpni_set_single_step_cfg()
        API, with offset provided to insert correction time on frame.
        The offset must respect all MAC headers, VLAN tags and other
        protocol headers accordingly. The correction field update can
        consider delays up to one second. So PTP frame needs to be
        filtered and parsed, and written timestamp into Sync frame
        originTimestamp field.
      
      The operation of API dpni_set_single_step_cfg() has to be done
      when no one-step timestamping frames are in flight. So we have
      to make sure the last one-step timestamping frame has already
      been transmitted on hardware before starting to send the current
      one. The resolution is,
      
      - Utilize skb->cb[0] to mark timestamping request per packet.
        If it is one-step timestamping PTP sync packet, queue to skb queue.
        If not, transmit immediately.
      
      - Schedule a work to transmit skbs in skb queue.
      
      - mutex lock is used to ensure the last one-step timestamping packet
        has already been transmitted on hardware through TX confirmation queue
        before transmitting current packet.
      
      Changes for v2:
      	- Removed unused variable priv in dpaa2_eth_xdp_create_fd().
      Changes for v3:
      	- Fixed sparse warnings.
      	- Fix build issue on 32-bit.
      	- Converted to use ptp_parse_header.
      Changes for v4:
      	- Used WARN_ONCE instead of netdev_err in data path.
      	- Enabled timestamping only when PTP driver is ready.
      	- Added comments in using onestep_tstamp_lock.
      	- Dropped dpmac.c sparse warning fix-up patch.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a9609d79
    • Yangbo Lu's avatar
      dpaa2-eth: support PTP Sync packet one-step timestamping · c5521189
      Yangbo Lu authored
      This patch is to add PTP sync packet one-step timestamping support.
      Before egress, one-step timestamping enablement needs,
      
      - Enabling timestamp and FAS (Frame Annotation Status) in
        dpni buffer layout.
      
      - Write timestamp to frame annotation and set PTP bit in
        FAS to mark as one-step timestamping event.
      
      - Enabling one-step timestamping by dpni_set_single_step_cfg()
        API, with offset provided to insert correction time on frame.
        The offset must respect all MAC headers, VLAN tags and other
        protocol headers accordingly. The correction field update can
        consider delays up to one second. So PTP frame needs to be
        filtered and parsed, and written timestamp into Sync frame
        originTimestamp field.
      
      The operation of API dpni_set_single_step_cfg() has to be done
      when no one-step timestamping frames are in flight. So we have
      to make sure the last one-step timestamping frame has already
      been transmitted on hardware before starting to send the current
      one. The resolution is,
      
      - Utilize skb->cb[0] to mark timestamping request per packet.
        If it is one-step timestamping PTP sync packet, queue to skb queue.
        If not, transmit immediately.
      
      - Schedule a work to transmit skbs in skb queue.
      
      - mutex lock is used to ensure the last one-step timestamping packet
        has already been transmitted on hardware through TX confirmation queue
        before transmitting current packet.
      Signed-off-by: default avatarYangbo Lu <yangbo.lu@nxp.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      c5521189
    • Yangbo Lu's avatar
      dpaa2-eth: utilize skb->cb[0] for hardware timestamping · 1cf773bd
      Yangbo Lu authored
      This patch is a preparation for next hardware one-step timestamping
      support. For DPAA2, the one step timestamping configuration on
      hardware registers has to be done when there is no one-step timestamping
      packet in flight. So we will have to use workqueue and skb queue
      for such packets transmitting, to make sure waiting the last packet has
      already been sent on hardware, and starting to transmit the current one.
      
      So the tx timestamping flag in private data may not reflect the actual
      request for the one-step timestamping packets of skb queue. This also
      affects skb headroom allocation. Let's use skb->cb[0] to mark the
      timestamping request for each skb.
      Signed-off-by: default avatarYangbo Lu <yangbo.lu@nxp.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      1cf773bd
    • Yangbo Lu's avatar
      dpaa2-eth: invoke dpaa2_eth_enable_tx_tstamp() once in code · 64a965de
      Yangbo Lu authored
      Invoke dpaa2_eth_enable_tx_tstamp() once in code after building FD,
      rather than calling it in dpaa2_eth_build_single_fd(),
      dpaa2_eth_build_sg_fd_single_buf(), and dpaa2_eth_build_sg_fd().
      Signed-off-by: default avatarYangbo Lu <yangbo.lu@nxp.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      64a965de
    • Yangbo Lu's avatar
      dpaa2-eth: define a global ptp_qoriq structure pointer · d21c784c
      Yangbo Lu authored
      Define a global ptp_qoriq structure pointer, and export to use.
      The ptp clock operations will be used in dpaa2-eth driver.
      For example, supporting one step timestamping needs to write
      current time to hardware frame annotation before sending and
      then hardware inserts the delay time on frame during sending.
      So in driver, at least clock gettime operation will be needed
      to make sure right time is written to hardware frame annotation
      for one step timestamping.
      Signed-off-by: default avatarYangbo Lu <yangbo.lu@nxp.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      d21c784c
    • Yangbo Lu's avatar
      dpaa2-eth: add APIs of 1588 single step timestamping · 23cd4f27
      Yangbo Lu authored
      This patch is to add APIs of 1588 single step timestamping.
      
      - dpni_set_single_step_cfg
      - dpni_get_single_step_cfg
      Signed-off-by: default avatarYangbo Lu <yangbo.lu@nxp.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      23cd4f27
    • Zeng Tao's avatar
      net: openswitch: reuse the helper variable to improve the code readablity · 7b066d17
      Zeng Tao authored
      In the function ovs_ct_limit_exit, there is already a helper vaibale
      which could be reused to improve the readability, so i fix it in this
      patch.
      Signed-off-by: default avatarZeng Tao <prime.zeng@hisilicon.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      7b066d17
    • Mahesh Bandewar's avatar
      net: fix build without CONFIG_SYSCTL definition · 3753d977
      Mahesh Bandewar authored
      Earlier commit 316cdaa1 ("net: add option to not create fall-back
      tunnels in root-ns as well") removed the CONFIG_SYSCTL to enable the
      kernel-commandline to work. However, this variable gets defined only
      when CONFIG_SYSCTL option is selected.
      
      With this change the behavior would default to creating fall-back
      tunnels in all namespaces when CONFIG_SYSCTL is not selected and
      the kernel commandline option will be ignored.
      
      Fixes: 316cdaa1 ("net: add option to not create fall-back tunnels in root-ns as well")
      Signed-off-by: default avatarMahesh Bandewar <maheshb@google.com>
      Reported-by: default avatarRandy Dunlap <rdunlap@infradead.org>
      Reported-by: default avatarkernel test robot <lkp@intel.com>
      Acked-by: Randy Dunlap <rdunlap@infradead.org> # build-tested
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      3753d977
    • David S. Miller's avatar
      Merge branch 'net-various-delete-duplicated-words' · d134b78e
      David S. Miller authored
      Randy Dunlap says:
      
      ====================
      net: various: delete duplicated words
      
      [PATCH 1/7 net-next] net: core: delete duplicated words
      [PATCH 2/7 net-next] net: rds: delete duplicated words
      [PATCH 3/7 net-next] net: ipv6: delete duplicated words
      [PATCH 4/7 net-next] net: bluetooth: delete duplicated words
      [PATCH 5/7 net-next] net: tipc: delete duplicated words
      [PATCH 6/7 net-next] net: atm: delete duplicated words
      [PATCH 7/7 net-next] net: bridge: delete duplicated words
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      d134b78e
    • Randy Dunlap's avatar
      net: bridge: delete duplicated words · 4bbd026c
      Randy Dunlap authored
      Drop repeated words in net/bridge/.
      Signed-off-by: default avatarRandy Dunlap <rdunlap@infradead.org>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Jakub Kicinski <kuba@kernel.org>
      Cc: Roopa Prabhu <roopa@nvidia.com>
      Cc: Nikolay Aleksandrov <nikolay@nvidia.com>
      Cc: bridge@lists.linux-foundation.org
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      4bbd026c
    • Randy Dunlap's avatar
      net: atm: delete duplicated words · 563f63e3
      Randy Dunlap authored
      Drop repeated words in net/atm/.
      Signed-off-by: default avatarRandy Dunlap <rdunlap@infradead.org>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Jakub Kicinski <kuba@kernel.org>
      Cc: Chas Williams <3chas3@gmail.com>
      Cc: linux-atm-general@lists.sourceforge.net
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      563f63e3