Skip to content
Snippets Groups Projects
  1. Oct 15, 2020
  2. Jul 28, 2020
  3. Apr 05, 2020
    • Firoz Khan's avatar
      parisc: remove nargs from __SYSCALL · 106c9092
      Firoz Khan authored
      
      The __SYSCALL macro's arguments are system call number,
      system call entry name and number of arguments for the
      system call.
      
      Argument- nargs in __SYSCALL(nr, entry, nargs) is neither
      calculated nor used anywhere. So it would be better to
      keep the implementaion as  __SYSCALL(nr, entry). This will
      unifies the implementation with some other architetures
      too.
      
      Signed-off-by: default avatarFiroz Khan <firoz.khan@linaro.org>
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      106c9092
  4. May 10, 2019
  5. May 05, 2019
  6. May 03, 2019
  7. Dec 10, 2018
    • Firoz Khan's avatar
      parisc: generate uapi header and system call table files · 575afc4d
      Firoz Khan authored
      
      System call table generation script must be run to gener-
      ate unistd_32/64.h and syscall_table_32/64/c32.h files.
      This patch will have changes which will invokes the script.
      
      This patch will generate unistd_32/64.h and syscall_table-
      _32/64/c32.h files by the syscall table generation script
      invoked by parisc/Makefile and the generated files against
      the removed files must be identical.
      
      The generated uapi header file will be included in uapi/-
      asm/unistd.h and generated system call table header file
      will be included by kernel/syscall.S file.
      
      Signed-off-by: default avatarFiroz Khan <firoz.khan@linaro.org>
      Acked-by: default avatarHelge Deller <deller@gmx.de>
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      575afc4d
  8. Nov 06, 2018
    • John David Anglin's avatar
      parisc: Revert "Release spinlocks using ordered store" · 86d4d068
      John David Anglin authored
      
      This reverts commit d27dfa13.
      
      Unfortunately, this patch needs to be reverted.  We need the full sync
      barrier and not the limited barrier provided by using an ordered store.
      The sync ensures that all accesses and cache purge instructions that
      follow the sync are performed after all such instructions prior the sync
      instruction have completed executing.
      
      The patch breaks the rwlock implementation in glibc.  This caused the
      test-lock application in the libprelude testsuite to hang.  With the
      change reverted, the test runs correctly and the libprelude package
      builds successfully.
      
      Signed-off-by: default avatarJohn David Anglin <dave.anglin@bell.net>
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      86d4d068
  9. Oct 17, 2018
  10. Sep 30, 2018
  11. Aug 17, 2018
  12. Aug 13, 2018
  13. Aug 08, 2018
  14. Nov 17, 2017
    • John David Anglin's avatar
      parisc: Fix validity check of pointer size argument in new CAS implementation · 05f016d2
      John David Anglin authored
      
      As noted by Christoph Biedl, passing a pointer size of 4 in the new CAS
      implementation causes a kernel crash.  The attached patch corrects the
      off by one error in the argument validity check.
      
      In reviewing the code, I noticed that we only perform word operations
      with the pointer size argument.  The subi instruction intentionally uses
      a word condition on 64-bit kernels.  Nullification was used instead of a
      cmpib instruction as the branch should never be taken.  The shlw
      pseudo-operation generates a depw,z instruction and it clears the target
      before doing a shift left word deposit.  Thus, we don't need to clip the
      upper 32 bits of this argument on 64-bit kernels.
      
      Tested with a gcc testsuite run with a 64-bit kernel.  The gcc atomic
      code in libgcc is the only direct user of the new CAS implementation
      that I am aware of.
      
      Signed-off-by: default avatarJohn David Anglin <dave.anglin@bell.net>
      Cc: stable@vger.kernel.org # 3.13+
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      05f016d2
  15. Oct 19, 2017
  16. Nov 02, 2016
  17. May 22, 2016
  18. May 06, 2016
  19. Mar 31, 2016
    • Helge Deller's avatar
      parisc: Fix and enable seccomp filter support · 910cd32e
      Helge Deller authored
      
      The seccomp filter support requires careful handling of task registers.  This
      includes reloading of the return value (%r28) and proper syscall exit if
      secure_computing() returned -1.
      
      Additionally we need to sign-extend the syscall number from signed 32bit to
      signed 64bit in do_syscall_trace_enter() since the ptrace interface only allows
      storing 32bit values in compat mode.
      
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      Cc: stable@vger.kernel.org # v4.5
      910cd32e
  20. Mar 01, 2016
    • Helge Deller's avatar
      parisc: Fix ptrace syscall number and return value modification · 98e8b6c9
      Helge Deller authored
      
      Mike Frysinger reported that his ptrace testcase showed strange
      behaviour on parisc: It was not possible to avoid a syscall and the
      return value of a syscall couldn't be changed.
      
      To modify a syscall number, we were missing to save the new syscall
      number to gr20 which is then picked up later in assembly again.
      
      The effect that the return value couldn't be changed is a side-effect of
      another bug in the assembly code. When a process is ptraced, userspace
      expects each syscall to report entrance and exit of a syscall.  If a
      syscall number was given which doesn't exist, we jumped to the normal
      syscall exit code instead of informing userspace that the (non-existant)
      syscall exits. This unexpected behaviour confuses userspace and thus the
      bug was misinterpreted as if we can't change the return value.
      
      This patch fixes both problems and was tested on 64bit kernel with
      32bit userspace.
      
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      Cc: Mike Frysinger <vapier@gentoo.org>
      Cc: stable@vger.kernel.org  # v4.0+
      Tested-by: default avatarMike Frysinger <vapier@gentoo.org>
      98e8b6c9
  21. Nov 22, 2015
  22. Sep 08, 2015
  23. Sep 13, 2014
  24. May 15, 2014
    • John David Anglin's avatar
      parisc: Improve LWS-CAS performance · c776cd89
      John David Anglin authored
      
      The attached change significantly improves the performance of the LWS-CAS code
      in syscall.S.
      This allows a number of packages to build (e.g., zeromq3, gtest and libxs)
      that previously failed because slow LWS-CAS performance under contention. In
      particular, interrupts taken while the lock was taken degraded performance
      significantly.
      
      The change does the following:
      
      1) Disables interrupts around the CAS operation, and
      2) Changes the loads and stores to use the ordered completer, "o", on
      PA 2.0. "o" and "ma" with a zero offset are equivalent. The latter is
      accepted on both PA 1.X and 2.0.
      
      The use of ordered loads and stores probably makes no difference on all
      existing hardware, but it seemed pedantically correct. In particular, the CAS
      operation must complete before LDCW lock is released. As written before, a
      processor could reorder the operations.
      
      I don't believe the period interrupts are disabled is long enough to
      significantly increase interrupt latency. For example, the TLB insert code is
      longer. Worst case is a memory fault in the CAS operation.
      
      Signed-off-by: default avatarJohn David Anglin <dave.anglin@bell.net>
      Cc: stable@vger.kernel.org # 3.13+
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      c776cd89
  25. Nov 07, 2013
    • Helge Deller's avatar
      parisc: provide macro to create exception table entries · 61dbbaeb
      Helge Deller authored
      
      Provide a macro ASM_EXCEPTIONTABLE_ENTRY() to create exception table
      entries and convert all open-coded places to use that macro.
      
      This patch is a first step toward creating a exception table which only
      holds 32bit pointers even on a 64bit kernel. That way in my own kernel
      I was able to reduce the in-kernel exception table from 44kB to 22kB.
      
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      61dbbaeb
  26. May 06, 2013
    • Helge Deller's avatar
      parisc: document the parisc gateway page · dde39798
      Helge Deller authored
      
      Include some documentation about how the parisc gateway page technically
      works and how it is used from userspace.
      
      James Bottomley is the original author of this description and it was
      copied here out of an email thread from Apr 12 2013 titled:
      man2 : syscall.2 : document syscall calling conventions
      
      CC: James Bottomley <James.Bottomley@HansenPartnership.com>
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      dde39798
    • Helge Deller's avatar
      parisc: fix partly 16/64k PAGE_SIZE boot · 6a45716a
      Helge Deller authored
      
      This patch fixes partly PAGE_SIZEs of 16K or 64K by adjusting the
      assembler PTE lookup code and the assembler TEMPALIAS code.  Furthermore
      some data alignments for PAGE_SIZE have been limited to 4K (or less) to
      not waste too much memory with greater page sizes. As a side note, the
      palo loader can (currently) only handle up to 10 ELF segments which is
      fixed with tighter aligning as well.
      
      My testings indicated that the ldci command in the sba iommu coding
      needed adjustment by the PAGE_SHIFT value and that the I/O PDIR Page
      size was only set to 4K for my machine (C3000).
      
      All this fixes partly the boot, but there are still quite some caching
      problems left.  Examples are e.g. the symbios logic driver which is
      failing:
      
      sym0: <896> rev 0x7 at pci 0000:00:0f.0 irq 69
      sym0: PA-RISC Firmware, ID 7, Fast-40, SE, parity checking
      CACHE TEST FAILED: DMA error (dstat=0x81).sym0: CACHE INCORRECTLY CONFIGURED.
      
      and the tulip network driver which doesn't seem to work correctly
      either:
      
      Sending BOOTP requests .net eth0: Setting full-duplex based on MII#1
      link partner capability of 05e1
      ..... timed out!
      
      Beside those kernel fixes glibc will need fixes too to be able to handle
      >4K page sizes.
      
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      6a45716a
  27. Feb 20, 2013
    • Al Viro's avatar
      parisc: fix ptrace breakage · 52ab532e
      Al Viro authored
      
      1) PTRACE_SYSCALL doesn't work for 64bit process on parisc64.
      Compat syscall table is used instead of 64bit one.  IMO we should either
      refuse to allow PTRACE_SYSCALL for 64bit processes or duplicate the
      logics choosing the right syscall table into .Ltracesys.
      
      	2) if you have let the tracee run with PTRACE_SYSCALL and
      it had stopped, you can use PTRACE_POKEUSR to modify syscall number
      (r20) and arguments 1--4 (r26--r23).  Modifications will have effect.
      However, modifying arguments 5 and 6 (r22 and r21 resp.) works only
      when process (32bit one) runs on 64bit host - on 32bit one it has no
      effect.  AFAICS, the diff below should fix that one.
      
      Signed-off-by: default avatarAl Viro <viro@ZenIV.linux.org.uk>
      Tested-by: default avatarJohn David Anglin <dave.anglin@bell.net>
      Signed-off-by: default avatarHelge Deller <deller@gmx.de>
      52ab532e
  28. Oct 01, 2012
  29. Mar 31, 2011
  30. May 30, 2010
  31. Sep 28, 2009
Loading