diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2018-07-26 17:36:36 -0700 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2019-06-22 23:54:38 -0700 |
commit | 38d107690df7f0826adb5b53f4e87676859ff0a6 (patch) | |
tree | c50a93a2c43c71b4c15ac6d71c07643b78004170 /drivers/input/joystick/iforce/iforce.h | |
parent | Input: iforce - remove "being used" silliness (diff) | |
download | linux-dev-38d107690df7f0826adb5b53f4e87676859ff0a6.tar.xz linux-dev-38d107690df7f0826adb5b53f4e87676859ff0a6.zip |
Input: iforce - introduce transport ops
In order to tease apart the driver into core and transport modules, let's
introduce transport operations and make "xmit" the very first one such
operation.
Tested-by: Tim Schumacher <timschumi@gmx.de>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to '')
-rw-r--r-- | drivers/input/joystick/iforce/iforce.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/drivers/input/joystick/iforce/iforce.h b/drivers/input/joystick/iforce/iforce.h index 0e9d01f8bcb6..2fea3be751ed 100644 --- a/drivers/input/joystick/iforce/iforce.h +++ b/drivers/input/joystick/iforce/iforce.h @@ -93,9 +93,16 @@ struct iforce_device { signed short *ff; }; +struct iforce; + +struct iforce_xport_ops { + void (*xmit)(struct iforce *iforce); +}; + struct iforce { struct input_dev *dev; /* Input device interface */ struct iforce_device *type; + const struct iforce_xport_ops *xport_ops; int bus; unsigned char data[IFORCE_MAX_LENGTH]; @@ -141,12 +148,6 @@ struct iforce { /* Public functions */ -/* iforce-serio.c */ -void iforce_serial_xmit(struct iforce *iforce); - -/* iforce-usb.c */ -void iforce_usb_xmit(struct iforce *iforce); - /* iforce-main.c */ int iforce_init_device(struct iforce *iforce); |