aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/rio.h
diff options
context:
space:
mode:
authorAlexandre Bounine <alexandre.bounine@idt.com>2010-05-26 17:44:03 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2010-05-27 12:12:51 -0400
commit058f88d672b3161fe511ebe2996c3faef63c1c8e (patch)
treefb4bb8d93aef661cc9e24e1e6e2e8bd4edc2e764 /include/linux/rio.h
parent011507e49a696462c30914e2eeebcdda33ed30f8 (diff)
rapidio: modify initialization of switch operations
Modify the way how RapidIO switch operations are declared. Multiple assignments through the linker script replaced by single initialization call. Signed-off-by: Alexandre Bounine <alexandre.bounine@idt.com> Cc: Matt Porter <mporter@kernel.crashing.org> Cc: Li Yang <leoli@freescale.com> Cc: Kumar Gala <galak@kernel.crashing.org> Cc: Thomas Moll <thomas.moll@sysgo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/rio.h')
-rw-r--r--include/linux/rio.h35
1 files changed, 6 insertions, 29 deletions
diff --git a/include/linux/rio.h b/include/linux/rio.h
index 4ec31f44f406..3d0ac930cbea 100644
--- a/include/linux/rio.h
+++ b/include/linux/rio.h
@@ -320,40 +320,17 @@ struct rio_device_id {
320}; 320};
321 321
322/** 322/**
323 * struct rio_route_ops - Per-switch route operations 323 * struct rio_switch_ops - Per-switch operations
324 * @vid: RIO vendor ID 324 * @vid: RIO vendor ID
325 * @did: RIO device ID 325 * @did: RIO device ID
326 * @add_hook: Callback that adds a route entry 326 * @init_hook: Callback that performs switch device initialization
327 * @get_hook: Callback that gets a route entry
328 * @clr_hook: Callback that clears a switch route table (may be NULL)
329 * 327 *
330 * Defines the operations that are necessary to manipulate the route 328 * Defines the operations that are necessary to initialize/control
331 * tables for a particular RIO switch device. 329 * a particular RIO switch device.
332 */ 330 */
333struct rio_route_ops { 331struct rio_switch_ops {
334 u16 vid, did; 332 u16 vid, did;
335 int (*add_hook) (struct rio_mport * mport, u16 destid, u8 hopcount, 333 int (*init_hook) (struct rio_dev *rdev, int do_enum);
336 u16 table, u16 route_destid, u8 route_port);
337 int (*get_hook) (struct rio_mport * mport, u16 destid, u8 hopcount,
338 u16 table, u16 route_destid, u8 * route_port);
339 int (*clr_hook) (struct rio_mport *mport, u16 destid, u8 hopcount,
340 u16 table);
341};
342
343/**
344 * struct rio_em_ops - Per-switch error management operations
345 * @vid: RIO vendor ID
346 * @did: RIO device ID
347 * @init_hook: Switch specific error management initialization (may be NULL)
348 * @handler_hook: Switch specific error management handler (may be NULL)
349 *
350 * Defines the operations that are necessary to initialize and handle
351 * error management events for a particular RIO switch device.
352 */
353struct rio_em_ops {
354 u16 vid, did;
355 int (*init_hook) (struct rio_dev *dev);
356 int (*handler_hook) (struct rio_dev *dev, u8 swport);
357}; 334};
358 335
359union rio_pw_msg { 336union rio_pw_msg {