Commit 8bff05b0 authored by Stephen Rothwell's avatar Stephen Rothwell

[POWERPC] iseries: A new iSeries console

This driver uses the hvc_console.c infrastructure that is used by the
pSeries virtual and RTAS consoles.  This will allow us to make viocons.c
obsolete and is another step along the way to a combined kernel (as
viocons could not coexist with CONFIG_VT).
Signed-off-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
parent 3da27289
......@@ -3,7 +3,11 @@ menu "iSeries device drivers"
depends on PPC_ISERIES
config VIOCONS
tristate "iSeries Virtual Console Support"
tristate "iSeries Virtual Console Support (Obsolete)"
help
This is the old virtual console driver for legacy iSeries.
You should use the iSeries Hypervisor Virtual Console
support instead.
config VIODASD
tristate "iSeries Virtual I/O disk support"
......
......@@ -298,7 +298,8 @@ static void __init dt_vdevices(struct iseries_flat_dt *dt)
dt_prop_u32(dt, "#address-cells", 1);
dt_prop_u32(dt, "#size-cells", 0);
dt_do_vdevice(dt, "vty", reg, -1, device_type_serial, NULL, 1);
dt_do_vdevice(dt, "vty", reg, -1, device_type_serial,
"IBM,iSeries-vty", 1);
reg++;
dt_do_vdevice(dt, "v-scsi", reg, -1, device_type_vscsi,
......
......@@ -610,6 +610,13 @@ config HVC_CONSOLE
console. This driver allows each pSeries partition to have a console
which is accessed via the HMC.
config HVC_ISERIES
bool "iSeries Hypervisor Virtual Console support"
depends on PPC_ISERIES && !VIOCONS
select HVC_DRIVER
help
iSeries machines support a hypervisor virtual console.
config HVC_RTAS
bool "IBM RTAS Console support"
depends on PPC_RTAS
......
......@@ -42,6 +42,7 @@ obj-$(CONFIG_AMIGA_BUILTIN_SERIAL) += amiserial.o
obj-$(CONFIG_SX) += sx.o generic_serial.o
obj-$(CONFIG_RIO) += rio/ generic_serial.o
obj-$(CONFIG_HVC_CONSOLE) += hvc_vio.o hvsi.o
obj-$(CONFIG_HVC_ISERIES) += hvc_iseries.o
obj-$(CONFIG_HVC_RTAS) += hvc_rtas.o
obj-$(CONFIG_HVC_DRIVER) += hvc_console.o
obj-$(CONFIG_RAW_DRIVER) += raw.o
......
This diff is collapsed.
......@@ -43,7 +43,6 @@
#include <linux/sysrq.h>
#include <asm/iseries/vio.h>
#include <asm/iseries/hv_lp_event.h>
#include <asm/iseries/hv_call_event.h>
#include <asm/iseries/hv_lp_config.h>
......@@ -67,35 +66,6 @@ static int vio_sysrq_pressed;
extern int sysrq_enabled;
#endif
/*
* The structure of the events that flow between us and OS/400. You can't
* mess with this unless the OS/400 side changes too
*/
struct viocharlpevent {
struct HvLpEvent event;
u32 reserved;
u16 version;
u16 subtype_result_code;
u8 virtual_device;
u8 len;
u8 data[VIOCHAR_MAX_DATA];
};
#define VIOCHAR_WINDOW 10
#define VIOCHAR_HIGHWATERMARK 3
enum viocharsubtype {
viocharopen = 0x0001,
viocharclose = 0x0002,
viochardata = 0x0003,
viocharack = 0x0004,
viocharconfig = 0x0005
};
enum viochar_rc {
viochar_rc_ebusy = 1
};
#define VIOCHAR_NUM_BUF 16
/*
......@@ -1183,6 +1153,7 @@ static int __init viocons_init(void)
port_info[i].magic = VIOTTY_MAGIC;
}
HvCall_setLogBufferFormatAndCodepage(HvCall_LogBuffer_ASCII, 437);
add_preferred_console("viocons", 0, NULL);
register_console(&viocons_early);
return 0;
}
......
......@@ -122,6 +122,34 @@ enum viorc {
viorc_openRejected = 0x0301
};
/*
* The structure of the events that flow between us and OS/400 for chario
* events. You can't mess with this unless the OS/400 side changes too.
*/
struct viocharlpevent {
struct HvLpEvent event;
u32 reserved;
u16 version;
u16 subtype_result_code;
u8 virtual_device;
u8 len;
u8 data[VIOCHAR_MAX_DATA];
};
#define VIOCHAR_WINDOW 10
enum viocharsubtype {
viocharopen = 0x0001,
viocharclose = 0x0002,
viochardata = 0x0003,
viocharack = 0x0004,
viocharconfig = 0x0005
};
enum viochar_rc {
viochar_rc_ebusy = 1
};
struct device;
extern struct device *iSeries_vio_dev;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment