diff --git a/src/xrt/include/xrt/xrt_prober.h b/src/xrt/include/xrt/xrt_prober.h index 9b33f7f06..eb224e405 100644 --- a/src/xrt/include/xrt/xrt_prober.h +++ b/src/xrt/include/xrt/xrt_prober.h @@ -152,12 +152,6 @@ enum xrt_prober_string XRT_PROBER_STRING_SERIAL_NUMBER, }; -const char * -xrt_prober_string_to_string(enum xrt_prober_string t); - -const char * -xrt_bus_type_to_string(enum xrt_bus_type t); - /*! * A probed device, may or may not be opened. * @@ -473,14 +467,6 @@ xrt_prober_destroy(struct xrt_prober **xp_ptr) int xrt_prober_create_with_lists(struct xrt_prober **out_xp, struct xrt_prober_entry_lists *list); -/*! - * @public @memberof xrt_prober - */ -bool -xrt_prober_match_string(struct xrt_prober *xp, - struct xrt_prober_device *dev, - enum xrt_prober_string type, - const char *to_match); /* * diff --git a/src/xrt/state_trackers/prober/p_prober.c b/src/xrt/state_trackers/prober/p_prober.c index 590d50b6c..a39d04cfd 100644 --- a/src/xrt/state_trackers/prober/p_prober.c +++ b/src/xrt/state_trackers/prober/p_prober.c @@ -144,46 +144,6 @@ xrt_prober_create_with_lists(struct xrt_prober **out_xp, struct xrt_prober_entry return 0; } -#define ENUM_TO_STR(r) \ - case r: return #r - -const char * -xrt_prober_string_to_string(enum xrt_prober_string t) -{ - switch (t) { - ENUM_TO_STR(XRT_PROBER_STRING_MANUFACTURER); - ENUM_TO_STR(XRT_PROBER_STRING_PRODUCT); - ENUM_TO_STR(XRT_PROBER_STRING_SERIAL_NUMBER); - } - return ""; -} - -const char * -xrt_bus_type_to_string(enum xrt_bus_type t) -{ - switch (t) { - ENUM_TO_STR(XRT_BUS_TYPE_UNKNOWN); - ENUM_TO_STR(XRT_BUS_TYPE_USB); - ENUM_TO_STR(XRT_BUS_TYPE_BLUETOOTH); - } - return ""; -} - -bool -xrt_prober_match_string(struct xrt_prober *xp, - struct xrt_prober_device *dev, - enum xrt_prober_string type, - const char *to_match) -{ - unsigned char s[256] = {0}; - int len = xrt_prober_get_string_descriptor(xp, dev, type, s, sizeof(s)); - if (len <= 0) { - return false; - } - - return 0 == strncmp(to_match, (const char *)s, sizeof(s)); -} - int p_dev_get_usb_dev(struct prober *p, uint16_t bus,