mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Subject: [PATCH 05/21] ARM: include: remove unused <asm/processor.h>
Date: Mon, 13 Apr 2020 09:51:48 +0200	[thread overview]
Message-ID: <20200413075204.17544-6-a.fatoum@pengutronix.de> (raw)
In-Reply-To: <20200413075204.17544-1-a.fatoum@pengutronix.de>

File has been in source tree for 17 years and is unused.
Drop it. The only definition we might want out of the file is
cpu_relax(), which we already open code as barrier() with a comment in a
couple of places. Move the definition to <linux/barebox-wrapper.h>
and drop the file altogether.

No functional change.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 arch/arm/include/asm/processor.h | 131 -------------------------------
 include/linux/barebox-wrapper.h  |   2 +
 2 files changed, 2 insertions(+), 131 deletions(-)
 delete mode 100644 arch/arm/include/asm/processor.h

diff --git a/arch/arm/include/asm/processor.h b/arch/arm/include/asm/processor.h
deleted file mode 100644
index d5dbab0ac283..000000000000
--- a/arch/arm/include/asm/processor.h
+++ /dev/null
@@ -1,131 +0,0 @@
-/*
- *  linux/include/asm-arm/processor.h
- *
- *  Copyright (C) 1995-2002 Russell King
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License version 2 as
- * published by the Free Software Foundation.
- */
-
-#ifndef __ASM_ARM_PROCESSOR_H
-#define __ASM_ARM_PROCESSOR_H
-
-/*
- * Default implementation of macro that returns current
- * instruction pointer ("program counter").
- */
-#define current_text_addr() ({ __label__ _l; _l: &&_l;})
-
-#define FP_SIZE 35
-
-struct fp_hard_struct {
-	unsigned int save[FP_SIZE];		/* as yet undefined */
-};
-
-struct fp_soft_struct {
-	unsigned int save[FP_SIZE];		/* undefined information */
-};
-
-union fp_state {
-	struct fp_hard_struct	hard;
-	struct fp_soft_struct	soft;
-};
-
-typedef unsigned long mm_segment_t;		/* domain register	*/
-
-#ifdef __KERNEL__
-
-#define EISA_bus 0
-#define MCA_bus 0
-#define MCA_bus__is_a_macro
-
-#include <asm/atomic.h>
-#include <asm/ptrace.h>
-#include <asm/proc/processor.h>
-#include <asm/types.h>
-
-union debug_insn {
-	u32	arm;
-	u16	thumb;
-};
-
-struct debug_entry {
-	u32			address;
-	union debug_insn	insn;
-};
-
-struct debug_info {
-	int			nsaved;
-	struct debug_entry	bp[2];
-};
-
-struct thread_struct {
-	atomic_t			refcount;
-							/* fault info	  */
-	unsigned long			address;
-	unsigned long			trap_no;
-	unsigned long			error_code;
-							/* floating point */
-	union fp_state			fpstate;
-							/* debugging	  */
-	struct debug_info		debug;
-							/* context info	  */
-	struct context_save_struct	*save;
-	EXTRA_THREAD_STRUCT
-};
-
-#define INIT_THREAD  {					\
-	refcount:	ATOMIC_INIT(1),			\
-	EXTRA_THREAD_STRUCT_INIT			\
-}
-
-/*
- * Return saved PC of a blocked thread.
- */
-static inline unsigned long thread_saved_pc(struct thread_struct *t)
-{
-	return t->save ? pc_pointer(t->save->pc) : 0;
-}
-
-static inline unsigned long thread_saved_fp(struct thread_struct *t)
-{
-	return t->save ? t->save->fp : 0;
-}
-
-/* Forward declaration, a strange C thing */
-struct task_struct;
-
-/* Free all resources held by a thread. */
-extern void release_thread(struct task_struct *);
-
-/* Copy and release all segment info associated with a VM */
-#define copy_segments(tsk, mm)		do { } while (0)
-#define release_segments(mm)		do { } while (0)
-
-unsigned long get_wchan(struct task_struct *p);
-
-#define THREAD_SIZE	(8192)
-
-extern struct task_struct *alloc_task_struct(void);
-extern void __free_task_struct(struct task_struct *);
-#define get_task_struct(p)	atomic_inc(&(p)->thread.refcount)
-#define free_task_struct(p)					\
- do {								\
-	if (atomic_dec_and_test(&(p)->thread.refcount))		\
-		__free_task_struct((p));			\
- } while (0)
-
-#define init_task	(init_task_union.task)
-#define init_stack	(init_task_union.stack)
-
-#define cpu_relax()	barrier()
-
-/*
- * Create a new kernel thread
- */
-extern int arch_kernel_thread(int (*fn)(void *), void *arg, unsigned long flags);
-
-#endif
-
-#endif /* __ASM_ARM_PROCESSOR_H */
diff --git a/include/linux/barebox-wrapper.h b/include/linux/barebox-wrapper.h
index e998932d1201..82c52dd93309 100644
--- a/include/linux/barebox-wrapper.h
+++ b/include/linux/barebox-wrapper.h
@@ -52,4 +52,6 @@ typedef int irqreturn_t;
 #define __clk_get_rate			clk_get_rate
 #define __clk_get_parent		clk_get_parent
 
+#define cpu_relax()	barrier()
+
 #endif /* __INCLUDE_LINUX_BAREBOX_WRAPPER_H */
-- 
2.26.0.rc2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  parent reply	other threads:[~2020-04-13  7:52 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-13  7:51 [PATCH 00/21] clk: at91: sync with Linux v5.6 Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 01/21] mfd: syscon: enable specified clocks on syscon_base_lookup_by_phandle Ahmad Fatoum
2020-04-15  9:15   ` Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 02/21] mfd: syscon: refactor of_syscon_register compatible check Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 03/21] mfd: syscon: implement device_node_to_regmap Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 04/21] regmap: retire of_node_to_regmap in favor of device_node_to_regmap Ahmad Fatoum
2020-04-13  7:51 ` Ahmad Fatoum [this message]
2020-04-13  7:51 ` [PATCH 06/21] treewide: use cpu_relax() where appropriate Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 07/21] of: port Linux of_get_compatible_child helper Ahmad Fatoum
2020-04-14  6:46   ` Sascha Hauer
2020-04-14  7:29     ` Ahmad Fatoum
2020-04-14  9:44       ` Michael Tretter
2020-04-14 15:41     ` [PATCH] fixup! " Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 08/21] clk: implement clk_register_fixed_rate Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 09/21] clk: add clk_unregister stub Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 10/21] include: linux/kernel.h: port DIV_ROUND_CLOSEST_ULL definition Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 11/21] clk: migrate to SPDX-License-Identifier use Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 12/21] clk: at91: fix masterck name Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 13/21] clk: at91: fix possible deadlock Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 14/21] clk: at91: delete no-longer required DT compat code Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 15/21] clk: at91: compile dt-compat for all platforms that require it Ahmad Fatoum
2020-04-13  7:51 ` [PATCH 16/21] clk: at91: add __init marker where appropriate Ahmad Fatoum
2020-04-13  7:52 ` [PATCH 17/21] clk: at91: Mark struct clk_range as const Ahmad Fatoum
2020-04-13  7:52 ` [PATCH 18/21] clk: at91: allow 24 Mhz clock as input for PLL Ahmad Fatoum
2020-04-13  7:52 ` [PATCH 19/21] clk: at91: add sama5d2 audio PLL support Ahmad Fatoum
2020-04-13  7:52 ` [PATCH 20/21] clk: at91: port Linux v5.6 SAM9X60 (new ARM926EJ-S) clock support Ahmad Fatoum
2020-04-13  7:52 ` [PATCH 21/21] clk: at91: sckc: fix off-by-1000 in udelay() Ahmad Fatoum
2020-04-15  9:23 ` [PATCH 00/21] clk: at91: sync with Linux v5.6 Sascha Hauer

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=20200413075204.17544-6-a.fatoum@pengutronix.de \
    --to=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.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