linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: Tony Luck <tony.luck@intel.com>,
	Fenghua Yu <fenghua.yu@intel.com>,
	Mike Travis <mike.travis@hpe.com>,
	Dimitri Sivanich <sivanich@hpe.com>
Cc: Arnd Bergmann <arnd@arndb.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-ia64@vger.kernel.org, linux-ide@vger.kernel.org,
	linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH 21/28] ia64: remove the SGI UV simulator support
Date: Tue, 13 Aug 2019 09:25:07 +0200	[thread overview]
Message-ID: <20190813072514.23299-22-hch@lst.de> (raw)
In-Reply-To: <20190813072514.23299-1-hch@lst.de>

The simulator support was marked as temporary since the initial commit,
so drop it more than 10 years later.

Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 arch/ia64/include/asm/sn/simulator.h | 25 ----------------------
 arch/ia64/include/asm/sn/sn_sal.h    | 10 ---------
 arch/ia64/include/asm/uv/uv.h        |  4 +---
 arch/ia64/uv/kernel/setup.c          | 31 +++++-----------------------
 4 files changed, 6 insertions(+), 64 deletions(-)
 delete mode 100644 arch/ia64/include/asm/sn/simulator.h

diff --git a/arch/ia64/include/asm/sn/simulator.h b/arch/ia64/include/asm/sn/simulator.h
deleted file mode 100644
index 3e4557df3b7c..000000000000
--- a/arch/ia64/include/asm/sn/simulator.h
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * This file is subject to the terms and conditions of the GNU General Public
- * License.  See the file "COPYING" in the main directory of this archive
- * for more details.
- * Copyright (C) 2000-2004 Silicon Graphics, Inc. All rights reserved.
- */
-
-#ifndef _ASM_IA64_SN_SIMULATOR_H
-#define _ASM_IA64_SN_SIMULATOR_H
-
-#if defined(CONFIG_IA64_GENERIC) || defined(CONFIG_IA64_SGI_UV)
-#define SNMAGIC 0xaeeeeeee8badbeefL
-#define IS_MEDUSA()			({long sn; asm("mov %0=cpuid[%1]" : "=r"(sn) : "r"(2)); sn == SNMAGIC;})
-
-#define SIMULATOR_SLEEP()		asm("nop.i 0x8beef")
-#define IS_RUNNING_ON_SIMULATOR()	(sn_prom_type)
-#define IS_RUNNING_ON_FAKE_PROM()	(sn_prom_type == 2)
-extern int sn_prom_type;		/* 0=hardware, 1=medusa/realprom, 2=medusa/fakeprom */
-#else
-#define IS_MEDUSA()			0
-#define SIMULATOR_SLEEP()
-#define IS_RUNNING_ON_SIMULATOR()	0
-#endif
-
-#endif /* _ASM_IA64_SN_SIMULATOR_H */
diff --git a/arch/ia64/include/asm/sn/sn_sal.h b/arch/ia64/include/asm/sn/sn_sal.h
index 48b88d0807db..d437aa43343b 100644
--- a/arch/ia64/include/asm/sn/sn_sal.h
+++ b/arch/ia64/include/asm/sn/sn_sal.h
@@ -30,8 +30,6 @@
 #define SALRET_INVALID_ARG	(-2)
 #define SALRET_ERROR		(-3)
 
