From 8e4bff4cab0ddac6060645b0715210484d02ff40 Mon Sep 17 00:00:00 2001 From: Yuval Adam <_@yuv.al> Date: Wed, 30 Aug 2017 08:25:59 +0000 Subject: Initial file dump from open source release --- tools/gator/daemon/UserSpaceSource.h | 38 ++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 tools/gator/daemon/UserSpaceSource.h (limited to 'tools/gator/daemon/UserSpaceSource.h') diff --git a/tools/gator/daemon/UserSpaceSource.h b/tools/gator/daemon/UserSpaceSource.h new file mode 100644 index 00000000..9b366601 --- /dev/null +++ b/tools/gator/daemon/UserSpaceSource.h @@ -0,0 +1,38 @@ +/** + * Copyright (C) ARM Limited 2010-2014. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#ifndef USERSPACESOURCE_H +#define USERSPACESOURCE_H + +#include + +#include "Buffer.h" +#include "Source.h" + +// User space counters +class UserSpaceSource : public Source { +public: + UserSpaceSource(sem_t *senderSem); + ~UserSpaceSource(); + + bool prepare(); + void run(); + void interrupt(); + + bool isDone(); + void write(Sender *sender); + +private: + Buffer mBuffer; + + // Intentionally unimplemented + UserSpaceSource(const UserSpaceSource &); + UserSpaceSource &operator=(const UserSpaceSource &); +}; + +#endif // USERSPACESOURCE_H -- cgit v1.3.1