Merge tag 'arc-4.14-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc
authorLinus Torvalds <torvalds@linux-foundation.org>
Fri, 8 Sep 2017 23:02:18 +0000 (16:02 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 8 Sep 2017 23:02:18 +0000 (16:02 -0700)
Pull ARC updates from Vineet Gupta:

 - Support for HSDK board hosting a Quad core HS38x4 based SoC running
   @1GHz (and some prerrquisite changes such as ability to scoot the
   kernel code/data from start of memory map etc)

 - Quite a few updates for EZChip (Mellanox) platform

 - Fixes to fault/exception printing

* tag 'arc-4.14-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc: (26 commits)
  ARC: Re-enable MMU upon Machine Check exception
  ARC: Show fault information passed to show_kernel_fault_diag()
  ARC: [plat-hsdk] initial port for HSDK board
  ARC: mm: Decouple RAM base address from kernel link address
  ARCv2: IOC: Tighten up the contraints (specifically base / size alignment)
  ARC: [plat-axs103] refactor the DT fudging code
  ARC: [plat-axs103] use clk driver #2: Add core pll node to DT to manage cpu clk
  ARC: [plat-axs103] use clk driver #1: Get rid of platform specific cpu clk setting
  ARCv2: SLC: provide a line based flush routine for debugging
  ARC: Hardcode ARCH_DMA_MINALIGN to max line length we may have
  ARC: [plat-eznps] handle extra aux regs #2: kernel/entry exit
  ARC: [plat-eznps] handle extra aux regs #1: save/restore on context switch
  ARC: [plat-eznps] avoid toggling of DPC register
  ARC: [plat-eznps] Update the init sequence of aux regs per cpu.
  ARC: [plat-eznps] new command line argument for HW scheduler at MTM
  ARC: set boot print log level to PR_INFO
  ARC: [plat-eznps] Handle user memory error same in simulation and silicon
  ARC: [plat-eznps] use schd.wft instruction instead of sleep at idle task
  ARC: create cpu specific version of arch_cpu_idle()
  ARC: [plat-eznps] spinlock aware for MTM
  ...

1  2 
Documentation/admin-guide/kernel-parameters.txt
arch/arc/include/asm/spinlock.h

                        memory contents and reserves bad memory
                        regions that are detected.
  
 +      mem_encrypt=    [X86-64] AMD Secure Memory Encryption (SME) control
 +                      Valid arguments: on, off
 +                      Default (depends on kernel configuration option):
 +                        on  (CONFIG_AMD_MEM_ENCRYPT_ACTIVE_BY_DEFAULT=y)
 +                        off (CONFIG_AMD_MEM_ENCRYPT_ACTIVE_BY_DEFAULT=n)
 +                      mem_encrypt=on:         Activate SME
 +                      mem_encrypt=off:        Do not activate SME
 +
 +                      Refer to Documentation/x86/amd-memory-encryption.txt
 +                      for details on when memory encryption can be activated.
 +
        mem_sleep_default=      [SUSPEND] Default system suspend mode:
                        s2idle  - Suspend-To-Idle
                        shallow - Power-On Suspend or equivalent (if supported)
                        In kernels built with CONFIG_NO_HZ_FULL=y, set
                        the specified list of CPUs whose tick will be stopped
                        whenever possible. The boot CPU will be forced outside
 -                      the range to maintain the timekeeping.
 -                      The CPUs in this range must also be included in the
 -                      rcu_nocbs= set.
 +                      the range to maintain the timekeeping.  Any CPUs
 +                      in this list will have their RCU callbacks offloaded,
 +                      just as if they had also been called out in the
 +                      rcu_nocbs= boot parameter.
  
        noiotrap        [SH] Disables trapped I/O port accesses.
  
        nopat           [X86] Disable PAT (page attribute table extension of
                        pagetables) support.
  
 +      nopcid          [X86-64] Disable the PCID cpu feature.
 +
        norandmaps      Don't use address space randomization.  Equivalent to
                        echo 0 > /proc/sys/kernel/randomize_va_space
  
                        If the dependencies are under your control, you can
                        turn on cpu0_hotplug.
  
+       nps_mtm_hs_ctr= [KNL,ARC]
+                       This parameter sets the maximum duration, in
+                       cycles, each HW thread of the CTOP can run
+                       without interruptions, before HW switches it.
+                       The actual maximum duration is 16 times this
+                       parameter's value.
+                       Format: integer between 1 and 255
+                       Default: 255
        nptcg=          [IA-64] Override max number of concurrent global TLB
                        purges which is reported from either PAL_VM_SUMMARY or
                        SAL PALO.
                        Allowed values are enable and disable
  
        numa_zonelist_order= [KNL, BOOT] Select zonelist order for NUMA.
 -                      one of ['zone', 'node', 'default'] can be specified
 +                      'node', 'default' can be specified
                        This can be set from sysctl after boot.
                        See Documentation/sysctl/vm.txt for details.
  
                        Run specified binary instead of /init from the ramdisk,
                        used for early userspace startup. See initrd.
  
 +      rdt=            [HW,X86,RDT]
 +                      Turn on/off individual RDT features. List is:
 +                      cmt, mbmtotal, mbmlocal, l3cat, l3cdp, l2cat, mba.
 +                      E.g. to turn on cmt and turn off mba use:
 +                              rdt=cmt,!mba
 +
        reboot=         [KNL]
                        Format (x86 or x86_64):
                                [w[arm] | c[old] | h[ard] | s[oft] | g[pio]] \
                        decrease the size and leave more room for directly
                        mapped kernel RAM.
  
 +      vmcp_cma=nn[MG] [KNL,S390]
 +                      Sets the memory size reserved for contiguous memory
 +                      allocations for the vmcp device driver.
 +
        vmhalt=         [KNL,S390] Perform z/VM CP command after system halt.
                        Format: <command>
  
  #define arch_spin_is_locked(x)        ((x)->slock != __ARCH_SPIN_LOCK_UNLOCKED__)
  #define arch_spin_lock_flags(lock, flags)     arch_spin_lock(lock)
  
 -static inline void arch_spin_unlock_wait(arch_spinlock_t *lock)
 -{
 -      smp_cond_load_acquire(&lock->slock, !VAL);
 -}
 -
  #ifdef CONFIG_ARC_HAS_LLSC
  
  static inline void arch_spin_lock(arch_spinlock_t *lock)
@@@ -247,9 -252,15 +247,15 @@@ static inline void arch_spin_lock(arch_
  
        __asm__ __volatile__(
        "1:     ex  %0, [%1]            \n"
+ #ifdef CONFIG_EZNPS_MTM_EXT
+       "       .word %3                \n"
+ #endif
        "       breq  %0, %2, 1b        \n"
        : "+&r" (val)
        : "r"(&(lock->slock)), "ir"(__ARCH_SPIN_LOCK_LOCKED__)
+ #ifdef CONFIG_EZNPS_MTM_EXT
+       , "i"(CTOP_INST_SCHD_RW)
+ #endif
        : "memory");
  
        /*
@@@ -291,6 -302,12 +297,12 @@@ static inline void arch_spin_unlock(arc
         */
        smp_mb();
  
+       /*
+        * EX is not really required here, a simple STore of 0 suffices.
+        * However this causes tasklist livelocks in SystemC based SMP virtual
+        * platforms where the systemc core scheduler uses EX as a cue for
+        * moving to next core. Do a git log of this file for details
+        */
        __asm__ __volatile__(
        "       ex  %0, [%1]            \n"
        : "+r" (val)