Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
d5ffce3b
Commit
d5ffce3b
authored
Sep 27, 2002
by
Christoph Hellwig
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
XFS: XFS: Use do_gettimeofday() instead of racy direct access to xtime
Modid: 2.5.x-xfs:slinx:127568a
parent
0cd9efe3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
fs/xfs/support/time.h
fs/xfs/support/time.h
+6
-2
No files found.
fs/xfs/support/time.h
View file @
d5ffce3b
...
@@ -33,6 +33,7 @@
...
@@ -33,6 +33,7 @@
#define __XFS_SUPPORT_TIME_H__
#define __XFS_SUPPORT_TIME_H__
#include <linux/sched.h>
#include <linux/sched.h>
#include <linux/time.h>
static
inline
void
delay
(
long
ticks
)
static
inline
void
delay
(
long
ticks
)
{
{
...
@@ -42,8 +43,11 @@ static inline void delay(long ticks)
...
@@ -42,8 +43,11 @@ static inline void delay(long ticks)
static
inline
void
nanotime
(
struct
timespec
*
tvp
)
static
inline
void
nanotime
(
struct
timespec
*
tvp
)
{
{
tvp
->
tv_sec
=
xtime
.
tv_sec
;
struct
timeval
tv
;
tvp
->
tv_nsec
=
xtime
.
tv_nsec
;
do_gettimeofday
(
&
tv
);
tvp
->
tv_sec
=
tv
.
tv_sec
;
tvp
->
tv_nsec
=
tv
.
tv_usec
*
1000
;
}
}
#endif
/* __XFS_SUPPORT_TIME_H__ */
#endif
/* __XFS_SUPPORT_TIME_H__ */
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