summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--apps/plugins/imageviewer/png/tinflate.c2
-rw-r--r--apps/plugins/lua/gmtime.c2
-rw-r--r--firmware/drivers/ata_flash.c2
-rw-r--r--firmware/drivers/lcd-charset-player.c4
-rw-r--r--firmware/test/buflib/test_main2.c4
-rw-r--r--firmware/test/buflib/test_move2.c2
-rw-r--r--flash/uart_boot/uart_boot.c2
-rw-r--r--gdb/sh-stub.c16
-rw-r--r--lib/rbcodec/codecs/libfaad/codebook/hcb.h10
-rw-r--r--lib/rbcodec/codecs/libfaad/huffman.c21
-rw-r--r--lib/rbcodec/codecs/libfaad/syntax.c10
-rw-r--r--lib/rbcodec/codecs/libgme/inflate/mallocer.c6
-rw-r--r--lib/rbcodec/codecs/libspeex/filters.c8
-rw-r--r--lib/rbcodec/codecs/libwavpack/wputils.c2
-rw-r--r--lib/rbcodec/codecs/libwmapro/mdct_tables.c12
-rw-r--r--lib/rbcodec/codecs/mod.c8
-rw-r--r--lib/rbcodec/codecs/sid.c22
-rw-r--r--lib/rbcodec/codecs/wav64.c2
-rw-r--r--lib/skin_parser/skin_debug.c8
-rw-r--r--lib/skin_parser/skin_parser.c2
-rw-r--r--rbutil/mkimxboot/main.c2
21 files changed, 70 insertions, 77 deletions
diff --git a/apps/plugins/imageviewer/png/tinflate.c b/apps/plugins/imageviewer/png/tinflate.c
index 95d8e2b483..f873c37569 100644
--- a/apps/plugins/imageviewer/png/tinflate.c
+++ b/apps/plugins/imageviewer/png/tinflate.c
@@ -96,7 +96,7 @@ typedef struct {
96} TINF_DATA; 96} TINF_DATA;
97 97
98/* static tables */ 98/* static tables */
99TINF_TABLES tbl = { 99static TINF_TABLES tbl = {
100 .sltree = { 100 .sltree = {
101 .table = {0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0018, 101 .table = {0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0018,
102 0x0098, 0x0070, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000}, 102 0x0098, 0x0070, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000},
diff --git a/apps/plugins/lua/gmtime.c b/apps/plugins/lua/gmtime.c
index deb24e08c9..19ff3bc088 100644
--- a/apps/plugins/lua/gmtime.c
+++ b/apps/plugins/lua/gmtime.c
@@ -4,7 +4,7 @@
4#define SPD 24*60*60 4#define SPD 24*60*60
5 5
6/* days per month -- nonleap! */ 6/* days per month -- nonleap! */
7const short __spm[13] = 7static const short __spm[13] =
8 { 0, 8 { 0,
9 (31), 9 (31),
10 (31+28), 10 (31+28),
diff --git a/firmware/drivers/ata_flash.c b/firmware/drivers/ata_flash.c
index 96ea1cfa68..fbdd7f04ee 100644
--- a/firmware/drivers/ata_flash.c
+++ b/firmware/drivers/ata_flash.c
@@ -42,7 +42,7 @@
42 42
43#define SECTOR_SIZE (512) 43#define SECTOR_SIZE (512)
44 44
45long last_disk_activity = -1; 45static long last_disk_activity = -1;
46 46
47#if CONFIG_FLASH == FLASH_IFP7XX 47#if CONFIG_FLASH == FLASH_IFP7XX
48static unsigned char flash_ce[4] = {0x20, 0x02, 0x10, 0x08}; 48static unsigned char flash_ce[4] = {0x20, 0x02, 0x10, 0x08};
diff --git a/firmware/drivers/lcd-charset-player.c b/firmware/drivers/lcd-charset-player.c
index 68404c6230..b1f6f6dae2 100644
--- a/firmware/drivers/lcd-charset-player.c
+++ b/firmware/drivers/lcd-charset-player.c
@@ -115,7 +115,7 @@ enum {
115#endif 115#endif
116}; 116};
117 117
118const struct xchar_info xchar_info_newlcd[] = { 118static const struct xchar_info xchar_info_newlcd[] = {
119 /* Standard ascii */ 119 /* Standard ascii */
120 { 0x20, 0, 0, 0x20 }, /* */ 120 { 0x20, 0, 0, 0x20 }, /* */
121 { 0x21, 0, 0, 0x21 }, /* ! */ 121 { 0x21, 0, 0, 0x21 }, /* ! */
@@ -641,7 +641,7 @@ const struct xchar_info xchar_info_newlcd[] = {
641 { 0xfffd, 0, 0, 0x91 }, 641 { 0xfffd, 0, 0, 0x91 },
642}; 642};
643 643
644const struct xchar_info xchar_info_oldlcd[] = { 644static const struct xchar_info xchar_info_oldlcd[] = {
645 /* Standard ascii */ 645 /* Standard ascii */
646 { 0x20, 0, 0, 0x24 }, /* */ 646 { 0x20, 0, 0, 0x24 }, /* */
647 { 0x21, 0, 0, 0x25 }, /* ! */ 647 { 0x21, 0, 0, 0x25 }, /* ! */
diff --git a/firmware/test/buflib/test_main2.c b/firmware/test/buflib/test_main2.c
index 9fed78612e..da6b1366e7 100644
--- a/firmware/test/buflib/test_main2.c
+++ b/firmware/test/buflib/test_main2.c
@@ -52,12 +52,12 @@ static int shrink_callback(int handle, unsigned hints, void* start, size_t size)
52 return BUFLIB_CB_CANNOT_SHRINK; 52 return BUFLIB_CB_CANNOT_SHRINK;
53} 53}
54 54
55struct buflib_callbacks ops = { 55static struct buflib_callbacks ops = {
56 .move_callback = move_callback, 56 .move_callback = move_callback,
57 .shrink_callback = shrink_callback, 57 .shrink_callback = shrink_callback,
58}; 58};
59 59
60struct buflib_callbacks ops2 = { 60static struct buflib_callbacks ops2 = {
61 .move_callback = NULL, 61 .move_callback = NULL,
62 .shrink_callback = shrink_callback, 62 .shrink_callback = shrink_callback,
63}; 63};
diff --git a/firmware/test/buflib/test_move2.c b/firmware/test/buflib/test_move2.c
index 1076c27a50..2f72850b2b 100644
--- a/firmware/test/buflib/test_move2.c
+++ b/firmware/test/buflib/test_move2.c
@@ -80,7 +80,7 @@ struct buflib_callbacks ops = {
80 .shrink_callback = NULL, 80 .shrink_callback = NULL,
81}; 81};
82 82
83struct buflib_callbacks ops_no_move = { 83static struct buflib_callbacks ops_no_move = {
84 .move_callback = NULL, 84 .move_callback = NULL,
85 .shrink_callback = NULL, 85 .shrink_callback = NULL,
86}; 86};
diff --git a/flash/uart_boot/uart_boot.c b/flash/uart_boot/uart_boot.c
index 40c3682091..06750fdbe2 100644
--- a/flash/uart_boot/uart_boot.c
+++ b/flash/uart_boot/uart_boot.c
@@ -10,7 +10,7 @@
10#include "flash.h" // flash high level functions 10#include "flash.h" // flash high level functions
11 11
12// command line configuration: what shall we do? 12// command line configuration: what shall we do?
13struct 13static struct
14{ 14{
15 char* szPort; // COM port to use 15 char* szPort; // COM port to use
16 bool bRecorder; // it's a recorder 16 bool bRecorder; // it's a recorder
diff --git a/gdb/sh-stub.c b/gdb/sh-stub.c
index 1b93efa352..9daca39f72 100644
--- a/gdb/sh-stub.c
+++ b/gdb/sh-stub.c
@@ -381,16 +381,16 @@ void start (void);
381#define IO_VEC 33 381#define IO_VEC 33
382#define USER_VEC 127 382#define USER_VEC 127
383 383
384char in_nmi; /* Set when handling an NMI, so we don't reenter */ 384static char in_nmi; /* Set when handling an NMI, so we don't reenter */
385int dofault; /* Non zero, bus errors will raise exception */ 385static int dofault; /* Non zero, bus errors will raise exception */
386 386
387int *stub_sp; 387static int *stub_sp;
388 388
389/* debug > 0 prints ill-formed commands in valid packets & checksum errors */ 389/* debug > 0 prints ill-formed commands in valid packets & checksum errors */
390int remote_debug; 390static int remote_debug;
391 391
392/* jump buffer used for setjmp/longjmp */ 392/* jump buffer used for setjmp/longjmp */
393jmp_buf remcomEnv; 393static jmp_buf remcomEnv;
394 394
395enum regnames 395enum regnames
396{ 396{
@@ -407,9 +407,9 @@ typedef struct
407} 407}
408stepData; 408stepData;
409 409
410int registers[NUMREGBYTES / 4]; 410static int registers[NUMREGBYTES / 4];
411stepData instrBuffer; 411static stepData instrBuffer;
412char stepped; 412static char stepped;
413static const char hexchars[] = "0123456789abcdef"; 413static const char hexchars[] = "0123456789abcdef";
414static char remcomInBuffer[BUFMAX]; 414static char remcomInBuffer[BUFMAX];
415static char remcomOutBuffer[BUFMAX]; 415static char remcomOutBuffer[BUFMAX];
diff --git a/lib/rbcodec/codecs/libfaad/codebook/hcb.h b/lib/rbcodec/codecs/libfaad/codebook/hcb.h
index eaefdbf437..53e234ade9 100644
--- a/lib/rbcodec/codecs/libfaad/codebook/hcb.h
+++ b/lib/rbcodec/codecs/libfaad/codebook/hcb.h
@@ -112,16 +112,6 @@ typedef struct
112 int8_t data[2]; 112 int8_t data[2];
113} hcb_bin_pair; 113} hcb_bin_pair;
114 114
115hcb *hcb_table[];
116hcb_2_quad *hcb_2_quad_table[];
117hcb_2_pair *hcb_2_pair_table[];
118hcb_bin_pair *hcb_bin_table[];
119uint8_t hcbN[];
120uint8_t unsigned_cb[];
121int hcb_2_quad_table_size[];
122int hcb_2_pair_table_size[];
123int hcb_bin_table_size[];
124
125#include "codebook/hcb_1.h" 115#include "codebook/hcb_1.h"
126#include "codebook/hcb_2.h" 116#include "codebook/hcb_2.h"
127#include "codebook/hcb_3.h" 117#include "codebook/hcb_3.h"
diff --git a/lib/rbcodec/codecs/libfaad/huffman.c b/lib/rbcodec/codecs/libfaad/huffman.c
index bea0dd7bf2..93e3a2dfc3 100644
--- a/lib/rbcodec/codecs/libfaad/huffman.c
+++ b/lib/rbcodec/codecs/libfaad/huffman.c
@@ -76,33 +76,33 @@ int8_t huffman_scale_factor(bitfile *ld)
76} 76}
77 77
78 78
79hcb *hcb_table[] ICONST_ATTR = { 79static hcb *hcb_table[] ICONST_ATTR = {
80 0, hcb1_1, hcb2_1, 0, hcb4_1, 0, hcb6_1, 0, hcb8_1, 0, hcb10_1, hcb11_1 80 0, hcb1_1, hcb2_1, 0, hcb4_1, 0, hcb6_1, 0, hcb8_1, 0, hcb10_1, hcb11_1
81}; 81};
82 82
83hcb_2_quad *hcb_2_quad_table[] ICONST_ATTR = { 83static hcb_2_quad *hcb_2_quad_table[] ICONST_ATTR = {
84 0, hcb1_2, hcb2_2, 0, hcb4_2, 0, 0, 0, 0, 0, 0, 0 84 0, hcb1_2, hcb2_2, 0, hcb4_2, 0, 0, 0, 0, 0, 0, 0
85}; 85};
86 86
87hcb_2_pair *hcb_2_pair_table[] ICONST_ATTR = { 87static hcb_2_pair *hcb_2_pair_table[] ICONST_ATTR = {
88 0, 0, 0, 0, 0, 0, hcb6_2, 0, hcb8_2, 0, hcb10_2, hcb11_2 88 0, 0, 0, 0, 0, 0, hcb6_2, 0, hcb8_2, 0, hcb10_2, hcb11_2
89}; 89};
90 90
91hcb_bin_pair *hcb_bin_table[] ICONST_ATTR = { 91static hcb_bin_pair *hcb_bin_table[] ICONST_ATTR = {
92 0, 0, 0, 0, 0, hcb5, 0, hcb7, 0, hcb9, 0, 0 92 0, 0, 0, 0, 0, hcb5, 0, hcb7, 0, hcb9, 0, 0
93}; 93};
94 94
95uint8_t hcbN[] ICONST_ATTR = { 0, 5, 5, 0, 5, 0, 5, 0, 5, 0, 6, 5 }; 95static uint8_t hcbN[] ICONST_ATTR = { 0, 5, 5, 0, 5, 0, 5, 0, 5, 0, 6, 5 };
96 96
97/* defines whether a huffman codebook is unsigned or not */ 97/* defines whether a huffman codebook is unsigned or not */
98/* Table 4.6.2 */ 98/* Table 4.6.2 */
99uint8_t unsigned_cb[] ICONST_ATTR = { 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 99static uint8_t unsigned_cb[] ICONST_ATTR = { 0, 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0,
100 /* codebook 16 to 31 */ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 100 /* codebook 16 to 31 */ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
101}; 101};
102 102
103int hcb_2_quad_table_size[] ICONST_ATTR = { 0, 114, 86, 0, 185, 0, 0, 0, 0, 0, 0, 0 }; 103static int hcb_2_quad_table_size[] ICONST_ATTR = { 0, 114, 86, 0, 185, 0, 0, 0, 0, 0, 0, 0 };
104int hcb_2_pair_table_size[] ICONST_ATTR = { 0, 0, 0, 0, 0, 0, 126, 0, 83, 0, 210, 373 }; 104static int hcb_2_pair_table_size[] ICONST_ATTR = { 0, 0, 0, 0, 0, 0, 126, 0, 83, 0, 210, 373 };
105int hcb_bin_table_size[] ICONST_ATTR = { 0, 0, 0, 161, 0, 161, 0, 127, 0, 337, 0, 0 }; 105static int hcb_bin_table_size[] ICONST_ATTR = { 0, 0, 0, 161, 0, 161, 0, 127, 0, 337, 0, 0 };
106 106
107#define FAAD_GET_SIGN(idx) \ 107#define FAAD_GET_SIGN(idx) \
108 if (sp[idx]) \ 108 if (sp[idx]) \
@@ -113,6 +113,9 @@ static INLINE void huffman_sign_bits_pair(bitfile *ld, int16_t *sp)
113{ 113{
114 FAAD_GET_SIGN(0) 114 FAAD_GET_SIGN(0)
115 FAAD_GET_SIGN(1) 115 FAAD_GET_SIGN(1)
116
117 /* silence compiler warning about unused globals */
118 (void)unsigned_cb;
116} 119}
117 120
118static INLINE void huffman_sign_bits_quad(bitfile *ld, int16_t *sp) 121static INLINE void huffman_sign_bits_quad(bitfile *ld, int16_t *sp)
diff --git a/lib/rbcodec/codecs/libfaad/syntax.c b/lib/rbcodec/codecs/libfaad/syntax.c
index d3d7f9e3d4..65e1bf7744 100644
--- a/lib/rbcodec/codecs/libfaad/syntax.c
+++ b/lib/rbcodec/codecs/libfaad/syntax.c
@@ -558,8 +558,8 @@ void raw_data_block(NeAACDecHandle hDecoder, NeAACDecFrameInfo *hInfo,
558 558
559/* Table 4.4.4 and */ 559/* Table 4.4.4 and */
560/* Table 4.4.9 */ 560/* Table 4.4.9 */
561int16_t spec_data[FRAME_LEN] MEM_ALIGN_ATTR = {0}; 561static int16_t spec_data[FRAME_LEN] MEM_ALIGN_ATTR = {0};
562element sce; 562static element sce;
563static uint8_t single_lfe_channel_element(NeAACDecHandle hDecoder, bitfile *ld, 563static uint8_t single_lfe_channel_element(NeAACDecHandle hDecoder, bitfile *ld,
564 uint8_t channel, uint8_t *tag) 564 uint8_t channel, uint8_t *tag)
565{ 565{
@@ -604,9 +604,9 @@ static uint8_t single_lfe_channel_element(NeAACDecHandle hDecoder, bitfile *ld,
604 604
605/* Table 4.4.5 */ 605/* Table 4.4.5 */
606 606
607int16_t spec_data1[FRAME_LEN] IBSS_ATTR MEM_ALIGN_ATTR; 607static int16_t spec_data1[FRAME_LEN] IBSS_ATTR MEM_ALIGN_ATTR;
608int16_t spec_data2[FRAME_LEN] IBSS_ATTR MEM_ALIGN_ATTR; 608static int16_t spec_data2[FRAME_LEN] IBSS_ATTR MEM_ALIGN_ATTR;
609element cpe; 609static element cpe;
610static uint8_t channel_pair_element(NeAACDecHandle hDecoder, bitfile *ld, 610static uint8_t channel_pair_element(NeAACDecHandle hDecoder, bitfile *ld,
611 uint8_t channels, uint8_t *tag) 611 uint8_t channels, uint8_t *tag)
612{ 612{
diff --git a/lib/rbcodec/codecs/libgme/inflate/mallocer.c b/lib/rbcodec/codecs/libgme/inflate/mallocer.c
index 41abedd09f..1e9c235975 100644
--- a/lib/rbcodec/codecs/libgme/inflate/mallocer.c
+++ b/lib/rbcodec/codecs/libgme/inflate/mallocer.c
@@ -9,9 +9,9 @@
9#include "mallocer.h" 9#include "mallocer.h"
10#include "codeclib.h" 10#include "codeclib.h"
11 11
12unsigned char* mallocbuffer[MEMPOOL_MAX]; 12static unsigned char* mallocbuffer[MEMPOOL_MAX];
13long memory_ptr[MEMPOOL_MAX]; 13static long memory_ptr[MEMPOOL_MAX];
14size_t buffersize[MEMPOOL_MAX]; 14static size_t buffersize[MEMPOOL_MAX];
15 15
16int wpw_init_mempool(unsigned char mempool) 16int wpw_init_mempool(unsigned char mempool)
17{ 17{
diff --git a/lib/rbcodec/codecs/libspeex/filters.c b/lib/rbcodec/codecs/libspeex/filters.c
index 7c4c90a636..b6fb79c9e0 100644
--- a/lib/rbcodec/codecs/libspeex/filters.c
+++ b/lib/rbcodec/codecs/libspeex/filters.c
@@ -590,21 +590,21 @@ void qmf_synth(const spx_word16_t *x1, const spx_word16_t *x2, const spx_word16_
590 590
591#ifdef FIXED_POINT 591#ifdef FIXED_POINT
592#if 0 592#if 0
593const spx_word16_t shift_filt[3][7] = {{-33, 1043, -4551, 19959, 19959, -4551, 1043}, 593static const spx_word16_t shift_filt[3][7] = {{-33, 1043, -4551, 19959, 19959, -4551, 1043},
594 {-98, 1133, -4425, 29179, 8895, -2328, 444}, 594 {-98, 1133, -4425, 29179, 8895, -2328, 444},
595 {444, -2328, 8895, 29179, -4425, 1133, -98}}; 595 {444, -2328, 8895, 29179, -4425, 1133, -98}};
596#else 596#else
597const spx_word16_t shift_filt[3][7] = {{-390, 1540, -4993, 20123, 20123, -4993, 1540}, 597static const spx_word16_t shift_filt[3][7] = {{-390, 1540, -4993, 20123, 20123, -4993, 1540},
598 {-1064, 2817, -6694, 31589, 6837, -990, -209}, 598 {-1064, 2817, -6694, 31589, 6837, -990, -209},
599 {-209, -990, 6837, 31589, -6694, 2817, -1064}}; 599 {-209, -990, 6837, 31589, -6694, 2817, -1064}};
600#endif 600#endif
601#else 601#else
602#if 0 602#if 0
603const float shift_filt[3][7] = {{-9.9369e-04, 3.1831e-02, -1.3889e-01, 6.0910e-01, 6.0910e-01, -1.3889e-01, 3.1831e-02}, 603static const float shift_filt[3][7] = {{-9.9369e-04, 3.1831e-02, -1.3889e-01, 6.0910e-01, 6.0910e-01, -1.3889e-01, 3.1831e-02},
604 {-0.0029937, 0.0345613, -0.1350474, 0.8904793, 0.2714479, -0.0710304, 0.0135403}, 604 {-0.0029937, 0.0345613, -0.1350474, 0.8904793, 0.2714479, -0.0710304, 0.0135403},
605 {0.0135403, -0.0710304, 0.2714479, 0.8904793, -0.1350474, 0.0345613, -0.0029937}}; 605 {0.0135403, -0.0710304, 0.2714479, 0.8904793, -0.1350474, 0.0345613, -0.0029937}};
606#else 606#else
607const float shift_filt[3][7] = {{-0.011915f, 0.046995f, -0.152373f, 0.614108f, 0.614108f, -0.152373f, 0.046995f}, 607static const float shift_filt[3][7] = {{-0.011915f, 0.046995f, -0.152373f, 0.614108f, 0.614108f, -0.152373f, 0.046995f},
608 {-0.0324855f, 0.0859768f, -0.2042986f, 0.9640297f, 0.2086420f, -0.0302054f, -0.0063646f}, 608 {-0.0324855f, 0.0859768f, -0.2042986f, 0.9640297f, 0.2086420f, -0.0302054f, -0.0063646f},
609 {-0.0063646f, -0.0302054f, 0.2086420f, 0.9640297f, -0.2042986f, 0.0859768f, -0.0324855f}}; 609 {-0.0063646f, -0.0302054f, 0.2086420f, 0.9640297f, -0.2042986f, 0.0859768f, -0.0324855f}};
610#endif 610#endif
diff --git a/lib/rbcodec/codecs/libwavpack/wputils.c b/lib/rbcodec/codecs/libwavpack/wputils.c
index b0ccd3ba83..3487f980b2 100644
--- a/lib/rbcodec/codecs/libwavpack/wputils.c
+++ b/lib/rbcodec/codecs/libwavpack/wputils.c
@@ -23,7 +23,7 @@ static void strcpy_loc (char *dst, char *src) { while ((*dst++ = *src++) != 0);
23 23
24///////////////////////////// local table storage //////////////////////////// 24///////////////////////////// local table storage ////////////////////////////
25 25
26const uint32_t sample_rates [] = { 6000, 8000, 9600, 11025, 12000, 16000, 22050, 26static const uint32_t sample_rates [] = { 6000, 8000, 9600, 11025, 12000, 16000, 22050,
27 24000, 32000, 44100, 48000, 64000, 88200, 96000, 192000 }; 27 24000, 32000, 44100, 48000, 64000, 88200, 96000, 192000 };
28 28
29///////////////////////////// executable code //////////////////////////////// 29///////////////////////////// executable code ////////////////////////////////
diff --git a/lib/rbcodec/codecs/libwmapro/mdct_tables.c b/lib/rbcodec/codecs/libwmapro/mdct_tables.c
index bec3c37ee7..deea04f746 100644
--- a/lib/rbcodec/codecs/libwmapro/mdct_tables.c
+++ b/lib/rbcodec/codecs/libwmapro/mdct_tables.c
@@ -4,7 +4,7 @@
4/* Tables for fixed-point trig tables for windowing and mdct */ 4/* Tables for fixed-point trig tables for windowing and mdct */
5 5
6/* Windowing trig tables in s.31 format */ 6/* Windowing trig tables in s.31 format */
7const int32_t sine_4096[] = { 7static const int32_t sine_4096[] = {
8 0xFFF9B782, 0xFFED2685, 0xFFE09587, 0xFFD4048A, 0xFFC7738D, 0xFFBAE291, 8 0xFFF9B782, 0xFFED2685, 0xFFE09587, 0xFFD4048A, 0xFFC7738D, 0xFFBAE291,
9 0xFFAE5196, 0xFFA1C09B, 0xFF952FA1, 0xFF889EA8, 0xFF7C0DB1, 0xFF6F7CBB, 9 0xFFAE5196, 0xFFA1C09B, 0xFF952FA1, 0xFF889EA8, 0xFF7C0DB1, 0xFF6F7CBB,
10 0xFF62EBC5, 0xFF565AD3, 0xFF49C9E1, 0xFF3D38F0, 0xFF30A803, 0xFF241716, 10 0xFF62EBC5, 0xFF565AD3, 0xFF49C9E1, 0xFF3D38F0, 0xFF30A803, 0xFF241716,
@@ -690,7 +690,7 @@ const int32_t sine_4096[] = {
690 0x8000078F, 0x800003DC, 0x80000164, 0x80000028 690 0x8000078F, 0x800003DC, 0x80000164, 0x80000028
691}; 691};
692 692
693const int32_t sine_2048[] ICONST_ATTR_WMAPRO_WIN_VS_TMP = { 693static const int32_t sine_2048[] ICONST_ATTR_WMAPRO_WIN_VS_TMP = {
694 0xFFF36F03, 0xFFDA4D09, 0xFFC12B0F, 0xFFA80918, 0xFF8EE725, 0xFF75C536, 694 0xFFF36F03, 0xFFDA4D09, 0xFFC12B0F, 0xFFA80918, 0xFF8EE725, 0xFF75C536,
695 0xFF5CA34B, 0xFF438168, 0xFF2A5F8C, 0xFF113DB7, 0xFEF81BEE, 0xFEDEFA2D, 695 0xFF5CA34B, 0xFF438168, 0xFF2A5F8C, 0xFF113DB7, 0xFEF81BEE, 0xFEDEFA2D,
696 0xFEC5D876, 0xFEACB6CE, 0xFE939531, 0xFE7A73A2, 0xFE615224, 0xFE4830B4, 696 0xFEC5D876, 0xFEACB6CE, 0xFE939531, 0xFE7A73A2, 0xFE615224, 0xFE4830B4,
@@ -1035,7 +1035,7 @@ const int32_t sine_2048[] ICONST_ATTR_WMAPRO_WIN_VS_TMP = {
1035 0x8000058E, 0x8000009F 1035 0x8000058E, 0x8000009F
1036}; 1036};
1037 1037
1038const int32_t sine_1024[] = { 1038static const int32_t sine_1024[] = {
1039 0xFFE6DE06, 0xFFB49A13, 0xFF82562D, 0xFF501259, 0xFF1DCEA1, 0xFEEB8B0C, 1039 0xFFE6DE06, 0xFFB49A13, 0xFF82562D, 0xFF501259, 0xFF1DCEA1, 0xFEEB8B0C,
1040 0xFEB947A0, 0xFE870468, 0xFE54C16A, 0xFE227EAD, 0xFDF03C3D, 0xFDBDFA1A, 1040 0xFEB947A0, 0xFE870468, 0xFE54C16A, 0xFE227EAD, 0xFDF03C3D, 0xFDBDFA1A,
1041 0xFD8BB850, 0xFD5976EC, 0xFD2735EC, 0xFCF4F55C, 0xFCC2B548, 0xFC9075B1, 1041 0xFD8BB850, 0xFD5976EC, 0xFD2735EC, 0xFCF4F55C, 0xFCC2B548, 0xFC9075B1,
@@ -1209,7 +1209,7 @@ const int32_t sine_1024[] = {
1209 0x800078E8, 0x80003DB0, 0x80001636, 0x80000279 1209 0x800078E8, 0x80003DB0, 0x80001636, 0x80000279
1210}; 1210};
1211 1211
1212const int32_t sine_512[] = { 1212static const int32_t sine_512[] = {
1213 0xFFCDBC0C, 0xFF693440, 0xFF04ACD1, 0xFEA025FE, 0xFE3BA003, 0xFDD71B21, 1213 0xFFCDBC0C, 0xFF693440, 0xFF04ACD1, 0xFEA025FE, 0xFE3BA003, 0xFDD71B21,
1214 0xFD72978F, 0xFD0E1595, 0xFCA9956C, 0xFC45174E, 0xFBE09B85, 0xFB7C223F, 1214 0xFD72978F, 0xFD0E1595, 0xFCA9956C, 0xFC45174E, 0xFBE09B85, 0xFB7C223F,
1215 0xFB17ABC2, 0xFAB33854, 0xFA4EC823, 0xF9EA5B74, 0xF985F28F, 0xF9218DA0, 1215 0xFB17ABC2, 0xFAB33854, 0xFA4EC823, 0xF9EA5B74, 0xF985F28F, 0xF9218DA0,
@@ -1298,7 +1298,7 @@ const int32_t sine_512[] = {
1298 0x800058D4, 0x800009DF 1298 0x800058D4, 0x800009DF
1299}; 1299};
1300 1300
1301const int32_t sine_256[] ICONST_ATTR_WMAPRO_WIN_VS_TMP = { 1301static const int32_t sine_256[] ICONST_ATTR_WMAPRO_WIN_VS_TMP = {
1302 0xFF9B781E, 0xFED26950, 0xFE095D6B, 0xFD40565E, 0xFC775617, 0xFBAE5E8D, 1302 0xFF9B781E, 0xFED26950, 0xFE095D6B, 0xFD40565E, 0xFC775617, 0xFBAE5E8D,
1303 0xFAE571A2, 0xFA1C9157, 0xF953BF94, 0xF88AFE40, 0xF7C24F61, 0xF6F9B4C9, 1303 0xFAE571A2, 0xFA1C9157, 0xF953BF94, 0xF88AFE40, 0xF7C24F61, 0xF6F9B4C9,
1304 0xF6313075, 0xF568C463, 0xF4A07264, 0xF3D83C74, 0xF3102493, 0xF2482C8D, 1304 0xF6313075, 0xF568C463, 0xF4A07264, 0xF3D83C74, 0xF3102493, 0xF2482C8D,
@@ -1344,7 +1344,7 @@ const int32_t sine_256[] ICONST_ATTR_WMAPRO_WIN_VS_TMP = {
1344 0x80078E60, 0x8003DAF2, 0x8001634E, 0x8000277B 1344 0x80078E60, 0x8003DAF2, 0x8001634E, 0x8000277B
1345}; 1345};
1346 1346
1347const int32_t sine_128[] ICONST_ATTR = { 1347static const int32_t sine_128[] ICONST_ATTR = {
1348 0xFF36F079, 0xFDA4D929, 0xFC12D91C, 0xFA80FFCF, 0xF8EF5CBC, 0xF75DFF6C, 1348 0xFF36F079, 0xFDA4D929, 0xFC12D91C, 0xFA80FFCF, 0xF8EF5CBC, 0xF75DFF6C,
1349 0xF5CCF73F, 0xF43C53CB, 0xF2AC2474, 0xF11C7895, 0xEF8D5FC8, 0xEDFEE931, 1349 0xF5CCF73F, 0xF43C53CB, 0xF2AC2474, 0xF11C7895, 0xEF8D5FC8, 0xEDFEE931,
1350 0xEC71244A, 0xEAE4208A, 0xE957ED00, 0xE7CC9912, 0xE642341D, 0xE4B8CD16, 1350 0xEC71244A, 0xEAE4208A, 0xE957ED00, 0xE7CC9912, 0xE642341D, 0xE4B8CD16,
diff --git a/lib/rbcodec/codecs/mod.c b/lib/rbcodec/codecs/mod.c
index 4dd0cde6e5..3d5f729235 100644
--- a/lib/rbcodec/codecs/mod.c
+++ b/lib/rbcodec/codecs/mod.c
@@ -234,9 +234,9 @@ struct s_mixer {
234 struct s_channel channel[32]; 234 struct s_channel channel[32];
235}; 235};
236 236
237struct s_song modsong IDATA_ATTR; /* The Song */ 237static struct s_song modsong IDATA_ATTR; /* The Song */
238struct s_modplayer modplayer IDATA_ATTR; /* The Module Player */ 238static struct s_modplayer modplayer IDATA_ATTR; /* The Module Player */
239struct s_mixer mixer IDATA_ATTR; 239static struct s_mixer mixer IDATA_ATTR;
240 240
241/* The Amiga Period Table (+1 because we use index 0 for period 0 = no new note) */ 241/* The Amiga Period Table (+1 because we use index 0 for period 0 = no new note) */
242static unsigned short s_periodtable[37*8+1] IDATA_ATTR = 242static unsigned short s_periodtable[37*8+1] IDATA_ATTR =
@@ -290,7 +290,7 @@ static signed short s_sintable[0x40] IDATA_ATTR =
290 -255, -254, -250, -244, -235, -224, -211, -197, 290 -255, -254, -250, -244, -235, -224, -211, -197,
291 -180, -161, -141, -119, -97, -73, -49, -24}; 291 -180, -161, -141, -119, -97, -73, -49, -24};
292 292
293const unsigned short mixingrate = 44100; 293static const unsigned short mixingrate = 44100;
294 294
295static void mixer_playsample(int channel, int instrument) ICODE_ATTR; 295static void mixer_playsample(int channel, int instrument) ICODE_ATTR;
296void mixer_playsample(int channel, int instrument) 296void mixer_playsample(int channel, int instrument)
diff --git a/lib/rbcodec/codecs/sid.c b/lib/rbcodec/codecs/sid.c
index 6e39d3f759..3c370961c7 100644
--- a/lib/rbcodec/codecs/sid.c
+++ b/lib/rbcodec/codecs/sid.c
@@ -155,27 +155,27 @@ struct sidflt {
155}; 155};
156 156
157/* ------------------------ pseudo-constants (depending on mixing freq) */ 157/* ------------------------ pseudo-constants (depending on mixing freq) */
158int mixing_frequency IDATA_ATTR; 158static int mixing_frequency IDATA_ATTR;
159unsigned long freqmul IDATA_ATTR; 159static unsigned long freqmul IDATA_ATTR;
160int filtmul IDATA_ATTR; 160static int filtmul IDATA_ATTR;
161#ifndef ROCKBOX 161#ifndef ROCKBOX
162unsigned long attacks [16] IDATA_ATTR; 162unsigned long attacks [16] IDATA_ATTR;
163unsigned long releases[16] IDATA_ATTR; 163unsigned long releases[16] IDATA_ATTR;
164#endif 164#endif
165 165
166/* ------------------------------------------------------------ globals */ 166/* ------------------------------------------------------------ globals */
167struct s6581 sid IDATA_ATTR; 167static struct s6581 sid IDATA_ATTR;
168struct sidosc osc[3] IDATA_ATTR; 168static struct sidosc osc[3] IDATA_ATTR;
169struct sidflt filter IDATA_ATTR; 169static struct sidflt filter IDATA_ATTR;
170 170
171/* ------------------------------------------------------ C64 Emu Stuff */ 171/* ------------------------------------------------------ C64 Emu Stuff */
172unsigned char bval IDATA_ATTR; 172static unsigned char bval IDATA_ATTR;
173unsigned short wval IDATA_ATTR; 173static unsigned short wval IDATA_ATTR;
174/* -------------------------------------------------- Register & memory */ 174/* -------------------------------------------------- Register & memory */
175unsigned char a,x,y,s,p IDATA_ATTR; 175static unsigned char a,x,y,s,p IDATA_ATTR;
176unsigned short pc IDATA_ATTR; 176static unsigned short pc IDATA_ATTR;
177 177
178unsigned char memory[65536]; 178static unsigned char memory[65536];
179 179
180/* ----------------------------------------- Variables for sample stuff */ 180/* ----------------------------------------- Variables for sample stuff */
181static int sample_active IDATA_ATTR; 181static int sample_active IDATA_ATTR;
diff --git a/lib/rbcodec/codecs/wav64.c b/lib/rbcodec/codecs/wav64.c
index 96e605faad..66bb3e3a11 100644
--- a/lib/rbcodec/codecs/wav64.c
+++ b/lib/rbcodec/codecs/wav64.c
@@ -60,7 +60,7 @@ enum
60 WAVE_FORMAT_EXTENSIBLE = 0xFFFE 60 WAVE_FORMAT_EXTENSIBLE = 0xFFFE
61}; 61};
62 62
63const struct pcm_entry wave_codecs[] = { 63static const struct pcm_entry wave_codecs[] = {
64 { WAVE_FORMAT_UNKNOWN, 0 }, 64 { WAVE_FORMAT_UNKNOWN, 0 },
65 { WAVE_FORMAT_PCM, get_linear_pcm_codec }, 65 { WAVE_FORMAT_PCM, get_linear_pcm_codec },
66 { WAVE_FORMAT_ADPCM, get_ms_adpcm_codec }, 66 { WAVE_FORMAT_ADPCM, get_ms_adpcm_codec },
diff --git a/lib/skin_parser/skin_debug.c b/lib/skin_parser/skin_debug.c
index a2042744b9..43cd746253 100644
--- a/lib/skin_parser/skin_debug.c
+++ b/lib/skin_parser/skin_debug.c
@@ -34,10 +34,10 @@ extern char* skin_start;
34extern char* skin_buffer; 34extern char* skin_buffer;
35 35
36/* Global error variables */ 36/* Global error variables */
37int error_line; 37static int error_line;
38int error_col; 38static int error_col;
39const char *error_line_start; 39static const char *error_line_start;
40char* error_message; 40static char* error_message;
41 41
42 42
43static inline struct skin_element* 43static inline struct skin_element*
diff --git a/lib/skin_parser/skin_parser.c b/lib/skin_parser/skin_parser.c
index e47054b06a..1d784f918a 100644
--- a/lib/skin_parser/skin_parser.c
+++ b/lib/skin_parser/skin_parser.c
@@ -35,7 +35,7 @@
35/* Global variables for the parser */ 35/* Global variables for the parser */
36int skin_line = 0; 36int skin_line = 0;
37char* skin_start = 0; 37char* skin_start = 0;
38int viewport_line = 0; 38static int viewport_line = 0;
39 39
40#ifdef ROCKBOX 40#ifdef ROCKBOX
41static skin_callback callback = NULL; 41static skin_callback callback = NULL;
diff --git a/rbutil/mkimxboot/main.c b/rbutil/mkimxboot/main.c
index 23a15cf4ea..a2ec462db0 100644
--- a/rbutil/mkimxboot/main.c
+++ b/rbutil/mkimxboot/main.c
@@ -31,7 +31,7 @@ struct imx_variant_t
31 enum imx_firmware_variant_t variant; 31 enum imx_firmware_variant_t variant;
32}; 32};
33 33
34struct imx_variant_t imx_variants[] = 34static struct imx_variant_t imx_variants[] =
35{ 35{
36 { "default", VARIANT_DEFAULT }, 36 { "default", VARIANT_DEFAULT },
37 { "zenxfi2-recovery", VARIANT_ZENXFI2_RECOVERY }, 37 { "zenxfi2-recovery", VARIANT_ZENXFI2_RECOVERY },