Merge remote-tracking branch 'sparc/master' into work.sparc32
authorAl Viro <viro@zeniv.linux.org.uk>
Mon, 4 Jan 2021 01:05:34 +0000 (20:05 -0500)
committerAl Viro <viro@zeniv.linux.org.uk>
Mon, 4 Jan 2021 01:07:31 +0000 (20:07 -0500)
... and resolve a non-textual conflict in arch/sparc/lib/memset.S -
EXT(...) stuff shouldn't be reintroduced on merge.

1  2 
arch/sparc/Kconfig
arch/sparc/mm/srmmu.c

diff --combined arch/sparc/Kconfig
@@@ -15,7 -15,6 +15,7 @@@ config SPAR
        default y
        select ARCH_MIGHT_HAVE_PC_PARPORT if SPARC64 && PCI
        select ARCH_MIGHT_HAVE_PC_SERIO
 +      select DMA_OPS
        select OF
        select OF_PROMTREE
        select HAVE_ASM_MODVERSIONS
@@@ -23,7 -22,6 +23,7 @@@
        select HAVE_OPROFILE
        select HAVE_ARCH_KGDB if !SMP || SPARC64
        select HAVE_ARCH_TRACEHOOK
 +      select HAVE_ARCH_SECCOMP if SPARC64
        select HAVE_EXIT_THREAD
        select HAVE_PCI
        select SYSCTL_EXCEPTION_TRACE
        select HAVE_EBPF_JIT if SPARC64
        select HAVE_DEBUG_BUGVERBOSE
        select GENERIC_SMP_IDLE_THREAD
 -      select GENERIC_CLOCKEVENTS
        select GENERIC_STRNCPY_FROM_USER
        select GENERIC_STRNLEN_USER
        select MODULES_USE_ELF_RELA
        select PCI_SYSCALL if PCI
 +      select PCI_MSI_ARCH_FALLBACKS if PCI_MSI
        select ODD_RT_SIGACTION
        select OLD_SIGSUSPEND
        select CPU_NO_EFFICIENT_FFS
        select LOCKDEP_SMALL if LOCKDEP
        select NEED_DMA_MAP_STATE
        select NEED_SG_DMA_LENGTH
 +      select SET_FS
  
  config SPARC32
        def_bool !64BIT
@@@ -83,11 -80,11 +83,11 @@@ config SPARC6
        select RTC_DRV_STARFIRE
        select HAVE_PERF_EVENTS
        select PERF_USE_VMALLOC
 -      select IRQ_PREFLOW_FASTEOI
        select ARCH_HAVE_NMI_SAFE_CMPXCHG
        select HAVE_C_RECORDMCOUNT
        select HAVE_ARCH_AUDITSYSCALL
        select ARCH_SUPPORTS_ATOMIC_RMW
 +      select ARCH_SUPPORTS_DEBUG_PAGEALLOC
        select HAVE_NMI
        select HAVE_REGS_AND_STACK_ACCESS_API
        select ARCH_USE_QUEUED_RWLOCKS
@@@ -139,7 -136,6 +139,7 @@@ config MM
  config HIGHMEM
        bool
        default y if SPARC32
 +      select KMAP_LOCAL
  
  config ZONE_DMA
        bool
@@@ -149,6 -145,9 +149,6 @@@ config GENERIC_ISA_DM
        bool
        default y if SPARC32
  
 -config ARCH_SUPPORTS_DEBUG_PAGEALLOC
 -      def_bool y if SPARC64
 -
  config PGTABLE_LEVELS
        default 4 if 64BIT
        default 3
@@@ -176,7 -175,7 +176,7 @@@ config SM
          Management" code will be disabled if you say Y here.
  
          See also <file:Documentation/admin-guide/lockup-watchdogs.rst> and the SMP-HOWTO
-         available at <http://www.tldp.org/docs.html#howto>.
+         available at <https://www.tldp.org/docs.html#howto>.
  
          If you don't know what to do here, say N.
  
@@@ -227,6 -226,23 +227,6 @@@ config EARLYF
        help
          Say Y here to enable a faster early framebuffer boot console.
  
 -config SECCOMP
 -      bool "Enable seccomp to safely compute untrusted bytecode"
 -      depends on SPARC64 && PROC_FS
 -      default y
 -      help
 -        This kernel feature is useful for number crunching applications
 -        that may need to compute untrusted bytecode during their
 -        execution. By using pipes or other transports made available to
 -        the process as file descriptors supporting the read/write
 -        syscalls, it's possible to isolate those applications in
 -        their own address space using seccomp. Once seccomp is
 -        enabled via /proc/<pid>/seccomp, it cannot be disabled
 -        and the task is only allowed to execute a few safe syscalls
 -        defined by each seccomp mode.
 -
 -        If unsure, say Y. Only embedded should say N here.
 -
  config HOTPLUG_CPU
        bool "Support for hot-pluggable CPUs"
        depends on SPARC64 && SMP
