Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
tools
Manage
Activity
Members
Plan
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
CodeLinaro
public-release-test-restored
platform
vendor
qcom-opensource
tools
Commits
7f9ed666
Commit
7f9ed666
authored
8 years ago
by
Linux Build Service Account
Committed by
Gerrit - the friendly Code Review server
8 years ago
Browse files
Options
Downloads
Plain Diff
Merge "lrdp_v2: config value changes"
parents
978f7686
3aa49913
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
linux-ramdump-parser-v2/mm.py
+16
-3
16 additions, 3 deletions
linux-ramdump-parser-v2/mm.py
with
16 additions
and
3 deletions
linux-ramdump-parser-v2/mm.py
100755 → 100644
+
16
−
3
View file @
7f9ed666
# Copyright (c) 2013-201
5
, The Linux Foundation. All rights reserved.
# Copyright (c) 2013-201
6
, The Linux Foundation. All rights reserved.
#
#
# This program is free software; you can redistribute it and/or modify
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 and
# it under the terms of the GNU General Public License version 2 and
...
@@ -24,6 +24,7 @@ def get_debug_flags(ramdump, page):
...
@@ -24,6 +24,7 @@ def get_debug_flags(ramdump, page):
flagval
=
ramdump
.
read_word
(
page
+
debug_flag_offset
)
flagval
=
ramdump
.
read_word
(
page
+
debug_flag_offset
)
return
flagval
return
flagval
def
page_zonenum
(
page_flags
):
def
page_zonenum
(
page_flags
):
# save this in a variable somewhere...
# save this in a variable somewhere...
return
(
page_flags
>>
26
)
&
3
return
(
page_flags
>>
26
)
&
3
...
@@ -134,7 +135,11 @@ def get_vmemmap(ramdump):
...
@@ -134,7 +135,11 @@ def get_vmemmap(ramdump):
# See: include/asm-generic/pgtable-nopud.h,
# See: include/asm-generic/pgtable-nopud.h,
# arch/arm64/include/asm/pgtable-hwdef.h,
# arch/arm64/include/asm/pgtable-hwdef.h,
# arch/arm64/include/asm/pgtable.h
# arch/arm64/include/asm/pgtable.h
nlevels
=
int
(
ramdump
.
get_config_val
(
"
CONFIG_ARM64_PGTABLE_LEVELS
"
))
if
(
ramdump
.
kernel_version
<
(
3
,
18
,
0
)):
nlevels
=
int
(
ramdump
.
get_config_val
(
"
CONFIG_ARM64_PGTABLE_LEVELS
"
))
else
:
nlevels
=
int
(
ramdump
.
get_config_val
(
"
CONFIG_PGTABLE_LEVELS
"
))
if
ramdump
.
is_config_defined
(
"
CONFIG_ARM64_64K_PAGES
"
):
if
ramdump
.
is_config_defined
(
"
CONFIG_ARM64_64K_PAGES
"
):
page_shift
=
16
page_shift
=
16
else
:
else
:
...
@@ -146,7 +151,15 @@ def get_vmemmap(ramdump):
...
@@ -146,7 +151,15 @@ def get_vmemmap(ramdump):
spsize
=
ramdump
.
sizeof
(
'
struct page
'
)
spsize
=
ramdump
.
sizeof
(
'
struct page
'
)
vmemmap_size
=
bitops
.
align
((
1
<<
(
va_bits
-
page_shift
))
*
spsize
,
vmemmap_size
=
bitops
.
align
((
1
<<
(
va_bits
-
page_shift
))
*
spsize
,
pud_size
)
pud_size
)
vmalloc_end
=
ramdump
.
page_offset
-
pud_size
-
vmemmap_size
if
(
ramdump
.
kernel_version
<
(
3
,
18
,
31
)):
vmalloc_end
=
ramdump
.
page_offset
-
pud_size
-
vmemmap_size
# vmalloc_end = 0xFFFFFFBC00000000
else
:
# for version >= 3.18.31,
# vmemmap is shifted to base addr (0x80000000) pfn.
pfn_offset
=
(
ramdump
.
phys_offset
>>
page_shift
)
offset
=
pfn_offset
*
spsize
vmalloc_end
=
ramdump
.
page_offset
-
pud_size
-
vmemmap_size
-
offset
return
vmalloc_end
return
vmalloc_end
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment