1. 24 9月, 2007 1 次提交
    • J
      IB/mlx4: Fix data corruption triggered by wrong headroom marking order · 6e694ea3
      Jack Morgenstein 提交于
      This is an addendum to commit 0e6e7416 ("IB/mlx4: Handle new FW
      requirement for send request prefetching").  We also need to handle
      prefetch marking properly for S/G segments, or else the HCA may end up
      processing S/G segments that are not fully written and end up sending
      the wrong data.  This can actually cause data corruption in practice,
      especially on systems with relatively slow CPUs (where the HCA is more
      likely to prefetch while the CPU is in the middle of writing a work
      request into memory).
      
      We write S/G segments in reverse order into the WQE, in order to
      guarantee that the first dword of all cachelines containing S/G
      segments is written last (overwriting the headroom invalidation
      pattern).  The entire cacheline will thus contain valid data when the
      invalidation pattern is overwritten.
      Signed-off-by: NJack Morgenstein <jackm@dev.mellanox.co.il>
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      6e694ea3
  2. 01 9月, 2007 2 次提交
  3. 31 8月, 2007 1 次提交
  4. 16 8月, 2007 1 次提交
  5. 04 8月, 2007 2 次提交
  6. 01 8月, 2007 1 次提交
  7. 31 7月, 2007 4 次提交
  8. 30 7月, 2007 1 次提交
    • A
      Remove fs.h from mm.h · 4e950f6f
      Alexey Dobriyan 提交于
      Remove fs.h from mm.h. For this,
       1) Uninline vma_wants_writenotify(). It's pretty huge anyway.
       2) Add back fs.h or less bloated headers (err.h) to files that need it.
      
      As result, on x86_64 allyesconfig, fs.h dependencies cut down from 3929 files
      rebuilt down to 3444 (-12.3%).
      
      Cross-compile tested without regressions on my two usual configs and (sigh):
      
      alpha              arm-mx1ads        mips-bigsur          powerpc-ebony
      alpha-allnoconfig  arm-neponset      mips-capcella        powerpc-g5
      alpha-defconfig    arm-netwinder     mips-cobalt          powerpc-holly
      alpha-up           arm-netx          mips-db1000          powerpc-iseries
      arm                arm-ns9xxx        mips-db1100          powerpc-linkstation
      arm-assabet        arm-omap_h2_1610  mips-db1200          powerpc-lite5200
      arm-at91rm9200dk   arm-onearm        mips-db1500          powerpc-maple
      arm-at91rm9200ek   arm-picotux200    mips-db1550          powerpc-mpc7448_hpc2
      arm-at91sam9260ek  arm-pleb          mips-ddb5477         powerpc-mpc8272_ads
      arm-at91sam9261ek  arm-pnx4008       mips-decstation      powerpc-mpc8313_rdb
      arm-at91sam9263ek  arm-pxa255-idp    mips-e55             powerpc-mpc832x_mds
      arm-at91sam9rlek   arm-realview      mips-emma2rh         powerpc-mpc832x_rdb
      arm-ateb9200       arm-realview-smp  mips-excite          powerpc-mpc834x_itx
      arm-badge4         arm-rpc           mips-fulong          powerpc-mpc834x_itxgp
      arm-carmeva        arm-s3c2410       mips-ip22            powerpc-mpc834x_mds
      arm-cerfcube       arm-shannon       mips-ip27            powerpc-mpc836x_mds
      arm-clps7500       arm-shark         mips-ip32            powerpc-mpc8540_ads
      arm-collie         arm-simpad        mips-jazz            powerpc-mpc8544_ds
      arm-corgi          arm-spitz         mips-jmr3927         powerpc-mpc8560_ads
      arm-csb337         arm-trizeps4      mips-malta           powerpc-mpc8568mds
      arm-csb637         arm-versatile     mips-mipssim         powerpc-mpc85xx_cds
      arm-ebsa110        i386              mips-mpc30x          powerpc-mpc8641_hpcn
      arm-edb7211        i386-allnoconfig  mips-msp71xx         powerpc-mpc866_ads
      arm-em_x270        i386-defconfig    mips-ocelot          powerpc-mpc885_ads
      arm-ep93xx         i386-up           mips-pb1100          powerpc-pasemi
      arm-footbridge     ia64              mips-pb1500          powerpc-pmac32
      arm-fortunet       ia64-allnoconfig  mips-pb1550          powerpc-ppc64
      arm-h3600          ia64-bigsur       mips-pnx8550-jbs     powerpc-prpmc2800
      arm-h7201          ia64-defconfig    mips-pnx8550-stb810  powerpc-ps3
      arm-h7202          ia64-gensparse    mips-qemu            powerpc-pseries
      arm-hackkit        ia64-sim          mips-rbhma4200       powerpc-up
      arm-integrator     ia64-sn2          mips-rbhma4500       s390
      arm-iop13xx        ia64-tiger        mips-rm200           s390-allnoconfig
      arm-iop32x         ia64-up           mips-sb1250-swarm    s390-defconfig
      arm-iop33x         ia64-zx1          mips-sead            s390-up
      arm-ixp2000        m68k              mips-tb0219          sparc
      arm-ixp23xx        m68k-amiga        mips-tb0226          sparc-allnoconfig
      arm-ixp4xx         m68k-apollo       mips-tb0287          sparc-defconfig
      arm-jornada720     m68k-atari        mips-workpad         sparc-up
      arm-kafa           m68k-bvme6000     mips-wrppmc          sparc64
      arm-kb9202         m68k-hp300        mips-yosemite        sparc64-allnoconfig
      arm-ks8695         m68k-mac          parisc               sparc64-defconfig
      arm-lart           m68k-mvme147      parisc-allnoconfig   sparc64-up
      arm-lpd270         m68k-mvme16x      parisc-defconfig     um-x86_64
      arm-lpd7a400       m68k-q40          parisc-up            x86_64
      arm-lpd7a404       m68k-sun3         powerpc              x86_64-allnoconfig
      arm-lubbock        m68k-sun3x        powerpc-cell         x86_64-defconfig
      arm-lusl7200       mips              powerpc-celleb       x86_64-up
      arm-mainstone      mips-atlas        powerpc-chrp32
      Signed-off-by: NAlexey Dobriyan <adobriyan@gmail.com>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      4e950f6f
  9. 29 7月, 2007 2 次提交
  10. 28 7月, 2007 2 次提交
  11. 21 7月, 2007 9 次提交
  12. 20 7月, 2007 2 次提交
  13. 19 7月, 2007 6 次提交
    • R
      IB/mthca: Simplify use of size0 in work request posting · 43509d1f
      Roland Dreier 提交于
          
      Current code sets size0 to 0 at the start of work request posting
      functions and then handles size0 == 0 specially within the loop over
      work requests.  Change this so size0 is set along with f0 the first
      time through the loop (when nreq == 0).  This makes the code easier to
      understand by making it clearer that f0 and size0 are always
      initialized if nreq != 0 without having to know that size0 == 0
      implies nreq == 0.
      
      Also annotate size0 with uninitialized_var() so that this doesn't
      introduce a new compiler warning.
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      43509d1f
    • R
      IB/mthca: Factor out setting WQE UD segment entries · e535c699
      Roland Dreier 提交于
          
      Factor code to set UD entries out of the work request posting
      functions into inline functions set_tavor_ud_seg() and
      set_arbel_ud_seg().  This doesn't change the generated code in any
      significant way, and makes the source easier on the eyes.
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      e535c699
    • R
      IB/mthca: Factor out setting WQE remote address and atomic segment entries · 400ddc11
      Roland Dreier 提交于
          
      Factor code to set remote address and atomic segment entries out of the
      work request posting functions into inline functions set_raddr_seg()
      and set_atomic_seg().  This doesn't change the generated code in any
      significant way, and makes the source easier on the eyes.
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      400ddc11
    • R
      IB/mlx4: Factor out setting other WQE segments · 0fbfa6a9
      Roland Dreier 提交于
      Factor code to set remote address, atomic and datagram segments out of
      mlx4_ib_post_send() into small helper functions.  This doesn't change
      the generated code in any significant way, and makes the source easier
      on the eyes.
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      0fbfa6a9
    • R
      IB/mlx4: Factor out setting WQE data segment entries · d420d9e3
      Roland Dreier 提交于
      Factor code to set data segment entries out of mlx4_ib_post_send()
      into set_data_seg().  This cleans up the code and lets the compiler do
      a better job -- on x86_64:
      
      add/remove: 0/0 grow/shrink: 0/1 up/down: 0/-16 (-16)
      function                                     old     new   delta
      mlx4_ib_post_send                           1598    1582     -16
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      d420d9e3
    • R
      IB/mthca: Factor out setting WQE data segment entries · 80885456
      Roland Dreier 提交于
      Factor code to set data segment entries out of the work request
      posting functions into inline functions mthca_set_data_seg() and
      mthca_set_data_seg_inval().  This makes the code more readable and
      also allows the compiler to do a better job -- on x86_64:
      
      add/remove: 0/0 grow/shrink: 0/6 up/down: 0/-69 (-69)
      function                                     old     new   delta
      mthca_arbel_post_srq_recv                    373     369      -4
      mthca_arbel_post_receive                     570     562      -8
      mthca_tavor_post_srq_recv                    520     508     -12
      mthca_tavor_post_send                       1344    1330     -14
      mthca_arbel_post_send                       1481    1467     -14
      mthca_tavor_post_receive                     792     775     -17
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      80885456
  14. 18 7月, 2007 6 次提交
    • R
      IB/mlx4: Return receive queue sizes for userspace QPs from query QP · 7f5eb9bb
      Roland Dreier 提交于
      Return the receive queue sizes for both userspace QPs and kernel Qps
      (not just kernel QPs) from mlx4_ib_query_qp().  Also zero the send
      queue sizes for userspace QPs to avoid a possible information leak,
      and set the max_inline_data for kernel QPs to 0 since inline sends are
      not supported for kernel QPs.
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      7f5eb9bb
    • R
      IB/mthca: Use uninitialized_var() for f0 · 6d7d080e
      Roland Dreier 提交于
      Commit 9db48926 ("drivers/infiniband/hw/mthca/mthca_qp: kill uninit'd
      var warning") added "= 0" to the declarations of f0 to shut up gcc
      warnings.  However, there's no point in making the code bigger by
      initializing f0 to a random value just to get rid of a warning;
      setting f0 to 0 is no safer than just using uninitialized_var(), which
      documents the situation better and gives smaller code too.  For example, 
      on x86_64:
      
      add/remove: 0/0 grow/shrink: 0/2 up/down: 0/-16 (-16)
      function                                     old     new   delta
      mthca_tavor_post_send                       1352    1344      -8
      mthca_arbel_post_send                       1489    1481      -8
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      6d7d080e
    • R
      IB/ipath: Remove ipath_get_user_pages_nocopy() · 1743b917
      Roland Dreier 提交于
      It has no callers and is completely dead code.
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      1743b917
    • R
      IB/ipath: Make a few functions static · da9aec7b
      Roland Dreier 提交于
      Make some functions that are only used in a single .c file static.  In
      addition to being a cleanup, this shrinks the generated code.  On x86_64:
      
      add/remove: 1/3 grow/shrink: 2/1 up/down: 4777/-4956 (-179)
      function                                     old     new   delta
      handle_errors                                  -    3994   +3994
      __verbs_timer                                 42     710    +668
      ipath_do_ruc_send                           2131    2246    +115
      ipath_no_bufs_available                      136       -    -136
      ipath_disarm_senderrbufs                     639       -    -639
      ipath_ib_timer                               658       -    -658
      ipath_intr                                  5878    2355   -3523
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      da9aec7b
    • R
      IB/mthca: Fix printk format used for firmware version in warning · e4daf738
      Roland Dreier 提交于
      When warning about out-of-date firmware, current mthca code messes up
      the formatting of the version if the subminor doesn't have three
      digits.  It doesn't fill the field with 0s so we end up with:
      
          ib_mthca 0000:0b:00.0: HCA FW version 1.1.  0 is old (1.2.  0 is current).
      
      Change the format from "%3d" to "%03d" to get the right thing printed.
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      e4daf738
    • R
      IB/mthca: Schedule MSI support for removal · f6be6fbe
      Roland Dreier 提交于
      The mthca driver supports both MSI and MSI-X.  However, MSI-X works with
      all hardware that the driver handles, and provides a superset of what
      MSI does, so there's no point in having code for both.  Schedule MSI
      support for removal in 2008 to give anyone who actually needs MSI and
      who can't use MSI time to speak up.
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      f6be6fbe