From a079b04ac8bf2ce26f20e6c5887fce6d4cefd4e8 Mon Sep 17 00:00:00 2001 From: jsteube Date: Sat, 5 Nov 2016 23:34:17 +0100 Subject: [PATCH] Add missing files --- include/ext_sysfs.h | 25 +++++++++++++++++++++++++ src/ext_sysfs.c | 7 +++++++ 2 files changed, 32 insertions(+) create mode 100644 include/ext_sysfs.h create mode 100644 src/ext_sysfs.c diff --git a/include/ext_sysfs.h b/include/ext_sysfs.h new file mode 100644 index 000000000..8ce8cddd7 --- /dev/null +++ b/include/ext_sysfs.h @@ -0,0 +1,25 @@ +/** + * Author......: See docs/credits.txt + * License.....: MIT + */ + +#ifndef _EXT_SYSFS_H +#define _EXT_SYSFS_H + +static const char SYS_BUS_PCI_DEVICES[] = "/sys/bus/pci/devices"; + +typedef int HM_ADAPTER_SYSFS; + +typedef void *SYSFS_LIB; + +typedef struct hm_sysfs_lib +{ + // currently not using libudev, because it can only read values, not set them, so using /sys instead + + SYSFS_LIB lib; + +} hm_sysfs_lib_t; + +typedef hm_sysfs_lib_t SYSFS_PTR; + +#endif // _EXT_SYSFS_H diff --git a/src/ext_sysfs.c b/src/ext_sysfs.c new file mode 100644 index 000000000..b4898950d --- /dev/null +++ b/src/ext_sysfs.c @@ -0,0 +1,7 @@ +/** + * Author......: See docs/credits.txt + * License.....: MIT + */ + +#include "common.h" +#include "ext_sysfs.h"