1. 03 6月, 2011 1 次提交
  2. 23 5月, 2010 2 次提交
    • R
      Blackfin: optimize strncpy a bit · 648eee52
      Robin Getz 提交于
      Add a little strncpy optimization which can easily cut boot time by 20%.
      
      When the kernel is booting with initramfs, it builds up the filesystem
      from a cpio archive by calling strncpy_from_user() via fs/namei.c's
      do_getname() on every file in the archive (which can be lots) with a
      length of PATH_MAX (1024).  This causes the dest of the strncpy to be
      padded with many NUL bytes.
      
      This optimization mostly causes these NUL bytes to be padded with a call
      to memset() which is already optimized for filling memory quickly, but
      the hardware loop helps a little bit as well.
      
      Boot time measured with 'loglevel=0' so UART speed doesn't get in the way.
      Signed-off-by: NRobin Getz <robin.getz@analog.com>
      Signed-off-by: NMike Frysinger <vapier@gentoo.org>
      648eee52
    • R
      Blackfin: move string functions to normal lib/ assembly · 479ba603
      Robin Getz 提交于
      Since 'extern inline' doesn't work correctly in the context of the Linux
      kernel (too many overriding defines), move the string functions to normal
      lib/ assembly files (like the existing mem funcs).  This avoids the forced
      inline all over the kernel and allows us to place them constantly in L1.
      
      This also avoids some module failures when gcc inserts calls to string
      functions but the kernel build system doesn't fully consult the library
      archives.
      Signed-off-by: NRobin Getz <robin.getz@analog.com>
      Signed-off-by: NMike Frysinger <vapier@gentoo.org>
      479ba603