提交 836e4fed 编写于 作者: C Colin Ian King 提交者: Mark Brown

ASoC: ak4642: make arrays fs_list and ps_list static const

Don't populate the arrays fs_list and ps_list on the stack but make
them static const.  Makes the object code smaller:

Before:
   text    data     bss     dec     hex filename
  12084    4888      64   17036    428c sound/soc/codecs/ak4642.o

After:
   text    data     bss     dec     hex filename
  11883    5032      64   16979    4253 sound/soc/codecs/ak4642.o
Signed-off-by: NColin Ian King <colin.king@canonical.com>
Signed-off-by: NMark Brown <broonie@kernel.org>
上级 2ea659a9
......@@ -433,7 +433,7 @@ static int ak4642_dai_set_fmt(struct snd_soc_dai *dai, unsigned int fmt)
static int ak4642_set_mcko(struct snd_soc_codec *codec,
u32 frequency)
{
u32 fs_list[] = {
static const u32 fs_list[] = {
[0] = 8000,
[1] = 12000,
[2] = 16000,
......@@ -447,7 +447,7 @@ static int ak4642_set_mcko(struct snd_soc_codec *codec,
[14] = 29400,
[15] = 44100,
};
u32 ps_list[] = {
static const u32 ps_list[] = {
[0] = 256,
[1] = 128,
[2] = 64,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册