aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh/boards/hp6xx/hp680
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sh/boards/hp6xx/hp680')
-rw-r--r--arch/sh/boards/hp6xx/hp680/Makefile6
-rw-r--r--arch/sh/boards/hp6xx/hp680/mach.c53
-rw-r--r--arch/sh/boards/hp6xx/hp680/setup.c41
3 files changed, 100 insertions, 0 deletions
diff --git a/arch/sh/boards/hp6xx/hp680/Makefile b/arch/sh/boards/hp6xx/hp680/Makefile
new file mode 100644
index 00000000000..0beef11d9b1
--- /dev/null
+++ b/arch/sh/boards/hp6xx/hp680/Makefile
@@ -0,0 +1,6 @@
1#
2# Makefile for the HP680 specific parts of the kernel
3#
4
5obj-y := mach.o setup.o
6
diff --git a/arch/sh/boards/hp6xx/hp680/mach.c b/arch/sh/boards/hp6xx/hp680/mach.c
new file mode 100644
index 00000000000..d7348613604
--- /dev/null
+++ b/arch/sh/boards/hp6xx/hp680/mach.c
@@ -0,0 +1,53 @@
1/*
2 * linux/arch/sh/boards/hp6xx/hp680/mach.c
3 *
4 * Copyright (C) 2000 Stuart Menefy (stuart.menefy@st.com)
5 *
6 * May be copied or modified under the terms of the GNU General Public
7 * License. See linux/COPYING for more information.
8 *
9 * Machine vector for the HP680
10 */
11
12#include <linux/init.h>
13
14#include <asm/machvec.h>
15#include <asm/rtc.h>
16#include <asm/machvec_init.h>
17
18#include <asm/io.h>
19#include <asm/hd64461/hd64461.h>
20#include <asm/hp6xx/io.h>
21#include <asm/irq.h>
22
23struct sh_machine_vector mv_hp680 __initmv = {
24 .mv_nr_irqs = HD64461_IRQBASE + HD64461_IRQ_NUM,
25
26 .mv_inb = hd64461_inb,
27 .mv_inw = hd64461_inw,
28 .mv_inl = hd64461_inl,
29 .mv_outb = hd64461_outb,
30 .mv_outw = hd64461_outw,
31 .mv_outl = hd64461_outl,
32
33 .mv_inb_p = hd64461_inb_p,
34 .mv_inw_p = hd64461_inw,
35 .mv_inl_p = hd64461_inl,
36 .mv_outb_p = hd64461_outb_p,
37 .mv_outw_p = hd64461_outw,
38 .mv_outl_p = hd64461_outl,
39
40 .mv_insb = hd64461_insb,
41 .mv_insw = hd64461_insw,
42 .mv_insl = hd64461_insl,
43 .mv_outsb = hd64461_outsb,
44 .mv_outsw = hd64461_outsw,
45 .mv_outsl = hd64461_outsl,
46
47 .mv_readw = hd64461_readw,
48 .mv_writew = hd64461_writew,
49
50 .mv_irq_demux = hd64461_irq_demux,
51};
52
53ALIAS_MV(hp680)
diff --git a/arch/sh/boards/hp6xx/hp680/setup.c b/arch/sh/boards/hp6xx/hp680/setup.c
new file mode 100644
index 00000000000..4170190f264
--- /dev/null
+++ b/arch/sh/boards/hp6xx/hp680/setup.c
@@ -0,0 +1,41 @@
1/*
2 * linux/arch/sh/boards/hp6xx/hp680/setup.c
3 *
4 * Copyright (C) 2002 Andriy Skulysh
5 *
6 * May be copied or modified under the terms of the GNU General Public
7 * License. See linux/COPYING for more information.
8 *
9 * Setup code for an HP680 (internal peripherials only)
10 */
11
12#include <linux/config.h>
13#include <linux/init.h>
14#include <asm/hd64461/hd64461.h>
15#include <asm/io.h>
16#include <asm/hp6xx/hp6xx.h>
17#include <asm/cpu/dac.h>
18
19const char *get_system_type(void)
20{
21 return "HP680";
22}
23
24int __init platform_setup(void)
25{
26 u16 v;
27 v = inw(HD64461_STBCR);
28 v |= HD64461_STBCR_SURTST | HD64461_STBCR_SIRST |
29 HD64461_STBCR_STM1ST | HD64461_STBCR_STM0ST |
30 HD64461_STBCR_SAFEST | HD64461_STBCR_SPC0ST |
31 HD64461_STBCR_SMIAST | HD64461_STBCR_SAFECKE_OST |
32 HD64461_STBCR_SAFECKE_IST;
33 outw(v, HD64461_STBCR);
34 v = inw(HD64461_GPADR);
35 v |= HD64461_GPADR_SPEAKER | HD64461_GPADR_PCMCIA0;
36 outw(v, HD64461_GPADR);
37
38 sh_dac_disable(DAC_SPEAKER_VOLUME);
39
40 return 0;
41}