16 |
16 |
17 |
17 |
18 |
18 |
19 USE_PAGING = 0 |
19 USE_PAGING = 0 |
20 |
20 |
21 USE_PAGEDROM = $(if $(filter rom code code:%,$(call lcase,$(USE_PAGING))),1,0) |
21 USE_PAGEDROM = $(if $(or $(call true,$(USE_PAGEDCODE)$(USE_PAGEDDATA)),$(filter rom,$(call lcase,$(USE_PAGING)))),1,0) |
22 USE_PAGEDCODE = $(call _getcodedp) |
22 USE_PAGEDCODE = $(call _getcodedp) |
|
23 USE_PAGEDDATA = $(if $(filter data,$(call lcase,$(USE_PAGING))),1,0) |
23 |
24 |
24 ODP_CONFDIR = $(E32ROM)/configpaging |
25 ODP_CONFDIR = $(E32ROM)/configpaging |
25 ODP_PAGEFILE = configpaging.cfg |
26 ODP_PAGEFILE = $(call iif,$(USE_PAGEDDATA),configpaging_wdp.cfg,configpaging.cfg) |
26 ODP_CODECOMP = bytepair |
27 ODP_CODECOMP = bytepair |
27 |
28 |
28 # Min Max Young/Old NAND page read NAND page read |
29 ODP_ROMCONF =\ |
29 # live live page ratio delay CPU overhead |
30 $(or $(SYMBIAN_ODP_NUMBER_OF_MIN_LIVE_PAGES),1024)\ |
30 # pages pages (microseconds) (microseconds) |
31 $(or $(SYMBIAN_ODP_NUMBER_OF_MAX_LIVE_PAGES),2048)\ |
31 ODP_ROMCONF = 1024 2048 3 0 0 |
32 $(or $(SYMBIAN_ODP_YOUNG_OLD_PAGE_RATIO),3)\ |
|
33 $(or $(SYMBIAN_ODP_NAND_PAGE_READ_DELAY),0)\ |
|
34 $(or $(SYMBIAN_ODP_NAND_PAGE_NAND_PAGE_READ_CPU_OVERHEAD),0) |
32 |
35 |
33 # Section for Rombuild phase on all Demand Paging builds |
36 # Section for Rombuild on all Demand Paging builds |
34 # |
37 # |
35 define ODP_ROMINFO |
38 define ODP_ROMINFO |
|
39 $(call iif,$(USE_PAGEDDATA), |
|
40 #if defined(FF_WDP_EMMC) && defined(FF_WDP_NAND) |
|
41 #error ERROR: Both of the flags FF_WDP_EMMC and FF_WDP_NAND are defined! |
|
42 #elif !defined(FF_WDP_EMMC) && !defined(FF_WDP_NAND) |
|
43 #error ERROR: One of the flags FF_WDP_EMMC or FF_WDP_NAND should be defined! |
|
44 #endif |
|
45 , |
|
46 #undef FF_WDP_EMMC |
|
47 #undef FF_WDP_NAND |
|
48 ) |
36 $(call iif,$(USE_PAGEDROM), |
49 $(call iif,$(USE_PAGEDROM), |
37 #define PAGED_ROM |
50 #define PAGED_ROM |
38 ROMBUILD_OPTION -geninc |
51 ROMBUILD_OPTION -geninc |
39 demandpagingconfig $(strip $(ODP_ROMCONF)) |
|
40 pagingoverride defaultpaged |
|
41 pagedrom |
52 pagedrom |
42 compress |
53 compress |
|
54 demandpagingconfig $(strip $(ODP_ROMCONF)) |
|
55 codepagingoverride defaultpaged |
|
56 $(call iif,$(USE_PAGEDDATA), |
|
57 datapagingoverride defaultunpaged |
|
58 , |
|
59 datapagingoverride nopaging) |
43 ) |
60 ) |
44 $(if $(filter 1,$(USE_PAGEDCODE)), |
61 $(if $(filter 1,$(USE_PAGEDCODE)), |
45 #define PAGED_CODE |
62 #define PAGED_CODE |
46 pagingpolicy defaultpaged |
63 codepagingpolicy defaultpaged |
|
64 $(call iif,$(USE_PAGEDDATA), |
|
65 datapagingpolicy defaultunpaged |
|
66 , |
|
67 datapagingpolicy nopaging) |
47 ) |
68 ) |
48 $(if $(CORE_PAGEFILE),$(call iif,$(USE_PAGEDROM)$(filter 1,$(USE_PAGEDCODE)), |
69 $(if $(CORE_PAGEFILE),$(call iif,$(USE_PAGEDROM)$(filter 1,$(USE_PAGEDCODE)), |
49 externaltool=configpaging:$(CORE_PAGEFILE)) |
70 externaltool=configpaging:$(CORE_PAGEFILE))) |
50 ) |
|
51 endef |
71 endef |
52 |
72 |
53 # Section for Rofsbuild phase on Code DP enabled builds |
73 # Section for Rofsbuild on Code/Data DP enabled builds |
54 # |
74 # |
55 define ODP_CODEINFO |
75 define ODP_ROFSINFO |
56 $(if $(filter $1,$(USE_PAGEDCODE)), |
76 $(if $(filter $(IMAGE_ID),$(USE_PAGEDCODE)), |
57 #define PAGED_CODE |
77 #define PAGED_CODE |
58 $(if $(ROFS$1_PAGEFILE), |
78 codepagingoverride defaultpaged |
59 externaltool=configpaging:$(ROFS$1_PAGEFILE)) |
79 $(call iif,$(USE_PAGEDDATA), |
60 pagingoverride defaultpaged |
80 datapagingoverride defaultunpaged |
|
81 , |
|
82 datapagingoverride nopaging |
|
83 ) |
|
84 $(if $(ROFS$(IMAGE_ID)_PAGEFILE), |
|
85 externaltool=configpaging:$(ROFS$(IMAGE_ID)_PAGEFILE)) |
61 ) |
86 ) |
62 endef |
87 endef |
63 |
88 |
64 |
89 |
65 ############################################################################### |
90 ############################################################################### |
66 # Internal stuff |
91 # Internal stuff |
67 |
92 |
68 _getcodedp = $(or $(strip\ |
93 _getcodedp = $(or $(strip\ |
69 $(if $(filter code code:,$(eval __i_paging := $(call lcase,$(call sstrip,$(USE_PAGING))))$(__i_paging)),\ |
94 $(eval __i_paging := $(call lcase,$(USE_PAGING)))\ |
70 $(foreach rofs,1 2 3 4 5 6,$(call iif,$(USE_ROFS$(rofs)),$(rofs))),\ |
95 $(foreach rofs,$(if $(filter code:%,$(__i_paging)),\ |
71 $(if $(filter code:%,$(__i_paging)),\ |
96 $(foreach rofs,1 2 3 4 5 6,$(findstring $(rofs),$(__i_paging))),\ |
72 $(foreach rofs,1 2 3 4 5 6,$(findstring $(rofs),$(__i_paging)))))),0) |
97 $(if $(or $(call true,$(USE_PAGEDDATA)),$(filter code,$(__i_paging))),1 2 3 4 5 6)),\ |
|
98 $(call iif,$(USE_ROFS$(rofs)),$(rofs)))),0) |
73 |
99 |
74 |
100 |
75 # END OF IMAKER_ODP.MK |
101 # END OF IMAKER_ODP.MK |