Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
60051a1a
Commit
60051a1a
authored
Aug 16, 2017
by
Claes Sjofors
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Monotonic time used in qcom_Get() and que_Get(), and Shutdown fix for qdb lock
parent
572c35e0
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
5 deletions
+8
-5
src/lib/rt/src/os_linux/rt_qos.c
src/lib/rt/src/os_linux/rt_qos.c
+2
-2
src/lib/rt/src/rt_qdb.c
src/lib/rt/src/rt_qdb.c
+3
-1
src/lib/rt/src/rt_thread.c
src/lib/rt/src/rt_thread.c
+3
-2
No files found.
src/lib/rt/src/os_linux/rt_qos.c
View file @
60051a1a
...
...
@@ -154,7 +154,7 @@ qos_WaitQue (
qdb_Unlock
;
if
(
tmo
!=
qcom_cTmoEternal
)
{
time_GetTime
(
&
atime
);
time_GetTime
Monotonic
(
&
atime
);
time_MsToD
(
&
dtime
,
tmo
);
time_Aadd
(
&
atime
,
&
atime
,
&
dtime
);
atime_ts
.
tv_sec
=
atime
.
tv_sec
;
...
...
@@ -248,4 +248,4 @@ qos_DeleteQlock (
qdb_AssumeLocked
;
}
\ No newline at end of file
}
src/lib/rt/src/rt_qdb.c
View file @
60051a1a
...
...
@@ -1104,6 +1104,7 @@ qdb_Put (
}
break
;
default:
qdb_Unlock
;
errh_Bugcheck
(
QCOM__WEIRD
,
"unknown queue type"
);
}
}
...
...
@@ -1240,6 +1241,7 @@ qdb_AddQue (
qp
->
qix
=
qix
;
pthread_condattr_init
(
&
condattr
);
pthread_condattr_setclock
(
&
condattr
,
CLOCK_MONOTONIC
);
#if !defined OS_OPENBSD
pthread_condattr_setpshared
(
&
condattr
,
PTHREAD_PROCESS_SHARED
);
#endif
...
...
@@ -1562,4 +1564,4 @@ qdb_Wait (
pool_QinsertPred
(
NULL
,
&
qdb
->
pool
,
&
qp
->
eve_ll
,
&
ep
->
eve_lh
);
return
qos_WaitQue
(
sts
,
qp
,
tmo
);
}
\ No newline at end of file
}
src/lib/rt/src/rt_thread.c
View file @
60051a1a
...
...
@@ -60,6 +60,7 @@ thread_CondInit (
#elif defined OS_POSIX
pthread_condattr_t
attr
;
pthread_condattr_init
(
&
attr
);
pthread_condattr_setclock
(
&
attr
,
CLOCK_MONOTONIC
);
return
errno_Status
(
pthread_cond_init
(
&
cp
->
c
,
&
attr
));
#else
# error Not defined for this platform !
...
...
@@ -204,7 +205,7 @@ thread_CondTimedWait (
if
(
time
==
NULL
||
time
->
tv_sec
>
100000000
)
return
thread_CondWait
(
cp
,
mp
);
time_GetTime
(
&
now
);
time_GetTime
Monotonic
(
&
now
);
time_Aadd
(
&
then
,
&
now
,
time
);
then_ts
.
tv_sec
=
then
.
tv_sec
;
then_ts
.
tv_nsec
=
then
.
tv_nsec
;
...
...
@@ -393,4 +394,4 @@ thread_SigTimedWait (
return
signal
;
}
#endif
\ No newline at end of file
#endif
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment