1. 26 7月, 2008 1 次提交
  2. 25 7月, 2008 1 次提交
    • A
      PAGE_ALIGN(): correctly handle 64-bit values on 32-bit architectures · 27ac792c
      Andrea Righi 提交于
      On 32-bit architectures PAGE_ALIGN() truncates 64-bit values to the 32-bit
      boundary. For example:
      
      	u64 val = PAGE_ALIGN(size);
      
      always returns a value < 4GB even if size is greater than 4GB.
      
      The problem resides in PAGE_MASK definition (from include/asm-x86/page.h for
      example):
      
      #define PAGE_SHIFT      12
      #define PAGE_SIZE       (_AC(1,UL) << PAGE_SHIFT)
      #define PAGE_MASK       (~(PAGE_SIZE-1))
      ...
      #define PAGE_ALIGN(addr)       (((addr)+PAGE_SIZE-1)&PAGE_MASK)
      
      The "~" is performed on a 32-bit value, so everything in "and" with
      PAGE_MASK greater than 4GB will be truncated to the 32-bit boundary.
      Using the ALIGN() macro seems to be the right way, because it uses
      typeof(addr) for the mask.
      
      Also move the PAGE_ALIGN() definitions out of include/asm-*/page.h in
      include/linux/mm.h.
      
      See also lkml discussion: http://lkml.org/lkml/2008/6/11/237
      
      [akpm@linux-foundation.org: fix drivers/media/video/uvc/uvc_queue.c]
      [akpm@linux-foundation.org: fix v850]
      [akpm@linux-foundation.org: fix powerpc]
      [akpm@linux-foundation.org: fix arm]
      [akpm@linux-foundation.org: fix mips]
      [akpm@linux-foundation.org: fix drivers/media/video/pvrusb2/pvrusb2-dvb.c]
      [akpm@linux-foundation.org: fix drivers/mtd/maps/uclinux.c]
      [akpm@linux-foundation.org: fix powerpc]
      Signed-off-by: NAndrea Righi <righi.andrea@gmail.com>
      Cc: <linux-arch@vger.kernel.org>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      27ac792c
  3. 23 7月, 2008 5 次提交
  4. 15 7月, 2008 2 次提交
  5. 06 5月, 2008 1 次提交
  6. 30 4月, 2008 2 次提交
    • O
      mlx4_core: Avoid recycling old FMR R_Keys too soon · bbdc2821
      Olaf Kirch 提交于
      When a FMR is unmapped, mlx4 resets the map count to 0, and clears the
      upper part of the R_Key which is used as the sequence counter.
      
      This poses a problem for RDS, which uses ib_fmr_unmap as a fence
      operation.  RDS assumes that after issuing an unmap, the old R_Keys
      will be invalid for a "reasonable" period of time. For instance,
      Oracle processes uses shared memory buffers allocated from a pool of
      buffers.  When a process dies, we want to reclaim these buffers -- but
      we must make sure there are no pending RDMA operations to/from those
      buffers.  The only way to achieve that is by using unmap and sync the
      TPT.
      
      However, when the sequence count is reset on unmap, there is a high
      likelihood that a new mapping will be given the same R_Key that was
      issued a few milliseconds ago.
      
      To prevent this, don't reset the sequence count when unmapping a FMR.
      Signed-off-by: NOlaf Kirch <olaf.kirch@oracle.com>
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      bbdc2821
    • Y
      mlx4_core: Add a way to set the "collapsed" CQ flag · e463c7b1
      Yevgeny Petrilin 提交于
      Extend the mlx4_cq_resize() API with a way to set the "collapsed" flag
      for the CQ being created.
      Signed-off-by: NYevgeny Petrilin <yevgenyp@mellanox.co.il>
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      e463c7b1
  7. 26 4月, 2008 2 次提交
  8. 24 4月, 2008 2 次提交
  9. 17 4月, 2008 9 次提交
  10. 15 2月, 2008 1 次提交
  11. 12 2月, 2008 1 次提交
    • O
      mlx4_core: Fix build break (missing include) · 29c27112
      Olof Johansson 提交于
      Commit 313abe55 ("mlx4_core: For 64-bit systems, vmap() kernel queue
      buffers") caused this to pop up on powerpc allyesconfig, looks like a
      missing include file:
      
          drivers/net/mlx4/alloc.c: In function 'mlx4_buf_alloc':
          drivers/net/mlx4/alloc.c:162: error: implicit declaration of function 'vmap'
          drivers/net/mlx4/alloc.c:162: error: 'VM_MAP' undeclared (first use in this function)
          drivers/net/mlx4/alloc.c:162: error: (Each undeclared identifier is reported only once
          drivers/net/mlx4/alloc.c:162: error: for each function it appears in.)
          drivers/net/mlx4/alloc.c:162: warning: assignment makes pointer from integer without a cast
          drivers/net/mlx4/alloc.c: In function 'mlx4_buf_free':
          drivers/net/mlx4/alloc.c:187: error: implicit declaration of function 'vunmap'
      Signed-off-by: NOlof Johansson <olof@lixom.net>
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      29c27112
  12. 07 2月, 2008 2 次提交
  13. 05 2月, 2008 3 次提交
  14. 26 1月, 2008 1 次提交
  15. 21 11月, 2007 1 次提交
  16. 15 11月, 2007 1 次提交
  17. 14 11月, 2007 1 次提交
  18. 24 10月, 2007 1 次提交
  19. 23 10月, 2007 1 次提交
  20. 22 10月, 2007 1 次提交
  21. 14 10月, 2007 1 次提交