1. 29 8月, 2017 1 次提交
  2. 11 7月, 2017 1 次提交
  3. 25 1月, 2017 1 次提交
    • A
      MIPS: VDSO: avoid duplicate CAC_BASE definition · 1742ac26
      Arnd Bergmann 提交于
      vdso.h includes <spaces.h> implicitly after defining CONFIG_32BITS.
      This defeats the override in mach-ip27/spaces.h, leading to
      a build error that shows up in kernelci.org:
      
      In file included from arch/mips/include/asm/mach-ip27/spaces.h:29:0,
                       from arch/mips/include/asm/page.h:12,
                       from arch/mips/vdso/vdso.h:26,
                       from arch/mips/vdso/gettimeofday.c:11:
      arch/mips/include/asm/mach-generic/spaces.h:28:0: error: "CAC_BASE" redefined [-Werror]
       #define CAC_BASE  _AC(0x80000000, UL)
      
      An earlier patch tried to make the second definition conditional,
      but that patch had the #ifdef in the wrong place, and would lead
      to another warning:
      
      arch/mips/include/asm/io.h: In function 'phys_to_virt':
      arch/mips/include/asm/io.h:138:9: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast]
      
      For all I can tell, there is no other reason than vdso32 to ever
      include this file with CONFIG_32BITS set, and the vdso itself should
      never refer to the base addresses as it is running in user space,
      so adding an #ifdef here is safe.
      
      Link: https://patchwork.kernel.org/patch/9418187/
      Fixes: 3ffc17d8 ("MIPS: Adjust MIPS64 CAC_BASE to reflect Config.K0")
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Cc: Paul Burton <paul.burton@imgtec.com>
      Cc: linux-mips@linux-mips.org
      Cc: linux-kernel@vger.kernel.org
      Patchwork: https://patchwork.linux-mips.org/patch/15039/Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      1742ac26
  4. 07 10月, 2016 1 次提交
    • P
      MIPS: Adjust MIPS64 CAC_BASE to reflect Config.K0 · 3ffc17d8
      Paul Burton 提交于
      On MIPS64 we define the default CAC_BASE as one of the xkphys regions of
      the virtual address space. Since the CCA is encoded in bits 61:59 of
      xkphys addresses, fixing CAC_BASE to any particular one prevents us from
      dynamically changing the CCA as we do for MIPS32 where CAC_BASE is
      placed within kseg0. In order to make the kernel more generic, drop the
      current kludge that gives CAC_BASE CCA=3 if CONFIG_DMA_NONCOHERENT is
      selected (disregarding CONFIG_DMA_MAYBE_COHERENT) & CCA=5 (which is not
      standardised by the architecture) otherwise. Instead read Config.K0 and
      generate the appropriate offset into xkphys, presuming that either the
      bootloader or early kernel code will have configured Config.K0
      appropriately. This seems like the best option for a generic
      implementation.
      
      The ip27 spaces.h is adjusted to set its former value of CAC_BASE, since
      it's the only user of CAC_BASE from assembly (in its smp_slave_setup
      macro). This allows the generic case to focus solely on C code without
      breaking ip27.
      Signed-off-by: NPaul Burton <paul.burton@imgtec.com>
      Cc: linux-mips@linux-mips.org
      Patchwork: https://patchwork.linux-mips.org/patch/14351/Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      3ffc17d8
  5. 28 5月, 2016 1 次提交
  6. 03 4月, 2016 1 次提交
  7. 22 6月, 2015 1 次提交
    • J
      MIPS: IP27: Update/restructure CPU overrides · 0ebb2f41
      Joshua Kinard 提交于
      Inspired by Maciej's recent patch to update DEC cpu-feature-overrides.h,
      I updated IP27's as well to disable features known to not apply to the
      IP27 platform or the R10K-series of CPUs.
      
      Before:
         text    data     bss     dec     hex filename
      8616648  463200  472240 9552088  91c0d8 vmlinux
      
      After:
         text    data     bss     dec     hex filename
      8592256  471392  472240 9535888  918190 vmlinux
      
      I believe the increase in the size of the data section is for the same
      reasons as in the DEC patch.
      Signed-off-by: NJoshua Kinard <kumba@gentoo.org>
      Cc: linux-mips@linux-mips.org
      Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      0ebb2f41
  8. 01 4月, 2015 1 次提交
  9. 30 10月, 2013 1 次提交
  10. 18 9月, 2013 1 次提交
  11. 22 6月, 2013 2 次提交
    • R
      MIPS: IP27: Fix build error with CONFIG_MAPPED_KERNEL · 28963b1e
      Ralf Baechle 提交于
      Some of the TLB bit definitions in <asm/pgtable-bits.h> have become rather
      complex and are no longer usable from assembler resulting in an
      explosion like this:
      
        AS      arch/mips/kernel/head.o
      arch/mips/kernel/head.S: Assembler messages:
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: Illegal operands `li $12,(((1<<((cpu_has_rixi?(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1))))+1:(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))))+1))|(1<<(((cpu_has_rixi?(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1))))+1:(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))))+1)+1))|(5<<(((((cpu_has_rixi?(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1))))+1:(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))))+1)+1)+1)+1)))>>6)'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: missing ')'
      arch/mips/kernel/head.S:147: Error: Illegal operands `li $12,(((1<<((cpu_has_rixi?(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1))))+1:(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))))+1))|(1<<(((cpu_has_rixi?(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1))))+1:(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))))+1)+1))|(1<<((((cpu_has_rixi?(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1))))+1:(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))))+1)+1)+1))|(5<<(((((cpu_has_rixi?(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1))))+1:(cpu_has_rixi?((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))+1:((((((cpu_has_rixi?(0):(0)+1)+1)+1)+1)))))+1)+1)+1)+1)))>>6)'
      make[2]: *** [arch/mips/kernel/head.o] Error 1
      
      Since now MAPPED_KERNEL_SETUP_TLB is in platform-specific code it's safe
      to hardcode the TLB bits there.
      Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      28963b1e
    • R
      MIPS: Move gas macro MAPPED_KERNEL_SETUP_TLB to IP27-specific code. · 23946ef1
      Ralf Baechle 提交于
      It's IP27-specific and can only cause trouble in head.S.
      Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      23946ef1
  12. 01 2月, 2013 1 次提交
  13. 14 12月, 2012 1 次提交
  14. 11 10月, 2012 1 次提交
  15. 09 5月, 2012 1 次提交
    • P
      sched/numa: Rewrite the CONFIG_NUMA sched domain support · cb83b629
      Peter Zijlstra 提交于
      The current code groups up to 16 nodes in a level and then puts an
      ALLNODES domain spanning the entire tree on top of that. This doesn't
      reflect the numa topology and esp for the smaller not-fully-connected
      machines out there today this might make a difference.
      
      Therefore, build a proper numa topology based on node_distance().
      
      Since there's no fixed numa layers anymore, the static SD_NODE_INIT
      and SD_ALLNODES_INIT aren't usable anymore, the new code tries to
      construct something similar and scales some values either on the
      number of cpus in the domain and/or the node_distance() ratio.
      Signed-off-by: NPeter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Anton Blanchard <anton@samba.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Chris Metcalf <cmetcalf@tilera.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Fenghua Yu <fenghua.yu@intel.com>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: linux-alpha@vger.kernel.org
      Cc: linux-ia64@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-mips@linux-mips.org
      Cc: linuxppc-dev@lists.ozlabs.org
      Cc: linux-sh@vger.kernel.org
      Cc: Matt Turner <mattst88@gmail.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: sparclinux@vger.kernel.org
      Cc: Tony Luck <tony.luck@intel.com>
      Cc: x86@kernel.org
      Cc: Dimitri Sivanich <sivanich@sgi.com>
      Cc: Greg Pearson <greg.pearson@hp.com>
      Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
      Cc: bob.picco@oracle.com
      Cc: chris.mason@oracle.com
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Link: http://lkml.kernel.org/n/tip-r74n3n8hhuc2ynbrnp3vt954@git.kernel.orgSigned-off-by: NIngo Molnar <mingo@kernel.org>
      cb83b629
  16. 26 7月, 2011 1 次提交
  17. 30 10月, 2010 2 次提交
  18. 11 8月, 2010 1 次提交
    • F
      dma-mapping: rename ARCH_KMALLOC_MINALIGN to ARCH_DMA_MINALIGN · a6eb9fe1
      FUJITA Tomonori 提交于
      Now each architecture has the own dma_get_cache_alignment implementation.
      
      dma_get_cache_alignment returns the minimum DMA alignment.  Architectures
      define it as ARCH_KMALLOC_MINALIGN (it's used to make sure that malloc'ed
      buffer is DMA-safe; the buffer doesn't share a cache with the others).  So
      we can unify dma_get_cache_alignment implementations.
      
      This patch:
      
      dma_get_cache_alignment() needs to know if an architecture defines
      ARCH_KMALLOC_MINALIGN or not (needs to know if architecture has DMA
      alignment restriction).  However, slab.h define ARCH_KMALLOC_MINALIGN if
      architectures doesn't define it.
      
      Let's rename ARCH_KMALLOC_MINALIGN to ARCH_DMA_MINALIGN.
      ARCH_KMALLOC_MINALIGN is used only in the internals of slab/slob/slub
      (except for crypto).
      Signed-off-by: NFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
      Cc: <linux-arch@vger.kernel.org>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      a6eb9fe1
  19. 13 1月, 2010 1 次提交
    • A
      MIPS: cpumask_of_node() should handle -1 as a node · d797396f
      Anton Blanchard 提交于
      pcibus_to_node can return -1 if we cannot determine which node a pci bus
      is on. If passed -1, cpumask_of_node will negatively index the lookup array
      and pull in random data:
      
      # cat /sys/devices/pci0000:00/0000:00:01.0/local_cpus
      00000000,00000003,00000000,00000000
      # cat /sys/devices/pci0000:00/0000:00:01.0/local_cpulist
      64-65
      
      Change cpumask_of_node to check for -1 and return cpu_all_mask in this
      case:
      
      # cat /sys/devices/pci0000:00/0000:00:01.0/local_cpus
      ffffffff,ffffffff,ffffffff,ffffffff
      # cat /sys/devices/pci0000:00/0000:00:01.0/local_cpulist
      0-127
      Signed-off-by: NAnton Blanchard <anton@samba.org>
      Cc: linux-mips@linux-mips.org
      Cc: linux-kernel@vger.kernel.org
      Cc: Rusty Russell <rusty@rustcorp.com.au>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Patchwork: http://patchwork.linux-mips.org/patch/831/Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      d797396f
  20. 02 11月, 2009 1 次提交
  21. 24 9月, 2009 2 次提交
  22. 16 9月, 2009 1 次提交
    • P
      sched: Disable wakeup balancing · 182a85f8
      Peter Zijlstra 提交于
      Sysbench thinks SD_BALANCE_WAKE is too agressive and kbuild doesn't
      really mind too much, SD_BALANCE_NEWIDLE picks up most of the
      slack.
      
      On a dual socket, quad core, dual thread nehalem system:
      
      sysbench (--num_threads=16):
      
       SD_BALANCE_WAKE-: 13982 tx/s
       SD_BALANCE_WAKE+: 15688 tx/s
      
      kbuild (-j16):
      
       SD_BALANCE_WAKE-: 47.648295846  seconds time elapsed   ( +-   0.312% )
       SD_BALANCE_WAKE+: 47.608607360  seconds time elapsed   ( +-   0.026% )
      
      (same within noise)
      Signed-off-by: NPeter Zijlstra <a.p.zijlstra@chello.nl>
      LKML-Reference: <new-submission>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      182a85f8
  23. 15 9月, 2009 1 次提交
    • P
      sched: Merge select_task_rq_fair() and sched_balance_self() · c88d5910
      Peter Zijlstra 提交于
      The problem with wake_idle() is that is doesn't respect things like
      cpu_power, which means it doesn't deal well with SMT nor the recent
      RT interaction.
      
      To cure this, it needs to do what sched_balance_self() does, which
      leads to the possibility of merging select_task_rq_fair() and
      sched_balance_self().
      
      Modify sched_balance_self() to:
      
        - update_shares() when walking up the domain tree,
          (it only called it for the top domain, but it should
           have done this anyway), which allows us to remove
          this ugly bit from try_to_wake_up().
      
        - do wake_affine() on the smallest domain that contains
          both this (the waking) and the prev (the wakee) cpu for
          WAKE invocations.
      
      Then use the top-down balance steps it had to replace wake_idle().
      
      This leads to the dissapearance of SD_WAKE_BALANCE and
      SD_WAKE_IDLE_FAR, with SD_WAKE_IDLE replaced with SD_BALANCE_WAKE.
      
      SD_WAKE_AFFINE needs SD_BALANCE_WAKE to be effective.
      
      Touch all topology bits to replace the old with new SD flags --
      platforms might need re-tuning, enabling SD_BALANCE_WAKE
      conditionally on a NUMA distance seems like a good additional
      feature, magny-core and small nehalem systems would want this
      enabled, systems with slow interconnects would not.
      Signed-off-by: NPeter Zijlstra <a.p.zijlstra@chello.nl>
      LKML-Reference: <new-submission>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      c88d5910
  24. 17 6月, 2009 2 次提交
  25. 30 3月, 2009 1 次提交
  26. 11 1月, 2009 1 次提交
  27. 26 12月, 2008 1 次提交
  28. 26 11月, 2008 1 次提交
    • I
      sched: convert struct root_domain to cpumask_var_t, fix · 1c391948
      Ingo Molnar 提交于
      Mathieu Desnoyers reported this build failure on powerpc:
      
       kernel/sched.c: In function 'sd_init_NODE':
       kernel/sched.c:7319: error: non-static initialization of a flexible array member
       kernel/sched.c:7319: error: (near initialization for '(anonymous)')
      
      this happens because .span changed to cpumask_var_t, hence
      the static CPU_MASK_NONE initializers in the SD_*_INIT
      templates are not type-correct anymore.
      
      Remove them, as they default to empty anyway.
      
      Also remove them from IA64, MIPS and SH.
      Reported-by: NMathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      1c391948
  29. 11 10月, 2008 1 次提交