diff --combined arch/sparc/mm/srmmu.c
@@@ -689,7 -689,7 +689,7 @@@ static void __init srmmu_early_allocate
                pgdp = pgd_offset_k(start);
                p4dp = p4d_offset(pgdp, start);
                pudp = pud_offset(p4dp, start);
-               if (pud_none(*(pud_t *)__nocache_fix(pudp))) {
+               if (pud_none(*__nocache_fix(pudp))) {
                        pmdp = __srmmu_get_nocache(
                            SRMMU_PMD_TABLE_SIZE, SRMMU_PMD_TABLE_SIZE);
                        if (pmdp == NULL)
                        pud_set(__nocache_fix(pudp), pmdp);
                }
                pmdp = pmd_offset(__nocache_fix(pudp), start);
-               if (srmmu_pmd_none(*(pmd_t *)__nocache_fix(pmdp))) {
+               if (srmmu_pmd_none(*__nocache_fix(pmdp))) {
                        ptep = __srmmu_get_nocache(PTE_SIZE, PTE_SIZE);
                        if (ptep == NULL)
                                early_pgtable_allocfail("pte");
@@@ -810,11 -810,11 +810,11 @@@ static void __init srmmu_inherit_prom_m
                p4dp = p4d_offset(pgdp, start);
                pudp = pud_offset(p4dp, start);
                if (what == 2) {
-                       *(pgd_t *)__nocache_fix(pgdp) = __pgd(probed);
+                       *__nocache_fix(pgdp) = __pgd(probed);
                        start += PGDIR_SIZE;
                        continue;
                }
-               if (pud_none(*(pud_t *)__nocache_fix(pudp))) {
+               if (pud_none(*__nocache_fix(pudp))) {
                        pmdp = __srmmu_get_nocache(SRMMU_PMD_TABLE_SIZE,
                                                   SRMMU_PMD_TABLE_SIZE);
                        if (pmdp == NULL)
                        memset(__nocache_fix(pmdp), 0, SRMMU_PMD_TABLE_SIZE);
                        pud_set(__nocache_fix(pudp), pmdp);
                }
-               pmdp = pmd_offset(__nocache_fix(pgdp), start);
+               pmdp = pmd_offset(__nocache_fix(pudp), start);
                if (what == 1) {
                        *(pmd_t *)__nocache_fix(pmdp) = __pmd(probed);
                        start += PMD_SIZE;
                        continue;
                }
-               if (srmmu_pmd_none(*(pmd_t *)__nocache_fix(pmdp))) {
+               if (srmmu_pmd_none(*__nocache_fix(pmdp))) {
                        ptep = __srmmu_get_nocache(PTE_SIZE, PTE_SIZE);
                        if (ptep == NULL)
                                early_pgtable_allocfail("pte");
                        pmd_set(__nocache_fix(pmdp), ptep);
                }
                ptep = pte_offset_kernel(__nocache_fix(pmdp), start);
-               *(pte_t *)__nocache_fix(ptep) = __pte(probed);
+               *__nocache_fix(ptep) = __pte(probed);
                start += PAGE_SIZE;
        }
  }
@@@ -850,7 -850,7 +850,7 @@@ static void __init do_large_mapping(uns
        unsigned long big_pte;
  
        big_pte = KERNEL_PTE(phys_base >> 4);
-       *(pgd_t *)__nocache_fix(pgdp) = __pgd(big_pte);
+       *__nocache_fix(pgdp) = __pgd(big_pte);
  }
  
  /* Map sp_bank entry SP_ENTRY, starting at virtual address VBASE. */
@@@ -940,7 -940,7 +940,7 @@@ void __init srmmu_paging_init(void
        srmmu_ctx_table_phys = (ctxd_t *)__nocache_pa(srmmu_context_table);
  
        for (i = 0; i < num_contexts; i++)
-               srmmu_ctxd_set((ctxd_t *)__nocache_fix(&srmmu_context_table[i]), srmmu_swapper_pg_dir);
+               srmmu_ctxd_set(__nocache_fix(&srmmu_context_table[i]), srmmu_swapper_pg_dir);
  
        flush_cache_all();
        srmmu_set_ctable_ptr((unsigned long)srmmu_ctx_table_phys);
  
        sparc_context_init(num_contexts);
  
 -      kmap_init();
 -
        {
                unsigned long max_zone_pfn[MAX_NR_ZONES] = { 0 };