openrisc.lists.librecores.org archive mirror
 help / color / mirror / Atom feed
From: Stafford Horne <shorne@gmail.com>
To: LKML <linux-kernel@vger.kernel.org>
Cc: Linux OpenRISC <linux-openrisc@vger.kernel.org>,
	Stafford Horne <shorne@gmail.com>
Subject: [PATCH 0/5] OpenRISC FPU and Signal handling fixups
Date: Thu, 11 Apr 2024 19:06:27 +0100	[thread overview]
Message-ID: <20240411180644.2023991-1-shorne@gmail.com> (raw)

This series has some fixups found when I was doing a deep dive
documentation of the OpenRISC FPU support which was added in 2023.

  http://stffrdhrn.github.io/hardware/embedded/openrisc/2023/08/24/or1k-fpu-linux-and-compilers.html

The FPU handling has issues of being inefficient and also not providing the
proper state if signals are received when handling syscalls.

The series is small, so should be easy to see from the commit list but in
summary does:

 - Fixup some issues with exception handling.
 - Adds CONFIG_FPU to allow disabling FPU support
 - Fixups to e FPU handling logic moving the FPCSR state out of the kernel
   stack pt_regs and into the task_struct.

Stafford Horne (5):
  openrisc: traps: Convert printks to pr_<level> macros
  openrisc: traps: Remove calls to show_registers before die
  openrisc: traps: Don't send signals to kernel mode threads
  openrisc: Add FPU config
  openrisc: Move FPU state out of pt_regs

 arch/openrisc/Kconfig                 |   9 ++
 arch/openrisc/include/asm/fpu.h       |  22 ++++
 arch/openrisc/include/asm/processor.h |   1 +
 arch/openrisc/include/asm/ptrace.h    |   3 +-
 arch/openrisc/kernel/entry.S          |  15 +--
 arch/openrisc/kernel/process.c        |   5 +
 arch/openrisc/kernel/ptrace.c         |  18 ++--
 arch/openrisc/kernel/signal.c         |  36 ++++++-
 arch/openrisc/kernel/traps.c          | 144 ++++++++++++++------------
 9 files changed, 160 insertions(+), 93 deletions(-)
 create mode 100644 arch/openrisc/include/asm/fpu.h

-- 
2.44.0


             reply	other threads:[~2024-04-11 18:07 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-11 18:06 Stafford Horne [this message]
2024-04-11 18:06 ` [PATCH 1/5] openrisc: traps: Convert printks to pr_<level> macros Stafford Horne
2024-04-11 18:06 ` [PATCH 2/5] openrisc: traps: Remove calls to show_registers before die Stafford Horne
2024-04-11 18:06 ` [PATCH 3/5] openrisc: traps: Don't send signals to kernel mode threads Stafford Horne
2024-04-11 18:06 ` [PATCH 4/5] openrisc: Add FPU config Stafford Horne
2024-04-11 18:06 ` [PATCH 5/5] openrisc: Move FPU state out of pt_regs Stafford Horne

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240411180644.2023991-1-shorne@gmail.com \
    --to=shorne@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-openrisc@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).