1. 31 Jul, 2017 3 commits
    • Mike Marciniszyn's avatar
      IB/hfi1: Fix bar0 mapping to use write combining · cb51c5d2
      Mike Marciniszyn authored
      When the debugpat kernel boot flag is turned on the following
      traces are printed:
      
      [ 1884.793168] x86/PAT: Overlap at 0x90000000-0x92000000
      [ 1884.803510] x86/PAT: reserve_memtype added [mem 0x91200000-0x9127ffff],
      track uncached-minus, req write-combining, ret uncached-minus
      [ 1884.818167] hfi1 0000:05:00.0: hfi1_0: WC Remapped RcvArray:
      ffffc9000a980000
      
      The ioremap_wc() clearly is not returning a write combining mapping due
      to an overlap where the RcvArray is mapped in a uncached mapping prior
      to creating the proposed write combining mapping.
      
      The patch replaces the single base register for uncached CSRs that
      used to overlap the RcvArray with two mappings.   One, kregbase1, from the
      bar0 up to the RcvArray and another, kregbase2, from the end of the
      RcvArray to the pio send buffer space.  A new dd field, base2_start,
      is used to convert the zero-based offset in the CSR routines to the
      correct kregbase1/kregbase2 mapping.  A single direct write of the
      RcvArray CSRs is replaced with hfi1_put_tid() to insure correct access
      using the new disjoint mapping.
      
      Additionally, the kregend field is deleted since it is only ever written.
      
      patdebug now shows the RcvArray as write combining:
      [   35.688990] x86/PAT: reserve_memtype added [mem 0x91200000-0x9127ffff],
      track write-combining, req write-combining, ret write-combining
      
      To insulate from any potential issues with write combining, all
      writeq are now flushed in hfi1_put_tid() and rcv_array_wc_fill().
      Reviewed-by: default avatarMitko Haralanov <mitko.haralanov@intel.com>
      Reviewed-by: default avatarAshutosh Dixit <ashutosh.dixit@intel.com>
      Signed-off-by: default avatarMike Marciniszyn <mike.marciniszyn@intel.com>
      Signed-off-by: default avatarDennis Dalessandro <dennis.dalessandro@intel.com>
      Signed-off-by: default avatarDoug Ledford <dledford@redhat.com>
      cb51c5d2
    • Bartlomiej Dudek's avatar
      IB/hfi1: Check return values from PCI config API calls · c53df62c
      Bartlomiej Dudek authored
      Ensure that return values from kernel PCI config access
      API calls in HFI driver are checked and react properly if
      they are not expected (i.e. not successful).
      Reviewed-by: default avatarJakub Byczkowski <jakub.byczkowski@intel.com>
      Signed-off-by: default avatarBartlomiej Dudek <bartlomiej.dudek@intel.com>
      Signed-off-by: default avatarDennis Dalessandro <dennis.dalessandro@intel.com>
      Signed-off-by: default avatarDoug Ledford <dledford@redhat.com>
      c53df62c
    • Arnd Bergmann's avatar
      IB/hns: include linux/interrupt.h · 967de358
      Arnd Bergmann authored
      I ran into this build error on linux-next:
      
      drivers/infiniband/hw/hns/hns_roce_eq.c:477:8: error: unknown type name 'irqreturn_t'
       static irqreturn_t hns_roce_msi_x_interrupt(int irq, void *eq_ptr)
              ^~~~~~~~~~~
      drivers/infiniband/hw/hns/hns_roce_eq.c: In function 'hns_roce_msi_x_interrupt':
      drivers/infiniband/hw/hns/hns_roce_eq.c:485:9: error: implicit declaration of function 'IRQ_RETVAL'; did you mean 'BPF_RVAL'? [-Werror=implicit-function-declaration]
        return IRQ_RETVAL(int_work);
      
      I have bisected this to a seemingly unrelated change that happened
      to remove some indirect header inclusions. Simply including the
      required header explicitly fixes the build failure.
      
      Fixes: 09c75704 ("xfrm: remove flow cache")
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarDoug Ledford <dledford@redhat.com>
      967de358
  2. 28 Jul, 2017 6 commits
  3. 27 Jul, 2017 4 commits
  4. 24 Jul, 2017 27 commits