diff --git a/util-linux/lsusb.c b/util-linux/lsusb.c
index 7c5b6b9..c15b8ca 100644
--- a/util-linux/lsusb.c
+++ b/util-linux/lsusb.c
@@ -15,37 +15,41 @@
 		int depth UNUSED_PARAM)
 {
 	parser_t *parser;
-	char *tokens[6];
-	char *bus = NULL, *device = NULL;
+	char *tokens[4];
+	char *busnum = NULL, *devnum = NULL;
 	int product_vid = 0, product_did = 0;
-
 	char *uevent_filename = concat_path_file(fileName, "/uevent");
+
 	parser = config_open2(uevent_filename, fopen_for_read);
 	free(uevent_filename);
 
-	while (config_read(parser, tokens, 6, 1, "\\/=", PARSE_NORMAL)) {
+	while (config_read(parser, tokens, 4, 2, "\\/=", PARSE_NORMAL)) {
 		if ((parser->lineno == 1) && strcmp(tokens[0], "DEVTYPE") == 0) {
 			break;
 		}
 
-		if (strcmp(tokens[0], "DEVICE") == 0) {
-			bus = xstrdup(tokens[4]);
-			device = xstrdup(tokens[5]);
-			continue;
-		}
-
 		if (strcmp(tokens[0], "PRODUCT") == 0) {
 			product_vid = xstrtou(tokens[1], 16);
 			product_did = xstrtou(tokens[2], 16);
 			continue;
 		}
+
+		if (strcmp(tokens[0], "BUSNUM") == 0) {
+			busnum = xstrdup(tokens[1]);
+			continue;
+		}
+
+		if (strcmp(tokens[0], "DEVNUM") == 0) {
+			devnum = xstrdup(tokens[1]);
+			continue;
+		}
 	}
 	config_close(parser);
 
-	if (bus) {
-		printf("Bus %s Device %s: ID %04x:%04x\n", bus, device, product_vid, product_did);
-		free(bus);
-		free(device);
+	if (busnum) {
+		printf("Bus %s Device %s: ID %04x:%04x\n", busnum, devnum, product_vid, product_did);
+		free(busnum);
+		free(devnum);
 	}
 
 	return TRUE;
