Skip to content

Commit fa83cb0

Browse files
committed
8.0.4
1 parent 7204833 commit fa83cb0

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+891
-822
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ src/qxk/qxk.cpp
4949
src/qxk/qxk_mutex.cpp
5050
src/qxk/qxk_sema.cpp
5151
src/qxk/qxk_xthr.cpp
52+
zephyr/qutest_port.cpp
5253

5354
ports/arm-cm/qxk/
5455
ports/arm-cm/qutest/

examples

Submodule examples updated 193 files

include/qequeue.hpp

Lines changed: 19 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -51,31 +51,8 @@ class QEvt; // forward declaration
5151
namespace QP {
5252

5353
class QEQueue {
54-
private:
55-
QEvt const * volatile m_frontEvt;
56-
QEvt const * * m_ring;
57-
QEQueueCtr m_end;
58-
QEQueueCtr volatile m_head;
59-
QEQueueCtr volatile m_tail;
60-
QEQueueCtr volatile m_nFree;
61-
QEQueueCtr m_nMin;
62-
63-
// friends...
64-
friend class QActive;
65-
friend class QTicker;
66-
friend class QXMutex;
67-
friend class QXThread;
68-
6954
public:
70-
QEQueue() noexcept
71-
: m_frontEvt(nullptr),
72-
m_ring(nullptr),
73-
m_end(0U),
74-
m_head(0U),
75-
m_tail(0U),
76-
m_nFree(0U),
77-
m_nMin(0U)
78-
{}
55+
QEQueue() noexcept;
7956
void init(
8057
QEvt const * * const qSto,
8158
std::uint_fast16_t const qLen) noexcept;
@@ -96,13 +73,31 @@ class QEQueue {
9673
bool isEmpty() const noexcept {
9774
return m_frontEvt == nullptr;
9875
}
76+
QEvt const *peekFront() const noexcept {
77+
return m_frontEvt;
78+
}
9979

10080
private:
81+
QEvt const * volatile m_frontEvt;
82+
QEvt const * * m_ring;
83+
QEQueueCtr m_end;
84+
QEQueueCtr volatile m_head;
85+
QEQueueCtr volatile m_tail;
86+
QEQueueCtr volatile m_nFree;
87+
QEQueueCtr m_nMin;
88+
10189
QEQueue(QEQueue const & other) = delete;
10290
QEQueue & operator=(QEQueue const & other) = delete;
10391
void postFIFO_(
10492
QEvt const * const e,
10593
void const * const sender);
94+
95+
// friends...
96+
friend class QActive;
97+
friend class QTicker;
98+
friend class QXMutex;
99+
friend class QXThread;
100+
friend class QS;
106101
}; // class QEQueue
107102

108103
} // namespace QP

include/qk.hpp

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -41,22 +41,16 @@ extern "C" {
4141
class QK_Attr {
4242
public:
4343
QP::QPSet readySet;
44-
std::uint_fast8_t actPrio;
45-
std::uint_fast8_t nextPrio;
46-
std::uint_fast8_t actThre;
47-
std::uint_fast8_t lockCeil;
48-
std::uint_fast8_t intNest;
44+
std::uint8_t actPrio;
45+
std::uint8_t nextPrio;
46+
std::uint8_t actThre;
47+
std::uint8_t lockCeil;
48+
std::uint8_t intNest;
4949
}; // class QK_Attr
5050

5151
extern QK_Attr QK_priv_;
5252

53-
std::uint_fast8_t QK_sched_() noexcept;
54-
55-
std::uint_fast8_t QK_sched_act_(
56-
QP::QActive const * const act,
57-
std::uint_fast8_t const pthre_in) noexcept;
58-
59-
void QK_activate_() noexcept;
53+
// NOTE: the extern "C" QK functions already declared in qp.hpp
6054

6155
} // extern "C"
6256

include/qmpool.hpp

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -76,15 +76,7 @@ class QMPool {
7676
QMPoolCtr m_nMin;
7777

7878
public:
79-
QMPool()
80-
: m_start(nullptr),
81-
m_end(nullptr),
82-
m_freeHead(nullptr),
83-
m_blockSize(0U),
84-
m_nTot(0U),
85-
m_nFree(0U),
86-
m_nMin(0U)
87-
{}
79+
QMPool() noexcept;
8880
void init(
8981
void * const poolSto,
9082
std::uint_fast32_t const poolSize,
@@ -113,13 +105,16 @@ class QMPool {
113105
QMPool(QEQueue const & other) = delete;
114106
QMPool & operator=(QMPool const & other) = delete;
115107

108+
// friends...
109+
friend class QS;
110+
116111
public:
117112

118113
#ifdef QF_ISR_API
119114
void * getFromISR(
120115
std::uint_fast16_t const margin,
121116
std::uint_fast8_t const qsId) noexcept;
122-
#endif // def QF_ISR_API
117+
#endif
123118

124119
#ifdef QF_ISR_API
125120
void putFromISR(

0 commit comments

Comments
 (0)