• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

Commit MetaInfo

Revision7c1860fce4e369bdcabc1f574feb6b9af19999a3 (tree)
Time2022-07-26 15:23:54
AuthorAshok Reddy Soma <ashok.reddy.soma@xili...>
CommiterMichal Simek

Log Message

lmb: Fix lmb property's defination under struct lmb

Under struct lmb {} the lmb property's should be defined only if
CONFIG_LMB_MEMORY_REGIONS is defined.

Signed-off-by: Ashok Reddy Soma <ashok.reddy.soma@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>

Signed-off-by: Michal Simek <michal.simek@amd.com>
Link: https://lore.kernel.org/r/c24a2b1d6f5db4eb65393f6a77fae129b30b6233.1657183534.git.michal.simek@amd.com

Change Summary

Incremental Difference

--- a/include/lmb.h
+++ b/include/lmb.h
@@ -68,7 +68,7 @@ struct lmb_region {
6868 struct lmb {
6969 struct lmb_region memory;
7070 struct lmb_region reserved;
71-#if !IS_ENABLED(CONFIG_LMB_USE_MAX_REGIONS)
71+#if IS_ENABLED(CONFIG_LMB_MEMORY_REGIONS)
7272 struct lmb_property memory_regions[CONFIG_LMB_MEMORY_REGIONS];
7373 struct lmb_property reserved_regions[CONFIG_LMB_RESERVED_REGIONS];
7474 #endif
--- a/lib/lmb.c
+++ b/lib/lmb.c
@@ -108,7 +108,7 @@ void lmb_init(struct lmb *lmb)
108108 #if IS_ENABLED(CONFIG_LMB_USE_MAX_REGIONS)
109109 lmb->memory.max = CONFIG_LMB_MAX_REGIONS;
110110 lmb->reserved.max = CONFIG_LMB_MAX_REGIONS;
111-#else
111+#elif IS_ENABLED(CONFIG_LMB_MEMORY_REGIONS)
112112 lmb->memory.max = CONFIG_LMB_MEMORY_REGIONS;
113113 lmb->reserved.max = CONFIG_LMB_RESERVED_REGIONS;
114114 lmb->memory.region = lmb->memory_regions;