psusensor: remove unused fd
After enabling io-uring in [0], the underlying file is managed by the
random_access_file and the raw file descriptor is no longer used.
[0] https://gerrit.openbmc.org/c/openbmc/dbus-sensors/+/46918
Signed-off-by: Justin Ledford <justinledford@google.com>
Change-Id: Ie896f62d75ea9a461179ef807775a25bf517420a
diff --git a/include/PSUEvent.hpp b/include/PSUEvent.hpp
index 2ee7a33..824019c 100644
--- a/include/PSUEvent.hpp
+++ b/include/PSUEvent.hpp
@@ -51,7 +51,6 @@
private:
int value = 0;
- int fd{};
size_t errCount{0};
std::string path;
std::string eventName;
diff --git a/include/PSUSensor.hpp b/include/PSUSensor.hpp
index 4d7aaba..6466179 100644
--- a/include/PSUSensor.hpp
+++ b/include/PSUSensor.hpp
@@ -43,7 +43,6 @@
void checkThresholds(void) override;
unsigned int sensorPollMs = defaultSensorPollMs;
- int fd{};
static constexpr size_t warnAfterErrorCount = 10;
public:
diff --git a/src/PSUEvent.cpp b/src/PSUEvent.cpp
index 883c871..fa13ec8 100644
--- a/src/PSUEvent.cpp
+++ b/src/PSUEvent.cpp
@@ -284,7 +284,6 @@
updateValue(0);
errCount++;
}
- lseek(fd, 0, SEEK_SET);
restartRead();
}
diff --git a/src/PSUSensor.cpp b/src/PSUSensor.cpp
index af63805..9b7b38a 100644
--- a/src/PSUSensor.cpp
+++ b/src/PSUSensor.cpp
@@ -193,7 +193,6 @@
incrementError();
}
- lseek(fd, 0, SEEK_SET);
restartRead();
}