linux-mips
[Top] [All Lists]

[PATCH] MIPS: BCM47XX: move constant array from stack

To: ralf@linux-mips.org
Subject: [PATCH] MIPS: BCM47XX: move constant array from stack
From: Hauke Mehrtens <hauke@hauke-m.de>
Date: Sun, 13 Oct 2013 22:56:50 +0200
Cc: linux-mips@linux-mips.org, Hauke Mehrtens <hauke@hauke-m.de>
List-archive: <http://www.linux-mips.org/archives/linux-mips/>
List-help: <mailto:ecartis@linux-mips.org?Subject=help>
List-id: linux-mips <linux-mips.eddie.linux-mips.org>
List-owner: <mailto:ralf@linux-mips.org>
List-post: <mailto:linux-mips@linux-mips.org>
List-software: Ecartis version 1.0.0
List-subscribe: <mailto:ecartis@linux-mips.org?subject=subscribe%20linux-mips>
List-unsubscribe: <mailto:ecartis@linux-mips.org?subject=unsubscribe%20linux-mips>
Original-recipient: rfc822;linux-mips@linux-mips.org
Sender: linux-mips-bounce@linux-mips.org
Move the possible nvram sizes from the stack into the data segment

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 arch/mips/bcm47xx/nvram.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/mips/bcm47xx/nvram.c b/arch/mips/bcm47xx/nvram.c
index b4c585b..085a3ee 100644
--- a/arch/mips/bcm47xx/nvram.c
+++ b/arch/mips/bcm47xx/nvram.c
@@ -22,11 +22,11 @@
 #include <asm/mach-bcm47xx/bcm47xx.h>
 
 static char nvram_buf[NVRAM_SPACE];
+static const u32 nvram_sizes[] = {0x8000, 0xF000, 0x10000};
 
 static u32 find_nvram_size(u32 end)
 {
        struct nvram_header *header;
-       u32 nvram_sizes[] = {0x8000, 0xF000, 0x10000};
        int i;
 
        for (i = 0; i < ARRAY_SIZE(nvram_sizes); i++) {
-- 
1.7.10.4


<Prev in Thread] Current Thread [Next in Thread>
  • [PATCH] MIPS: BCM47XX: move constant array from stack, Hauke Mehrtens <=