All of lore.kernel.org
 help / color / mirror / Atom feed
From: Al Viro <viro@zeniv.linux.org.uk>
To: linux-arch@vger.kernel.org
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
	linux-parisc@vger.kernel.org, Vineet Gupta <vgupta@kernel.org>
Subject: [PATCH 1/3] parisc: get rid of private asm/unaligned.h
Date: Tue, 1 Oct 2024 20:51:58 +0100	[thread overview]
Message-ID: <20241001195158.GA4135693@ZenIV> (raw)
In-Reply-To: <20241001195107.GA4017910@ZenIV>

Declarations local to arch/*/kernel/*.c are better off *not* in a public
header - arch/parisc/kernel/unaligned.h is just fine for those
bits.

With that done parisc asm/unaligned.h is reduced to include
of asm-generic/unaligned.h and can be removed - unaligned.h is in
mandatory-y in include/asm-generic/Kbuild.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
---
 arch/parisc/include/asm/unaligned.h | 11 -----------
 arch/parisc/kernel/traps.c          |  2 ++
 arch/parisc/kernel/unaligned.c      |  1 +
 arch/parisc/kernel/unaligned.h      |  3 +++
 4 files changed, 6 insertions(+), 11 deletions(-)
 delete mode 100644 arch/parisc/include/asm/unaligned.h
 create mode 100644 arch/parisc/kernel/unaligned.h

diff --git a/arch/parisc/include/asm/unaligned.h b/arch/parisc/include/asm/unaligned.h
deleted file mode 100644
index c0621295100d..000000000000
--- a/arch/parisc/include/asm/unaligned.h
+++ /dev/null
@@ -1,11 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0 */
-#ifndef _ASM_PARISC_UNALIGNED_H
-#define _ASM_PARISC_UNALIGNED_H
-
-#include <asm-generic/unaligned.h>
-
-struct pt_regs;
-void handle_unaligned(struct pt_regs *regs);
-int check_unaligned(struct pt_regs *regs);
-
-#endif /* _ASM_PARISC_UNALIGNED_H */
diff --git a/arch/parisc/kernel/traps.c b/arch/parisc/kernel/traps.c
index 294b0e026c9a..a111d7362d56 100644
--- a/arch/parisc/kernel/traps.c
+++ b/arch/parisc/kernel/traps.c
@@ -47,6 +47,8 @@
 #include <linux/kgdb.h>
 #include <linux/kprobes.h>
 
+#include "unaligned.h"
+
 #if defined(CONFIG_LIGHTWEIGHT_SPINLOCK_CHECK)
 #include <asm/spinlock.h>
 #endif
diff --git a/arch/parisc/kernel/unaligned.c b/arch/parisc/kernel/unaligned.c
index 3e79e40e361d..99897107d800 100644
--- a/arch/parisc/kernel/unaligned.c
+++ b/arch/parisc/kernel/unaligned.c
@@ -15,6 +15,7 @@
 #include <asm/unaligned.h>
 #include <asm/hardirq.h>
 #include <asm/traps.h>
+#include "unaligned.h"
 
 /* #define DEBUG_UNALIGNED 1 */
 
diff --git a/arch/parisc/kernel/unaligned.h b/arch/parisc/kernel/unaligned.h
new file mode 100644
index 000000000000..c1aa4b12e284
--- /dev/null
+++ b/arch/parisc/kernel/unaligned.h
@@ -0,0 +1,3 @@
+struct pt_regs;
+void handle_unaligned(struct pt_regs *regs);
+int check_unaligned(struct pt_regs *regs);
-- 
2.39.5


  reply	other threads:[~2024-10-01 19:52 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-01 19:51 [RFC][PATCHES] asm/unaligned.h removal Al Viro
2024-10-01 19:51 ` Al Viro [this message]
2024-10-02  0:57   ` [PATCH 1/3] parisc: get rid of private asm/unaligned.h Helge Deller
2024-10-02  3:23     ` Al Viro
2024-10-02  8:10   ` Rolf Eike Beer
2024-10-01 19:53 ` [PATCH 2/3] arc: " Al Viro
2024-10-02 21:03   ` Vineet Gupta
2024-10-02 21:24     ` Al Viro
2024-10-01 19:54 ` [PATCH 3/3] move asm/unaligned.h to linux/unaligned.h Al Viro
2024-10-01 20:34 ` [RFC][PATCHES] asm/unaligned.h removal Al Viro
2024-10-02 18:33 ` Linus Torvalds
2024-10-02 22:17   ` Al Viro
2024-10-02 23:36     ` [git pull] " Al Viro
2024-10-03  0:04       ` pr-tracker-bot

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=20241001195158.GA4135693@ZenIV \
    --to=viro@zeniv.linux.org.uk \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-parisc@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=vgupta@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.