1. 07 6月, 2007 4 次提交
  2. 17 5月, 2007 1 次提交
    • C
      Remove SLAB_CTOR_CONSTRUCTOR · a35afb83
      Christoph Lameter 提交于
      SLAB_CTOR_CONSTRUCTOR is always specified. No point in checking it.
      Signed-off-by: NChristoph Lameter <clameter@sgi.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Jens Axboe <jens.axboe@oracle.com>
      Cc: Steven French <sfrench@us.ibm.com>
      Cc: Michael Halcrow <mhalcrow@us.ibm.com>
      Cc: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
      Cc: Miklos Szeredi <miklos@szeredi.hu>
      Cc: Steven Whitehouse <swhiteho@redhat.com>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      Cc: David Woodhouse <dwmw2@infradead.org>
      Cc: Dave Kleikamp <shaggy@austin.ibm.com>
      Cc: Trond Myklebust <trond.myklebust@fys.uio.no>
      Cc: "J. Bruce Fields" <bfields@fieldses.org>
      Cc: Anton Altaparmakov <aia21@cantab.net>
      Cc: Mark Fasheh <mark.fasheh@oracle.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Christoph Hellwig <hch@lst.de>
      Cc: Jan Kara <jack@ucw.cz>
      Cc: David Chinner <dgc@sgi.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      a35afb83
  3. 08 5月, 2007 1 次提交
    • C
      slab allocators: Remove SLAB_DEBUG_INITIAL flag · 50953fe9
      Christoph Lameter 提交于
      I have never seen a use of SLAB_DEBUG_INITIAL.  It is only supported by
      SLAB.
      
      I think its purpose was to have a callback after an object has been freed
      to verify that the state is the constructor state again?  The callback is
      performed before each freeing of an object.
      
      I would think that it is much easier to check the object state manually
      before the free.  That also places the check near the code object
      manipulation of the object.
      
      Also the SLAB_DEBUG_INITIAL callback is only performed if the kernel was
      compiled with SLAB debugging on.  If there would be code in a constructor
      handling SLAB_DEBUG_INITIAL then it would have to be conditional on
      SLAB_DEBUG otherwise it would just be dead code.  But there is no such code
      in the kernel.  I think SLUB_DEBUG_INITIAL is too problematic to make real
      use of, difficult to understand and there are easier ways to accomplish the
      same effect (i.e.  add debug code before kfree).
      
      There is a related flag SLAB_CTOR_VERIFY that is frequently checked to be
      clear in fs inode caches.  Remove the pointless checks (they would even be
      pointless without removeal of SLAB_DEBUG_INITIAL) from the fs constructors.
      
      This is the last slab flag that SLUB did not support.  Remove the check for
      unimplemented flags from SLUB.
      Signed-off-by: NChristoph Lameter <clameter@sgi.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      50953fe9
  4. 24 4月, 2007 5 次提交
  5. 13 4月, 2007 1 次提交
  6. 13 2月, 2007 2 次提交
  7. 09 12月, 2006 1 次提交
  8. 08 12月, 2006 2 次提交
  9. 04 12月, 2006 4 次提交
    • J
      [POWERPC] spufs: return an error in spu_create is isolated create isnt supported · bd2e5f82
      Jeremy Kerr 提交于
      This changes the spu_create system call to return an error (-ENODEV) if
      and isolated spu context is requested on hardware that doesn't support
      isolated mode.
      
      Tested on systemsim with and without isolation support
      Signed-off-by: NJeremy Kerr <jk@ozlabs.org>
      Signed-off-by: NArnd Bergmann <arnd.bergmann@de.ibm.com>
      bd2e5f82
    • D
      [POWERPC] coredump: Add SPU elf notes to coredump. · bf1ab978
      Dwayne Grant McConnell 提交于
      This patch adds SPU elf notes to the coredump. It creates a separate note
      for each of /regs, /fpcr, /lslr, /decr, /decr_status, /mem, /signal1,
      /signal1_type, /signal2, /signal2_type, /event_mask, /event_status,
      /mbox_info, /ibox_info, /wbox_info, /dma_info, /proxydma_info, /object-id.
      
      A new macro, ARCH_HAVE_EXTRA_NOTES, was created for architectures to
      specify they have extra elf core notes.
      
      A new macro, ELF_CORE_EXTRA_NOTES_SIZE, was created so the size of the
      additional notes could be calculated and added to the notes phdr entry.
      
      A new macro, ELF_CORE_WRITE_EXTRA_NOTES, was created so the new notes
      would be written after the existing notes.
      
      The SPU coredump code resides in spufs. Stub functions are provided in the
      kernel which are hooked into the spufs code which does the actual work via
      register_arch_coredump_calls().
      
      A new set of __spufs_<file>_read/get() functions was provided to allow the
      coredump code to read from the spufs files without having to lock the
      SPU context for each file read from.
      
      Cc: <linux-arch@vger.kernel.org>
      Signed-off-by: NDwayne Grant McConnell <decimal@us.ibm.com>
      Signed-off-by: NArnd Bergmann <arnd.bergmann@de.ibm.com>
      bf1ab978
    • J
      [POWERPC] spufs: Load isolation kernel from spu_run · c6730ed4
      Jeremy Kerr 提交于
      In order to fit with the "don't-run-spus-outside-of-spu_run" model, this
      patch starts the isolated-mode loader in spu_run, rather than
      spu_create. If spu_run is passed an isolated-mode context that isn't in
      isolated mode state, it will run the loader.
      
      This fixes potential races with the isolated SPE app doing a
      stop-and-signal before the PPE has called spu_run: bugzilla #29111.
      Also (in conjunction with a mambo patch), this addresses #28565, as we
      always set the runcntrl register when entering spu_run.
      
      It is up to libspe to ensure that isolated-mode apps are cleaned up
      after running to completion - ie, put the app through the "ISOLATE EXIT"
      state (see Ch11 of the CBEA).
      Signed-off-by: NJeremy Kerr <jk@ozlabs.org>
      Signed-off-by: NArnd Bergmann <arnd.bergmann@de.ibm.com>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      c6730ed4
    • A
      [POWERPC] spufs: Use SPU master control to prevent wild SPU execution · ee2d7340
      Arnd Bergmann 提交于
      When the user changes the runcontrol register, an SPU might be
      running without a process being attached to it and waiting for
      events. In order to prevent this, make sure we always disable
      the priv1 master control when we're not inside of spu_run.
      Signed-off-by: NArnd Bergmann <arnd.bergmann@de.ibm.com>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      ee2d7340
  10. 25 10月, 2006 3 次提交
    • J
      [POWERPC] spufs: Add isolated-mode SPE recycling support · 099814bb
      Jeremy Kerr 提交于
      When in isolated mode, SPEs have access to an area of persistent
      storage, which is per-SPE. In order for isolated-mode apps to
      communicate arbitrary data through this storage, we need to ensure that
      isolated physical SPEs can be reused for subsequent applications.
      
      Add a file ("recycle") in a spethread dir to enable isolated-mode
      recycling. By writing to this file, the kernel will reload the
      isolated-mode loader kernel, allowing a new app to be run on the same
      physical SPE.
      
      This requires the spu_acquire_exclusive function to enforce exclusive
      access to the SPE while the loader is initialised.
      Signed-off-by: NJeremy Kerr <jk@ozlabs.org>
      Signed-off-by: NArnd Bergmann <arnd.bergmann@de.ibm.com>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      099814bb
    • A
      [POWERPC] spufs: allow isolated mode apps by starting the SPE loader · 0afacde3
      arnd@arndb.de 提交于
      This patch adds general support for isolated mode SPE apps.
      
      Isolated apps are started indirectly, by a dedicated loader "kernel".
      This patch starts the loader when spe_create is invoked with the
      ISOLATE flag. We do this at spe_create time to allow libspe to pass the
      isolated app in before calling spe_run.
      
      The loader is read from the device tree, at the location
      "/spu-isolation/loader". If the loader is not present, an attempt to
      start an isolated SPE binary will fail with -ENODEV.
      
      Update: loader needs to be correctly aligned - copy to a kmalloced buf.
      Update: remove workaround for systemsim/spurom 'L-bit' bug, which has
              been fixed.
      Update: don't write to runcntl on spu_run_init: SPU is already running.
      Update: do spu_setup_isolated earlier
      
      Tested on systemsim.
      Signed-off-by: NJeremy Kerr <jk@ozlabs.org>
      Signed-off-by: NArnd Bergmann <arnd.bergmann@de.ibm.com>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      0afacde3
    • M
      [POWERPC] spufs: add support for nonschedulable contexts · 5737edd1
      Mark Nutter 提交于
      This adds two new flags to spu_create:
      
      SPU_CREATE_NONSCHED: create a context that is never moved
      away from an SPE once it has started running. This flag
      can only be used by tasks with the CAP_SYS_NICE capability.
      
      SPU_CREATE_ISOLATED: create a nonschedulable context that
      enters isolation mode upon first run. This requires the
      SPU_CREATE_NONSCHED flag.
      Signed-off-by: NJeremy Kerr <jk@ozlabs.org>
      Signed-off-by: NArnd Bergmann <arnd.bergmann@de.ibm.com>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      5737edd1
  11. 05 10月, 2006 2 次提交
    • A
      [POWERPC] spufs: Add infrastructure needed for gang scheduling · 6263203e
      Arnd Bergmann 提交于
      Add the concept of a gang to spufs as a new type of object.
      So far, this has no impact whatsover on scheduling, but makes
      it possible to add that later.
      
      A new type of object in spufs is now a spu_gang. It is created
      with the spu_create system call with the flags argument set
      to SPU_CREATE_GANG (0x2). Inside of a spu_gang, it
      is then possible to create spu_context objects, which until
      now was only possible at the root of spufs.
      
      There is a new member in struct spu_context pointing to
      the spu_gang it belongs to, if any. The spu_gang maintains
      a list of spu_context structures that are its children.
      This information can then be used in the scheduler in the
      future.
      
      There is still a bug that needs to be resolved in this
      basic infrastructure regarding the order in which objects
      are removed. When the spu_gang file descriptor is closed
      before the spu_context descriptors, we leak the dentry
      and inode for the gang. Any ideas how to cleanly solve
      this are appreciated.
      Signed-off-by: NArnd Bergmann <arnd.bergmann@de.ibm.com>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      6263203e
    • A
      [POWERPC] spufs: implement error event delivery to user space · 9add11da
      Arnd Bergmann 提交于
      This tries to fix spufs so we have an interface closer to what is
      specified in the man page for events returned in the third argument of
      spu_run.
      
      Fortunately, libspe has never been using the returned contents of that
      register, as they were the same as the return code of spu_run (duh!).
      
      Unlike the specification that we never implemented correctly, we now
      require a SPU_CREATE_EVENTS_ENABLED flag passed to spu_create, in
      order to get the new behavior. When this flag is not passed, spu_run
      will simply ignore the third argument now.
      Signed-off-by: NArnd Bergmann <arnd.bergmann@de.ibm.com>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      9add11da
  12. 27 9月, 2006 2 次提交
    • T
      [PATCH] inode-diet: Eliminate i_blksize from the inode structure · ba52de12
      Theodore Ts'o 提交于
      This eliminates the i_blksize field from struct inode.  Filesystems that want
      to provide a per-inode st_blksize can do so by providing their own getattr
      routine instead of using the generic_fillattr() function.
      
      Note that some filesystems were providing pretty much random (and incorrect)
      values for i_blksize.
      
      [bunk@stusta.de: cleanup]
      [akpm@osdl.org: generic_fillattr() fix]
      Signed-off-by: N"Theodore Ts'o" <tytso@mit.edu>
      Signed-off-by: NAdrian Bunk <bunk@stusta.de>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      ba52de12
    • T
      [PATCH] inode_diet: Replace inode.u.generic_ip with inode.i_private · 8e18e294
      Theodore Ts'o 提交于
      The following patches reduce the size of the VFS inode structure by 28 bytes
      on a UP x86.  (It would be more on an x86_64 system).  This is a 10% reduction
      in the inode size on a UP kernel that is configured in a production mode
      (i.e., with no spinlock or other debugging functions enabled; if you want to
      save memory taken up by in-core inodes, the first thing you should do is
      disable the debugging options; they are responsible for a huge amount of bloat
      in the VFS inode structure).
      
      This patch:
      
      The filesystem or device-specific pointer in the inode is inside a union,
      which is pretty pointless given that all 30+ users of this field have been
      using the void pointer.  Get rid of the union and rename it to i_private, with
      a comment to explain who is allowed to use the void pointer.  This is just a
      cleanup, but it allows us to reuse the union 'u' for something something where
      the union will actually be used.
      
      [judith@osdl.org: powerpc build fix]
      Signed-off-by: N"Theodore Ts'o" <tytso@mit.edu>
      Signed-off-by: NJudith Lebzelter <judith@osdl.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      8e18e294
  13. 23 6月, 2006 1 次提交
    • D
      [PATCH] VFS: Permit filesystem to override root dentry on mount · 454e2398
      David Howells 提交于
      Extend the get_sb() filesystem operation to take an extra argument that
      permits the VFS to pass in the target vfsmount that defines the mountpoint.
      
      The filesystem is then required to manually set the superblock and root dentry
      pointers.  For most filesystems, this should be done with simple_set_mnt()
      which will set the superblock pointer and then set the root dentry to the
      superblock's s_root (as per the old default behaviour).
      
      The get_sb() op now returns an integer as there's now no need to return the
      superblock pointer.
      
      This patch permits a superblock to be implicitly shared amongst several mount
      points, such as can be done with NFS to avoid potential inode aliasing.  In
      such a case, simple_set_mnt() would not be called, and instead the mnt_root
      and mnt_sb would be set directly.
      
      The patch also makes the following changes:
      
       (*) the get_sb_*() convenience functions in the core kernel now take a vfsmount
           pointer argument and return an integer, so most filesystems have to change
           very little.
      
       (*) If one of the convenience function is not used, then get_sb() should
           normally call simple_set_mnt() to instantiate the vfsmount. This will
           always return 0, and so can be tail-called from get_sb().
      
       (*) generic_shutdown_super() now calls shrink_dcache_sb() to clean up the
           dcache upon superblock destruction rather than shrink_dcache_anon().
      
           This is required because the superblock may now have multiple trees that
           aren't actually bound to s_root, but that still need to be cleaned up. The
           currently called functions assume that the whole tree is rooted at s_root,
           and that anonymous dentries are not the roots of trees which results in
           dentries being left unculled.
      
           However, with the way NFS superblock sharing are currently set to be
           implemented, these assumptions are violated: the root of the filesystem is
           simply a dummy dentry and inode (the real inode for '/' may well be
           inaccessible), and all the vfsmounts are rooted on anonymous[*] dentries
           with child trees.
      
           [*] Anonymous until discovered from another tree.
      
       (*) The documentation has been adjusted, including the additional bit of
           changing ext2_* into foo_* in the documentation.
      
      [akpm@osdl.org: convert ipath_fs, do other stuff]
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      Acked-by: NAl Viro <viro@zeniv.linux.org.uk>
      Cc: Nathan Scott <nathans@sgi.com>
      Cc: Roland Dreier <rolandd@cisco.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      454e2398
  14. 21 6月, 2006 2 次提交
  15. 29 3月, 2006 1 次提交
  16. 28 3月, 2006 1 次提交
  17. 27 3月, 2006 1 次提交
    • M
      [PATCH] spufs: enable SPE problem state MMIO access. · 6df10a82
      Mark Nutter 提交于
      This patch is layered on top of CONFIG_SPARSEMEM
      and is patterned after direct mapping of LS.
      
      This patch allows mmap() of the following regions:
      "mfc", which represents the area from [0x3000 - 0x3fff];
      "cntl", which represents the area from [0x4000 - 0x4fff];
      "signal1" which begins at offset 0x14000; "signal2" which
      begins at offset 0x1c000.
      
      The signal1 & signal2 files may be mmap()'d by regular user
      processes.  The cntl and mfc file, on the other hand, may
      only be accessed if the owning process has CAP_SYS_RAWIO,
      because they have the potential to confuse the kernel
      with regard to parallel access to the same files with
      regular file operations: the kernel always holds a spinlock
      when accessing registers in these areas to serialize them,
      which can not be guaranteed with user mmaps,
      Signed-off-by: NArnd Bergmann <arnd.bergmann@de.ibm.com>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      6df10a82
  18. 11 1月, 2006 1 次提交
  19. 10 1月, 2006 1 次提交
  20. 09 1月, 2006 4 次提交