1. 30 11月, 2020 1 次提交
  2. 04 11月, 2020 1 次提交
    • A
      habanalabs: fix kernel pointer type · 82948e6e
      Arnd Bergmann 提交于
      All throughout the driver, normal kernel pointers are
      stored as 'u64' struct members, which is kind of silly
      and requires casting through a uintptr_t to void* every
      time they are used.
      
      There is one line that missed the intermediate uintptr_t
      case, which leads to a compiler warning:
      
      drivers/misc/habanalabs/common/command_buffer.c: In function 'hl_cb_mmap':
      drivers/misc/habanalabs/common/command_buffer.c:512:44: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
        512 |  rc = hdev->asic_funcs->cb_mmap(hdev, vma, (void *) cb->kernel_address,
      
      Rather than adding one more cast, just fix the type and
      remove all the other casts.
      
      Fixes: 0db57535 ("habanalabs: make use of dma_mmap_coherent")
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Acked-by: NChristoph Hellwig <hch@lst.de>
      Reviewed-by: NOded Gabbay <oded.gabbay@gmail.com>
      Signed-off-by: NOded Gabbay <ogabbay@kernel.org>
      82948e6e
  3. 22 9月, 2020 13 次提交
  4. 22 8月, 2020 1 次提交
  5. 29 7月, 2020 2 次提交
  6. 25 7月, 2020 7 次提交
  7. 11 7月, 2020 2 次提交
  8. 01 7月, 2020 1 次提交
    • L
      misc: habanalabs: goya: Omit pointless check ensuring addr is >=0 · 2557f27f
      Lee Jones 提交于
      Seeing as 'addr' is unsigned, it would be impossible for the assigned
      value to be anything other than zero or positive.
      
      Squashes the following W=1 warnings:
      
       drivers/misc/habanalabs/goya/goya.c: In function ‘goya_debugfs_read32’:
       drivers/misc/habanalabs/goya/goya.c:3945:19: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
       3945 | } else if ((addr >= DRAM_PHYS_BASE) &&
       | ^~
       drivers/misc/habanalabs/goya/goya.c: In function ‘goya_debugfs_write32’:
       drivers/misc/habanalabs/goya/goya.c:4002:19: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
       4002 | } else if ((addr >= DRAM_PHYS_BASE) &&
       | ^~
       drivers/misc/habanalabs/goya/goya.c: In function ‘goya_debugfs_read64’:
       drivers/misc/habanalabs/goya/goya.c:4047:19: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
       4047 | } else if ((addr >= DRAM_PHYS_BASE) &&
       | ^~
       drivers/misc/habanalabs/goya/goya.c: In function ‘goya_debugfs_write64’:
       drivers/misc/habanalabs/goya/goya.c:4091:19: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
       4091 | } else if ((addr >= DRAM_PHYS_BASE) &&
       | ^~
       drivers/misc/habanalabs/pci.c:328: warning: Excess function parameter 'dma_mask' description in 'hl_pci_set_dma_mask'
       drivers/misc/habanalabs/goya/goya_coresight.c: In function ‘goya_debug_coresight’:
       drivers/misc/habanalabs/goya/goya_coresight.c:643:6: warning: variable ‘val’ set but not used [-Wunused-but-set-variable]
       643 | u32 val;
       | ^~~
      
      Cc: Oded Gabbay <oded.gabbay@gmail.com>
      Cc: Tomer Tayar <ttayar@habana.ai>
      Signed-off-by: NLee Jones <lee.jones@linaro.org>
      Reviewed-by: NOded Gabbay <oded.gabbay@gmail.com>
      Link: https://lore.kernel.org/r/20200701085853.164358-7-lee.jones@linaro.orgSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      2557f27f
  9. 25 5月, 2020 2 次提交
  10. 19 5月, 2020 6 次提交
  11. 17 5月, 2020 4 次提交