diff options
author | Alexandr Shadchin <alexandr.shadchin@gmail.com> | 2011-02-28 16:38:26 +0500 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2011-03-01 11:55:35 +1000 |
commit | 00abf2c63cf1613c3a65d561582e9fd8abc2f34a (patch) | |
tree | 4c7e6b7c14f820afee102478e2f280997bc8dc84 | |
parent | 8e6d67243375539f417f7a19e349c6546ce3be64 (diff) |
Remove arg proto_ops in ReadHwState()
Signed-off-by: Alexandr Shadchin <Alexandr.Shadchin@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-rw-r--r-- | src/alpscomm.c | 3 | ||||
-rw-r--r-- | src/eventcomm.c | 1 | ||||
-rw-r--r-- | src/ps2comm.c | 13 | ||||
-rw-r--r-- | src/ps2comm.h | 3 | ||||
-rw-r--r-- | src/psmcomm.c | 3 | ||||
-rw-r--r-- | src/synaptics.c | 3 | ||||
-rw-r--r-- | src/synproto.h | 1 |
7 files changed, 16 insertions, 11 deletions
diff --git a/src/alpscomm.c b/src/alpscomm.c index 56f74ac..3872f5c 100644 --- a/src/alpscomm.c +++ b/src/alpscomm.c @@ -33,10 +33,10 @@ #endif #include <xorg-server.h> -#include "ps2comm.h" #include "synproto.h" #include "synaptics.h" #include "synapticsstr.h" +#include "ps2comm.h" #include <xf86.h> @@ -206,7 +206,6 @@ ALPS_process_packet(unsigned char *packet, struct SynapticsHwState *hw) static Bool ALPSReadHwState(InputInfoPtr pInfo, - struct SynapticsProtocolOperations *proto_ops, struct CommData *comm, struct SynapticsHwState *hwRet) { unsigned char *buf = comm->protoBuf; diff --git a/src/eventcomm.c b/src/eventcomm.c index 1a31c54..d394d3f 100644 --- a/src/eventcomm.c +++ b/src/eventcomm.c @@ -316,7 +316,6 @@ SynapticsReadEvent(InputInfoPtr pInfo, struct input_event *ev) static Bool EventReadHwState(InputInfoPtr pInfo, - struct SynapticsProtocolOperations *proto_ops, struct CommData *comm, struct SynapticsHwState *hwRet) { struct input_event ev; diff --git a/src/ps2comm.c b/src/ps2comm.c index 6991d22..a6e052c 100644 --- a/src/ps2comm.c +++ b/src/ps2comm.c @@ -37,10 +37,10 @@ #endif #include <xorg-server.h> -#include "ps2comm.h" #include "synproto.h" #include "synaptics.h" #include "synapticsstr.h" +#include "ps2comm.h" #include <xf86.h> #define MAX_UNSYNC_PACKETS 10 /* i.e. 10 to 60 bytes */ @@ -513,8 +513,8 @@ ps2_synaptics_get_packet(InputInfoPtr pInfo, struct PS2SynapticsHwInfo *synhw, return FALSE; } -static Bool -PS2ReadHwState(InputInfoPtr pInfo, +Bool +PS2ReadHwStateProto(InputInfoPtr pInfo, struct SynapticsProtocolOperations *proto_ops, struct CommData *comm, struct SynapticsHwState *hwRet) { @@ -654,6 +654,13 @@ PS2ReadHwState(InputInfoPtr pInfo, } static Bool +PS2ReadHwState(InputInfoPtr pInfo, + struct CommData *comm, struct SynapticsHwState *hwRet) +{ + return PS2ReadHwStateProto(pInfo, &psaux_proto_operations, comm, hwRet); +} + +static Bool PS2AutoDevProbe(InputInfoPtr pInfo) { return FALSE; diff --git a/src/ps2comm.h b/src/ps2comm.h index 2cf6a23..006cc3f 100644 --- a/src/ps2comm.h +++ b/src/ps2comm.h @@ -103,5 +103,8 @@ struct PS2SynapticsHwInfo { Bool ps2_putbyte(int fd, byte b); void ps2_print_ident(const struct PS2SynapticsHwInfo *synhw); +Bool PS2ReadHwStateProto(InputInfoPtr pInfo, + struct SynapticsProtocolOperations *proto_ops, + struct CommData *comm, struct SynapticsHwState *hwRet); #endif /* _PS2COMM_H_ */ diff --git a/src/psmcomm.c b/src/psmcomm.c index 596db48..eec240c 100644 --- a/src/psmcomm.c +++ b/src/psmcomm.c @@ -157,10 +157,9 @@ PSMQueryHardware(InputInfoPtr pInfo) static Bool PSMReadHwState(InputInfoPtr pInfo, - struct SynapticsProtocolOperations *proto_ops, struct CommData *comm, struct SynapticsHwState *hwRet) { - return psaux_proto_operations.ReadHwState(pInfo, proto_ops, comm, hwRet); + return PS2ReadHwStateProto(pInfo, &psm_proto_operations, comm, hwRet); } static Bool PSMAutoDevProbe(InputInfoPtr pInfo) diff --git a/src/synaptics.c b/src/synaptics.c index 0b1681a..9980dcc 100644 --- a/src/synaptics.c +++ b/src/synaptics.c @@ -1254,8 +1254,7 @@ static Bool SynapticsGetHwState(InputInfoPtr pInfo, SynapticsPrivate *priv, struct SynapticsHwState *hw) { - return priv->proto_ops->ReadHwState(pInfo, priv->proto_ops, - &priv->comm, hw); + return priv->proto_ops->ReadHwState(pInfo, &priv->comm, hw); } /* diff --git a/src/synproto.h b/src/synproto.h index a899a73..3fe70b9 100644 --- a/src/synproto.h +++ b/src/synproto.h @@ -86,7 +86,6 @@ struct SynapticsProtocolOperations { void (*DeviceOffHook)(InputInfoPtr pInfo); Bool (*QueryHardware)(InputInfoPtr pInfo); Bool (*ReadHwState)(InputInfoPtr pInfo, - struct SynapticsProtocolOperations *proto_ops, struct CommData *comm, struct SynapticsHwState *hwRet); Bool (*AutoDevProbe)(InputInfoPtr pInfo); void (*ReadDevDimensions)(InputInfoPtr pInfo); |