Skip to content

Commit

Permalink
ALSA: sparc: Constify hw_constraints
Browse files Browse the repository at this point in the history
snd_pcm_hw_constraint_list(), *_ratnums() and *_ratdens() receive the
const pointers.  Constify the corresponding static objects for better
hardening.

Signed-off-by: Takashi Iwai <[email protected]>
  • Loading branch information
tiwai committed Jun 9, 2017
1 parent fbc57b2 commit 4e4b7ea
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sound/sparc/cs4231.c
Original file line number Diff line number Diff line change
Expand Up @@ -200,12 +200,12 @@ static unsigned char freq_bits[14] = {
/* 48000 */ 0x0C | CS4231_XTAL1
};

static unsigned int rates[14] = {
static const unsigned int rates[14] = {
5510, 6620, 8000, 9600, 11025, 16000, 18900, 22050,
27042, 32000, 33075, 37800, 44100, 48000
};

static struct snd_pcm_hw_constraint_list hw_constraints_rates = {
static const struct snd_pcm_hw_constraint_list hw_constraints_rates = {
.count = ARRAY_SIZE(rates),
.list = rates,
};
Expand Down

0 comments on commit 4e4b7ea

Please sign in to comment.