1. 12 2月, 2020 1 次提交
  2. 17 9月, 2019 5 次提交
  3. 27 6月, 2019 1 次提交
  4. 13 6月, 2019 2 次提交
  5. 04 6月, 2019 5 次提交
  6. 04 5月, 2019 4 次提交
  7. 08 4月, 2019 1 次提交
    • W
      drivers: Remove explicit invocations of mmiowb() · fb24ea52
      Will Deacon 提交于
      mmiowb() is now implied by spin_unlock() on architectures that require
      it, so there is no reason to call it from driver code. This patch was
      generated using coccinelle:
      
      	@mmiowb@
      	@@
      	- mmiowb();
      
      and invoked as:
      
      $ for d in drivers include/linux/qed sound; do \
      spatch --include-headers --sp-file mmiowb.cocci --dir $d --in-place; done
      
      NOTE: mmiowb() has only ever guaranteed ordering in conjunction with
      spin_unlock(). However, pairing each mmiowb() removal in this patch with
      the corresponding call to spin_unlock() is not at all trivial, so there
      is a small chance that this change may regress any drivers incorrectly
      relying on mmiowb() to order MMIO writes between CPUs using lock-free
      synchronisation. If you've ended up bisecting to this commit, you can
      reintroduce the mmiowb() calls using wmb() instead, which should restore
      the old behaviour on all architectures other than some esoteric ia64
      systems.
      Acked-by: NLinus Torvalds <torvalds@linux-foundation.org>
      Signed-off-by: NWill Deacon <will.deacon@arm.com>
      fb24ea52
  8. 08 1月, 2019 1 次提交
  9. 12 10月, 2018 4 次提交
  10. 09 9月, 2018 2 次提交
  11. 27 7月, 2018 1 次提交
    • G
      net: ena: Fix use of uninitialized DMA address bits field · 101f0cd4
      Gal Pressman 提交于
      UBSAN triggers the following undefined behaviour warnings:
      [...]
      [   13.236124] UBSAN: Undefined behaviour in drivers/net/ethernet/amazon/ena/ena_eth_com.c:468:22
      [   13.240043] shift exponent 64 is too large for 64-bit type 'long long unsigned int'
      [...]
      [   13.744769] UBSAN: Undefined behaviour in drivers/net/ethernet/amazon/ena/ena_eth_com.c:373:4
      [   13.748694] shift exponent 64 is too large for 64-bit type 'long long unsigned int'
      [...]
      
      When splitting the address to high and low, GENMASK_ULL is used to generate
      a bitmask with dma_addr_bits field from io_sq (in ena_com_prepare_tx and
      ena_com_add_single_rx_desc).
      The problem is that dma_addr_bits is not initialized with a proper value
      (besides being cleared in ena_com_create_io_queue).
      Assign dma_addr_bits the correct value that is stored in ena_dev when
      initializing the SQ.
      
      Fixes: 1738cd3e ("net: ena: Add a driver for Amazon Elastic Network Adapters (ENA)")
      Signed-off-by: NGal Pressman <pressmangal@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      101f0cd4
  12. 27 3月, 2018 1 次提交
  13. 19 10月, 2017 1 次提交
  14. 27 9月, 2017 1 次提交
  15. 24 6月, 2017 5 次提交
  16. 12 6月, 2017 3 次提交
    • N
      net: ena: disable admin msix while working in polling mode · a2cc5198
      Netanel Belgazal 提交于
      Fixes: 1738cd3e ("Add a driver for Amazon Elastic Network Adapters (ENA)")
      Signed-off-by: NNetanel Belgazal <netanel@amazon.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a2cc5198
    • N
      net: ena: fix race condition between submit and completion admin command · 661d2b0c
      Netanel Belgazal 提交于
      Bug:
      "Completion context is occupied" error printout will be noticed in
      dmesg.
      This error will cause the admin command to fail, which will lead to
      an ena_probe() failure or a watchdog reset (depends on which admin
      command failed).
      
      Root cause:
      __ena_com_submit_admin_cmd() is the function that submits new entries to
      the admin queue.
      The function have a check that makes sure the queue is not full and the
      function does not override any outstanding command.
      It uses head and tail indexes for this check.
      The head is increased by ena_com_handle_admin_completion() which runs
      from interrupt context, and the tail index is increased by the submit
      function (the function is running under ->q_lock, so there is no risk
      of multithread increment).
      Each command is associated with a completion context. This context
      allocated before call to __ena_com_submit_admin_cmd() and freed by
      ena_com_wait_and_process_admin_cq_interrupts(), right after the command
      was completed.
      
      This can lead to a state where the head was increased, the check passed,
      but the completion context is still in use.
      
      Solution:
      Use the atomic variable ->outstanding_cmds instead of using the head and
      the tail indexes.
      This variable is safe for use since it is bumped in get_comp_ctx() in
      __ena_com_submit_admin_cmd() and is freed by comp_ctxt_release()
      
      Fixes: 1738cd3e ("Add a driver for Amazon Elastic Network Adapters (ENA)")
      Signed-off-by: NNetanel Belgazal <netanel@amazon.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      661d2b0c
    • N
      net: ena: fix rare uncompleted admin command false alarm · a77c1aaf
      Netanel Belgazal 提交于
      The current flow to detect admin completion is:
      while (command_not_completed) {
      	if (timeout)
      		error
      
      	check_for_completion()
      		sleep()
         }
      So in case the sleep took more than the timeout
      (in case the thread/workqueue was not scheduled due to higher priority
      task or prolonged VMexit), the driver can detect a stall even if
      the completion is present.
      
      The fix changes the order of this function to first check for
      completion and only after that check if the timeout expired.
      
      Fixes: 1738cd3e ("Add a driver for Amazon Elastic Network Adapters (ENA)")
      Signed-off-by: NNetanel Belgazal <netanel@amazon.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a77c1aaf
  17. 10 2月, 2017 2 次提交