Commit b420677870e53b9b76ced91da207431f687eaed1
1 parent
bbc8b628b0
Exists in
master
and in
4 other branches
merge filename and modify references to iseries/vio.h
Signed-off-by: Kelly Daly <kelly@au.ibm.com>
Showing 10 changed files with 139 additions and 139 deletions Side-by-side Diff
- arch/powerpc/platforms/iseries/mf.c
- arch/powerpc/platforms/iseries/vio.c
- arch/powerpc/platforms/iseries/viopath.c
- drivers/block/viodasd.c
- drivers/cdrom/viocd.c
- drivers/char/viocons.c
- drivers/char/viotape.c
- drivers/scsi/ibmvscsi/iseries_vscsi.c
- include/asm-powerpc/iseries/vio.h
- include/asm-ppc64/iSeries/vio.h
arch/powerpc/platforms/iseries/mf.c
... | ... | @@ -38,7 +38,7 @@ |
38 | 38 | #include <asm/uaccess.h> |
39 | 39 | #include <asm/paca.h> |
40 | 40 | #include <asm/abs_addr.h> |
41 | -#include <asm/iSeries/vio.h> | |
41 | +#include <asm/iseries/vio.h> | |
42 | 42 | #include <asm/iseries/mf.h> |
43 | 43 | #include <asm/iseries/hv_lp_config.h> |
44 | 44 | #include <asm/iseries/it_lp_queue.h> |
arch/powerpc/platforms/iseries/vio.c
... | ... | @@ -17,7 +17,7 @@ |
17 | 17 | #include <asm/tce.h> |
18 | 18 | #include <asm/abs_addr.h> |
19 | 19 | #include <asm/page.h> |
20 | -#include <asm/iSeries/vio.h> | |
20 | +#include <asm/iseries/vio.h> | |
21 | 21 | #include <asm/iseries/hv_types.h> |
22 | 22 | #include <asm/iseries/hv_lp_config.h> |
23 | 23 | #include <asm/iseries/hv_call_xm.h> |
arch/powerpc/platforms/iseries/viopath.c
... | ... | @@ -46,7 +46,7 @@ |
46 | 46 | #include <asm/iseries/hv_lp_event.h> |
47 | 47 | #include <asm/iseries/hv_lp_config.h> |
48 | 48 | #include <asm/iseries/mf.h> |
49 | -#include <asm/iSeries/vio.h> | |
49 | +#include <asm/iseries/vio.h> | |
50 | 50 | |
51 | 51 | /* Status of the path to each other partition in the system. |
52 | 52 | * This is overkill, since we will only ever establish connections |
drivers/block/viodasd.c
... | ... | @@ -48,7 +48,7 @@ |
48 | 48 | #include <asm/iseries/hv_types.h> |
49 | 49 | #include <asm/iseries/hv_lp_event.h> |
50 | 50 | #include <asm/iseries/hv_lp_config.h> |
51 | -#include <asm/iSeries/vio.h> | |
51 | +#include <asm/iseries/vio.h> | |
52 | 52 | |
53 | 53 | MODULE_DESCRIPTION("iSeries Virtual DASD"); |
54 | 54 | MODULE_AUTHOR("Dave Boutcher"); |
drivers/cdrom/viocd.c
... | ... | @@ -48,7 +48,7 @@ |
48 | 48 | #include <asm/scatterlist.h> |
49 | 49 | #include <asm/iseries/hv_types.h> |
50 | 50 | #include <asm/iseries/hv_lp_event.h> |
51 | -#include <asm/iSeries/vio.h> | |
51 | +#include <asm/iseries/vio.h> | |
52 | 52 | |
53 | 53 | #define VIOCD_DEVICE "iseries/vcd" |
54 | 54 | #define VIOCD_DEVICE_DEVFS "iseries/vcd" |
drivers/char/viocons.c
drivers/char/viotape.c
... | ... | @@ -29,7 +29,7 @@ |
29 | 29 | * |
30 | 30 | * All tape operations are performed by sending messages back and forth to |
31 | 31 | * the OS/400 partition. The format of the messages is defined in |
32 | - * iSeries/vio.h | |
32 | + * iseries/vio.h | |
33 | 33 | */ |
34 | 34 | #include <linux/config.h> |
35 | 35 | #include <linux/version.h> |
... | ... | @@ -54,7 +54,7 @@ |
54 | 54 | #include <asm/ioctls.h> |
55 | 55 | |
56 | 56 | #include <asm/vio.h> |
57 | -#include <asm/iSeries/vio.h> | |
57 | +#include <asm/iseries/vio.h> | |
58 | 58 | #include <asm/iseries/hv_lp_event.h> |
59 | 59 | #include <asm/iseries/hv_call_event.h> |
60 | 60 | #include <asm/iseries/hv_lp_config.h> |
drivers/scsi/ibmvscsi/iseries_vscsi.c
include/asm-powerpc/iseries/vio.h
1 | +/* -*- linux-c -*- | |
2 | + * drivers/char/vio.h | |
3 | + * | |
4 | + * iSeries Virtual I/O Message Path header | |
5 | + * | |
6 | + * Authors: Dave Boutcher <boutcher@us.ibm.com> | |
7 | + * Ryan Arnold <ryanarn@us.ibm.com> | |
8 | + * Colin Devilbiss <devilbis@us.ibm.com> | |
9 | + * | |
10 | + * (C) Copyright 2000 IBM Corporation | |
11 | + * | |
12 | + * This header file is used by the iSeries virtual I/O device | |
13 | + * drivers. It defines the interfaces to the common functions | |
14 | + * (implemented in drivers/char/viopath.h) as well as defining | |
15 | + * common functions and structures. Currently (at the time I | |
16 | + * wrote this comment) the iSeries virtual I/O device drivers | |
17 | + * that use this are | |
18 | + * drivers/block/viodasd.c | |
19 | + * drivers/char/viocons.c | |
20 | + * drivers/char/viotape.c | |
21 | + * drivers/cdrom/viocd.c | |
22 | + * | |
23 | + * The iSeries virtual ethernet support (veth.c) uses a whole | |
24 | + * different set of functions. | |
25 | + * | |
26 | + * This program is free software; you can redistribute it and/or | |
27 | + * modify it under the terms of the GNU General Public License as | |
28 | + * published by the Free Software Foundation; either version 2 of the | |
29 | + * License, or (at your option) anyu later version. | |
30 | + * | |
31 | + * This program is distributed in the hope that it will be useful, but | |
32 | + * WITHOUT ANY WARRANTY; without even the implied warranty of | |
33 | + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
34 | + * General Public License for more details. | |
35 | + * | |
36 | + * You should have received a copy of the GNU General Public License | |
37 | + * along with this program; if not, write to the Free Software Foundation, | |
38 | + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
39 | + * | |
40 | + */ | |
41 | +#ifndef _ISERIES_VIO_H | |
42 | +#define _ISERIES_VIO_H | |
43 | + | |
44 | +#include <asm/iseries/hv_types.h> | |
45 | +#include <asm/iseries/hv_lp_event.h> | |
46 | + | |
47 | +/* | |
48 | + * iSeries virtual I/O events use the subtype field in | |
49 | + * HvLpEvent to figure out what kind of vio event is coming | |
50 | + * in. We use a table to route these, and this defines | |
51 | + * the maximum number of distinct subtypes | |
52 | + */ | |
53 | +#define VIO_MAX_SUBTYPES 8 | |
54 | + | |
55 | +/* | |
56 | + * Each subtype can register a handler to process their events. | |
57 | + * The handler must have this interface. | |
58 | + */ | |
59 | +typedef void (vio_event_handler_t) (struct HvLpEvent * event); | |
60 | + | |
61 | +extern int viopath_open(HvLpIndex remoteLp, int subtype, int numReq); | |
62 | +extern int viopath_close(HvLpIndex remoteLp, int subtype, int numReq); | |
63 | +extern int vio_setHandler(int subtype, vio_event_handler_t * beh); | |
64 | +extern int vio_clearHandler(int subtype); | |
65 | +extern int viopath_isactive(HvLpIndex lp); | |
66 | +extern HvLpInstanceId viopath_sourceinst(HvLpIndex lp); | |
67 | +extern HvLpInstanceId viopath_targetinst(HvLpIndex lp); | |
68 | +extern void vio_set_hostlp(void); | |
69 | +extern void *vio_get_event_buffer(int subtype); | |
70 | +extern void vio_free_event_buffer(int subtype, void *buffer); | |
71 | + | |
72 | +extern HvLpIndex viopath_hostLp; | |
73 | +extern HvLpIndex viopath_ourLp; | |
74 | + | |
75 | +#define VIOCHAR_MAX_DATA 200 | |
76 | + | |
77 | +#define VIOMAJOR_SUBTYPE_MASK 0xff00 | |
78 | +#define VIOMINOR_SUBTYPE_MASK 0x00ff | |
79 | +#define VIOMAJOR_SUBTYPE_SHIFT 8 | |
80 | + | |
81 | +#define VIOVERSION 0x0101 | |
82 | + | |
83 | +/* | |
84 | + * This is the general structure for VIO errors; each module should have | |
85 | + * a table of them, and each table should be terminated by an entry of | |
86 | + * { 0, 0, NULL }. Then, to find a specific error message, a module | |
87 | + * should pass its local table and the return code. | |
88 | + */ | |
89 | +struct vio_error_entry { | |
90 | + u16 rc; | |
91 | + int errno; | |
92 | + const char *msg; | |
93 | +}; | |
94 | +extern const struct vio_error_entry *vio_lookup_rc( | |
95 | + const struct vio_error_entry *local_table, u16 rc); | |
96 | + | |
97 | +enum viosubtypes { | |
98 | + viomajorsubtype_monitor = 0x0100, | |
99 | + viomajorsubtype_blockio = 0x0200, | |
100 | + viomajorsubtype_chario = 0x0300, | |
101 | + viomajorsubtype_config = 0x0400, | |
102 | + viomajorsubtype_cdio = 0x0500, | |
103 | + viomajorsubtype_tape = 0x0600, | |
104 | + viomajorsubtype_scsi = 0x0700 | |
105 | +}; | |
106 | + | |
107 | +enum vioconfigsubtype { | |
108 | + vioconfigget = 0x0001, | |
109 | +}; | |
110 | + | |
111 | +enum viorc { | |
112 | + viorc_good = 0x0000, | |
113 | + viorc_noConnection = 0x0001, | |
114 | + viorc_noReceiver = 0x0002, | |
115 | + viorc_noBufferAvailable = 0x0003, | |
116 | + viorc_invalidMessageType = 0x0004, | |
117 | + viorc_invalidRange = 0x0201, | |
118 | + viorc_invalidToken = 0x0202, | |
119 | + viorc_DMAError = 0x0203, | |
120 | + viorc_useError = 0x0204, | |
121 | + viorc_releaseError = 0x0205, | |
122 | + viorc_invalidDisk = 0x0206, | |
123 | + viorc_openRejected = 0x0301 | |
124 | +}; | |
125 | + | |
126 | +struct device; | |
127 | + | |
128 | +extern struct device *iSeries_vio_dev; | |
129 | + | |
130 | +#endif /* _ISERIES_VIO_H */ |
include/asm-ppc64/iSeries/vio.h
1 | -/* -*- linux-c -*- | |
2 | - * drivers/char/vio.h | |
3 | - * | |
4 | - * iSeries Virtual I/O Message Path header | |
5 | - * | |
6 | - * Authors: Dave Boutcher <boutcher@us.ibm.com> | |
7 | - * Ryan Arnold <ryanarn@us.ibm.com> | |
8 | - * Colin Devilbiss <devilbis@us.ibm.com> | |
9 | - * | |
10 | - * (C) Copyright 2000 IBM Corporation | |
11 | - * | |
12 | - * This header file is used by the iSeries virtual I/O device | |
13 | - * drivers. It defines the interfaces to the common functions | |
14 | - * (implemented in drivers/char/viopath.h) as well as defining | |
15 | - * common functions and structures. Currently (at the time I | |
16 | - * wrote this comment) the iSeries virtual I/O device drivers | |
17 | - * that use this are | |
18 | - * drivers/block/viodasd.c | |
19 | - * drivers/char/viocons.c | |
20 | - * drivers/char/viotape.c | |
21 | - * drivers/cdrom/viocd.c | |
22 | - * | |
23 | - * The iSeries virtual ethernet support (veth.c) uses a whole | |
24 | - * different set of functions. | |
25 | - * | |
26 | - * This program is free software; you can redistribute it and/or | |
27 | - * modify it under the terms of the GNU General Public License as | |
28 | - * published by the Free Software Foundation; either version 2 of the | |
29 | - * License, or (at your option) anyu later version. | |
30 | - * | |
31 | - * This program is distributed in the hope that it will be useful, but | |
32 | - * WITHOUT ANY WARRANTY; without even the implied warranty of | |
33 | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
34 | - * General Public License for more details. | |
35 | - * | |
36 | - * You should have received a copy of the GNU General Public License | |
37 | - * along with this program; if not, write to the Free Software Foundation, | |
38 | - * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
39 | - * | |
40 | - */ | |
41 | -#ifndef _ISERIES_VIO_H | |
42 | -#define _ISERIES_VIO_H | |
43 | - | |
44 | -#include <asm/iseries/hv_types.h> | |
45 | -#include <asm/iseries/hv_lp_event.h> | |
46 | - | |
47 | -/* | |
48 | - * iSeries virtual I/O events use the subtype field in | |
49 | - * HvLpEvent to figure out what kind of vio event is coming | |
50 | - * in. We use a table to route these, and this defines | |
51 | - * the maximum number of distinct subtypes | |
52 | - */ | |
53 | -#define VIO_MAX_SUBTYPES 8 | |
54 | - | |
55 | -/* | |
56 | - * Each subtype can register a handler to process their events. | |
57 | - * The handler must have this interface. | |
58 | - */ | |
59 | -typedef void (vio_event_handler_t) (struct HvLpEvent * event); | |
60 | - | |
61 | -extern int viopath_open(HvLpIndex remoteLp, int subtype, int numReq); | |
62 | -extern int viopath_close(HvLpIndex remoteLp, int subtype, int numReq); | |
63 | -extern int vio_setHandler(int subtype, vio_event_handler_t * beh); | |
64 | -extern int vio_clearHandler(int subtype); | |
65 | -extern int viopath_isactive(HvLpIndex lp); | |
66 | -extern HvLpInstanceId viopath_sourceinst(HvLpIndex lp); | |
67 | -extern HvLpInstanceId viopath_targetinst(HvLpIndex lp); | |
68 | -extern void vio_set_hostlp(void); | |
69 | -extern void *vio_get_event_buffer(int subtype); | |
70 | -extern void vio_free_event_buffer(int subtype, void *buffer); | |
71 | - | |
72 | -extern HvLpIndex viopath_hostLp; | |
73 | -extern HvLpIndex viopath_ourLp; | |
74 | - | |
75 | -#define VIOCHAR_MAX_DATA 200 | |
76 | - | |
77 | -#define VIOMAJOR_SUBTYPE_MASK 0xff00 | |
78 | -#define VIOMINOR_SUBTYPE_MASK 0x00ff | |
79 | -#define VIOMAJOR_SUBTYPE_SHIFT 8 | |
80 | - | |
81 | -#define VIOVERSION 0x0101 | |
82 | - | |
83 | -/* | |
84 | - * This is the general structure for VIO errors; each module should have | |
85 | - * a table of them, and each table should be terminated by an entry of | |
86 | - * { 0, 0, NULL }. Then, to find a specific error message, a module | |
87 | - * should pass its local table and the return code. | |
88 | - */ | |
89 | -struct vio_error_entry { | |
90 | - u16 rc; | |
91 | - int errno; | |
92 | - const char *msg; | |
93 | -}; | |
94 | -extern const struct vio_error_entry *vio_lookup_rc( | |
95 | - const struct vio_error_entry *local_table, u16 rc); | |
96 | - | |
97 | -enum viosubtypes { | |
98 | - viomajorsubtype_monitor = 0x0100, | |
99 | - viomajorsubtype_blockio = 0x0200, | |
100 | - viomajorsubtype_chario = 0x0300, | |
101 | - viomajorsubtype_config = 0x0400, | |
102 | - viomajorsubtype_cdio = 0x0500, | |
103 | - viomajorsubtype_tape = 0x0600, | |
104 | - viomajorsubtype_scsi = 0x0700 | |
105 | -}; | |
106 | - | |
107 | -enum vioconfigsubtype { | |
108 | - vioconfigget = 0x0001, | |
109 | -}; | |
110 | - | |
111 | -enum viorc { | |
112 | - viorc_good = 0x0000, | |
113 | - viorc_noConnection = 0x0001, | |
114 | - viorc_noReceiver = 0x0002, | |
115 | - viorc_noBufferAvailable = 0x0003, | |
116 | - viorc_invalidMessageType = 0x0004, | |
117 | - viorc_invalidRange = 0x0201, | |
118 | - viorc_invalidToken = 0x0202, | |
119 | - viorc_DMAError = 0x0203, | |
120 | - viorc_useError = 0x0204, | |
121 | - viorc_releaseError = 0x0205, | |
122 | - viorc_invalidDisk = 0x0206, | |
123 | - viorc_openRejected = 0x0301 | |
124 | -}; | |
125 | - | |
126 | -struct device; | |
127 | - | |
128 | -extern struct device *iSeries_vio_dev; | |
129 | - | |
130 | -#endif /* _ISERIES_VIO_H */ |