-#define SN_SAL_FAKE_PROM			   0x02009999
-
 /*
  * Returns the physical address of the partition's reserved page through
  * an iterative number of calls.
@@ -81,14 +79,6 @@ sn_change_memprotect(u64 paddr, u64 len, u64 perms, u64 *nasid_array)
 #define SN_MEMPROT_ACCESS_CLASS_6		0x084080
 #define SN_MEMPROT_ACCESS_CLASS_7		0x021080
 
-static inline int
-ia64_sn_is_fake_prom(void)
-{
-	struct ia64_sal_retval rv;
-	SAL_CALL_NOLOCK(rv, SN_SAL_FAKE_PROM, 0, 0, 0, 0, 0, 0, 0);
-	return (rv.status == 0);
-}
-
 union sn_watchlist_u {
 	u64     val;
 	struct {
diff --git a/arch/ia64/include/asm/uv/uv.h b/arch/ia64/include/asm/uv/uv.h
index 71df93ee3bc0..502cf1c56369 100644
--- a/arch/ia64/include/asm/uv/uv.h
+++ b/arch/ia64/include/asm/uv/uv.h
@@ -2,12 +2,10 @@
 #ifndef _ASM_IA64_UV_UV_H
 #define _ASM_IA64_UV_UV_H
 
-#include <asm/sn/simulator.h>
-
 static inline int is_uv_system(void)
 {
 	/* temporary support for running on hardware simulator */
-	return IS_MEDUSA() || ia64_platform_is("uv");
+	return ia64_platform_is("uv");
 }
 
 #endif	/* _ASM_IA64_UV_UV_H */
diff --git a/arch/ia64/uv/kernel/setup.c b/arch/ia64/uv/kernel/setup.c
index 11478d2d863d..6ac4bd314d92 100644
--- a/arch/ia64/uv/kernel/setup.c
+++ b/arch/ia64/uv/kernel/setup.c
@@ -10,14 +10,12 @@
 
 #include <linux/module.h>
 #include <linux/percpu.h>
-#include <asm/sn/simulator.h>
 #include <asm/uv/uv_mmrs.h>
 #include <asm/uv/uv_hub.h>
 
 DEFINE_PER_CPU(struct uv_hub_info_s, __uv_hub_info);
 EXPORT_PER_CPU_SYMBOL_GPL(__uv_hub_info);
 
-int sn_prom_type;
 long sn_coherency_id;
 EXPORT_SYMBOL_GPL(sn_coherency_id);
 
@@ -60,30 +58,11 @@ void __init uv_setup(char **cmdline_p)
 	int nid, cpu, m_val, n_val;
 	unsigned long mmr_base, lowmem_redir_base, lowmem_redir_size;
 
-	if (IS_MEDUSA()) {
-		lowmem_redir_base = 0;
-		lowmem_redir_size = 0;
-		node_id.v = 0;
-		m_n_config.s.m_skt = 37;
-		m_n_config.s.n_skt = 0;
-		mmr_base = 0;
-#if 0
-		/* Need BIOS calls - TDB */
-		if (!ia64_sn_is_fake_prom())
-			sn_prom_type = 1;
-		else
-#endif
-			sn_prom_type = 2;
-		printk(KERN_INFO "Running on medusa with %s PROM\n",
-					(sn_prom_type == 1) ? "real" : "fake");
-	} else {
-		get_lowmem_redirect(&lowmem_redir_base, &lowmem_redir_size);
-		node_id.v = uv_read_local_mmr(UVH_NODE_ID);
-		m_n_config.v = uv_read_local_mmr(UVH_SI_ADDR_MAP_CONFIG);
-		mmr_base =
-			uv_read_local_mmr(UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR) &
-				~UV_MMR_ENABLE;
-	}
+	get_lowmem_redirect(&lowmem_redir_base, &lowmem_redir_size);
+	node_id.v = uv_read_local_mmr(UVH_NODE_ID);
+	m_n_config.v = uv_read_local_mmr(UVH_SI_ADDR_MAP_CONFIG);
+	mmr_base = uv_read_local_mmr(UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR) &
+			~UV_MMR_ENABLE;
 
 	m_val = m_n_config.s.m_skt;
 	n_val = m_n_config.s.n_skt;
