summaryrefslogtreecommitdiffstats
path: root/lspcidrake.c
diff options
context:
space:
mode:
authorChristophe Fergeau <cfergeau@mandriva.com>2009-04-03 17:46:36 +0000
committerChristophe Fergeau <cfergeau@mandriva.com>2009-04-03 17:46:36 +0000
commit9915986c57ea14e19c2f049dc0d06a84b2e2a87a (patch)
tree2f3a7d9682813641628ad669729b9053c708cc9c /lspcidrake.c
parent8569a28793faad34b2697591bdc6519c28462ca7 (diff)
downloadldetect-9915986c57ea14e19c2f049dc0d06a84b2e2a87a.tar
ldetect-9915986c57ea14e19c2f049dc0d06a84b2e2a87a.tar.gz
ldetect-9915986c57ea14e19c2f049dc0d06a84b2e2a87a.tar.bz2
ldetect-9915986c57ea14e19c2f049dc0d06a84b2e2a87a.tar.xz
ldetect-9915986c57ea14e19c2f049dc0d06a84b2e2a87a.zip
Enumerate hid entries
Diffstat (limited to 'lspcidrake.c')
-rw-r--r--lspcidrake.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/lspcidrake.c b/lspcidrake.c
index 6883463..94ee003 100644
--- a/lspcidrake.c
+++ b/lspcidrake.c
@@ -51,6 +51,13 @@ static void print_dmi_entries(struct dmi_entries entries) {
printf("%-16s: %s\n", entries.entries[i].module, entries.entries[i].constraints);
}
+static void print_hid_entries(struct hid_entries entries) {
+ unsigned int i;
+ for (i = 0; i < entries.nb; i++)
+ printf("%-16s: %s\n", entries.entries[i].module,
+ entries.entries[i].text);
+}
+
static void usage(void)
{
printf(
@@ -101,5 +108,11 @@ int main(int argc, char **argv) {
dmi_entries_free(dmi_entries);
}
+ if (!fake || sysfs_hid_path) {
+ struct hid_entries hid_entries = hid_probe();
+ print_hid_entries(hid_entries);
+ hid_entries_free(&hid_entries);
+ }
+
return 0;
}