Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
wendelin.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
Kirill Smelkov
wendelin.core
Commits
c7dd2e52
Commit
c7dd2e52
authored
Oct 01, 2019
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
5da97fd3
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
7 deletions
+7
-7
wcfs/__init__.py
wcfs/__init__.py
+5
-5
wcfs/wcfs_test.py
wcfs/wcfs_test.py
+2
-2
No files found.
wcfs/__init__.py
View file @
c7dd2e52
...
@@ -232,12 +232,12 @@ def _pin1(wconn, req):
...
@@ -232,12 +232,12 @@ def _pin1(wconn, req):
continue
# blk ∉ mmap
continue
# blk ∉ mmap
trace
(
'
\
t
remmapblk %d @%s'
%
(
req
.
blk
,
(
h
(
req
.
at
)
if
req
.
at
else
"head"
)))
trace
(
'
\
t
remmapblk %d @%s'
%
(
req
.
blk
,
(
h
(
req
.
at
)
if
req
.
at
else
"head"
)))
# FIXME check if virtmem did not
mapped RW page in
to this block already
# FIXME check if virtmem did not
dirtied page corresponding
to this block already
#
-> check if virtmem did not dirtied page corresponding to this block already
#
virt_lock()
virt_lock
()
#if not fileh_blk_isdirty(mmap.fileh, req.blk):
if
not
fileh_blk_isdirty
(
mmap
.
fileh
,
req
.
blk
)
:
if
1
:
mmap
.
_remmapblk
(
req
.
blk
,
req
.
at
)
mmap
.
_remmapblk
(
req
.
blk
,
req
.
at
)
virt
unlock
()
#virt_
unlock()
trace
(
'
\
t
-> remmaped'
)
trace
(
'
\
t
-> remmaped'
)
# update f.pinned
# update f.pinned
...
...
wcfs/wcfs_test.py
View file @
c7dd2e52
...
@@ -1703,7 +1703,7 @@ class tMapping(object):
...
@@ -1703,7 +1703,7 @@ class tMapping(object):
# XXX assertCache
# XXX assertCache
# assertBlk asserts that mmap[·] with · corresponding to blk
has
reads as dataok.
# assertBlk asserts that mmap[·] with · corresponding to blk reads as dataok.
# see also: tFile.assertBlk .
# see also: tFile.assertBlk .
def
assertBlk
(
t
,
blk
,
dataok
):
def
assertBlk
(
t
,
blk
,
dataok
):
assert
t
.
mmap
.
blk_start
<=
blk
<
t
.
mmap
.
blk_stop
assert
t
.
mmap
.
blk_start
<=
blk
<
t
.
mmap
.
blk_stop
...
@@ -1719,7 +1719,7 @@ class tMapping(object):
...
@@ -1719,7 +1719,7 @@ class tMapping(object):
# XXX first access without GIL, so that e.g. if there is timeout on
# XXX first access without GIL, so that e.g. if there is timeout on
# wcfs.py side, _abort_ontimeout could run and kill WCFS.
# wcfs.py side, _abort_ontimeout could run and kill WCFS.
# FIXME also test with GIL locked, since wcfs.py pinner must be itself
# FIXME also test with GIL locked, since wcfs.py pinner must be itself
# running without GIL.
# running without GIL.
XXX
_
=
read_nogil
(
blkview
[:
1
])
_
=
read_nogil
(
blkview
[:
1
])
assert
_
==
dataok
[
0
]
assert
_
==
dataok
[
0
]
assert
blkview
.
tobytes
()
==
dataok
assert
blkview
.
tobytes
()
==
dataok
...
...
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