-- 
2.20.1


  parent reply	other threads:[~2019-08-13  7:26 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-13  7:24 RFC: remove sn2, hpsim and ia64 machvecs v2 Christoph Hellwig
2019-08-13  7:24 ` [PATCH 01/28] char: remove the SGI snsc driver Christoph Hellwig
2019-08-13  7:24 ` [PATCH 02/28] char: remove the SGI tiocx/mbcs driver Christoph Hellwig
2019-08-13  7:24 ` [PATCH 03/28] char/agp: remove the sgi-agp driver Christoph Hellwig
2019-08-13  7:24 ` [PATCH 04/28] ide: remove the sgiioc4 driver Christoph Hellwig
2019-08-13  7:24 ` [PATCH 05/28] PCI/hotplug: remove the sgi_hotplug driver Christoph Hellwig
2019-08-13  7:24 ` [PATCH 06/28] tty/serial: remove the sn_console driver Christoph Hellwig
2019-08-13  7:24 ` [PATCH 07/28] tty/serial: remove the ioc4_serial driver Christoph Hellwig
2019-08-13  7:24 ` [PATCH 08/28] tty/serial: remove the ioc3_serial driver Christoph Hellwig
2019-08-13  7:24 ` [PATCH 09/28] char/mspec: remove SGI SN2 support Christoph Hellwig
2019-08-13  7:24 ` [PATCH 10/28] misc/sgi-xp: " Christoph Hellwig
2019-08-13  7:24 ` [PATCH 11/28] qla1280: " Christoph Hellwig
2019-08-13  7:24 ` [PATCH 12/28] qla2xxx: " Christoph Hellwig
2019-08-13  7:24 ` [PATCH 13/28] drivers: remove the SGI SN2 IOC3 base support Christoph Hellwig
2019-08-13  7:25 ` [PATCH 14/28] drivers: remove the SGI SN2 IOC4 " Christoph Hellwig
2019-08-13  7:25 ` [PATCH 16/28] ia64: remove now unused machvec indirections Christoph Hellwig
2019-08-13  7:25 ` [PATCH 17/28] ia64: remove the hpsim platform Christoph Hellwig
2019-08-13 21:06   ` Vaden, Tom (HPE Server OS Architecture)
2019-08-13  7:25 ` [PATCH 18/28] ia64: remove CONFIG_PCI ifdefs Christoph Hellwig
2019-08-13 21:07   ` Vaden, Tom (HPE Server OS Architecture)
2019-08-13  7:25 ` [PATCH 19/28] ia64: remove CONFIG_ACPI ifdefs Christoph Hellwig
2019-08-13 21:07   ` Vaden, Tom (HPE Server OS Architecture)
2019-08-13  7:25 ` [PATCH 20/28] ia64: remove the zx1 swiotlb machvec Christoph Hellwig
2019-08-13  7:25 ` Christoph Hellwig [this message]
2019-08-13  7:25 ` [PATCH 22/28] ia64: remove the unused sn_coherency_id symbol Christoph Hellwig
2019-08-13  7:25 ` [PATCH 23/28] ia64: rework iommu probing Christoph Hellwig
2019-08-13  7:25 ` [PATCH 24/28] ia64: move the ROOT_DEV setup to common code Christoph Hellwig
2019-08-13  7:25 ` [PATCH 25/28] ia64: move the screen_info " Christoph Hellwig
2019-08-13  7:25 ` [PATCH 26/28] ia64: remove support for machvecs Christoph Hellwig
2019-08-13  7:25 ` [PATCH 27/28] ia64: remove CONFIG_SWIOTLB ifdefs Christoph Hellwig
2019-08-13  7:25 ` [PATCH 28/28] genirq: remove the is_affinity_mask_valid hook Christoph Hellwig

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=20190813072514.23299-22-hch@lst.de \
    --to=hch@lst.de \
    --cc=arnd@arndb.de \
    --cc=fenghua.yu@intel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=mike.travis@hpe.com \
    --cc=sivanich@hpe.com \
    --cc=tony.luck@intel.com \
    /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 NNTP newsgroup(s).