hidpp10: remove hidpp10_device_new_from_wpid

hidpp10_device_new_from_wpid() can not work anymore given that we are not
talking to the receiver anymore, but directly to the device.

The proof being that .wpid is never set in struct hidpp10_device.

Signed-off-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
This commit is contained in:
Benjamin Tissoires
2015-10-20 17:56:58 -04:00
parent 06c742d172
commit 40fe1b0eac
2 changed files with 0 additions and 24 deletions

View File

@@ -1238,26 +1238,6 @@ hidpp10_device_new(const struct hidpp_device *base,
return dev;
}
struct hidpp10_device*
hidpp10_device_new_from_wpid(const struct hidpp_device *base, uint16_t wpid)
{
struct hidpp10_device *dev;
int i;
for (i = 1; i < 7; i++) {
dev = hidpp10_device_new_from_idx(base, i);
if (!dev)
continue;
if (dev->wpid == wpid)
return dev;
hidpp10_device_destroy(dev);
}
return NULL;
}
struct hidpp10_device*
hidpp10_device_new_from_idx(const struct hidpp_device *base, int idx)
{

View File

@@ -43,12 +43,8 @@
struct hidpp10_device {
struct hidpp_device base;
unsigned index;
uint16_t wpid;
};
struct hidpp10_device*
hidpp10_device_new_from_wpid(const struct hidpp_device *base,
uint16_t wpid);
struct hidpp10_device*
hidpp10_device_new_from_idx(const struct hidpp_device *base,
int idx);