blob: 01c092e62e1b495242dea51e9422aaec4fe50f77 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
/**
* Copyright (C) ARM Limited 2010-2016. 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 <semaphore.h>
#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
|