Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d236d361 authored by Takashi Iwai's avatar Takashi Iwai
Browse files

ALSA: parisc: Constify hw_constraints



snd_pcm_hw_constraint_list(), *_ratnums() and *_ratdens() receive the
const pointers.  Constify the corresponding static objects for better
hardening.

Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent 7b3f4776
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -83,14 +83,14 @@ MODULE_DEVICE_TABLE(parisc, snd_harmony_devtable);
#define NAME "harmony"
#define PFX  NAME ": "

static unsigned int snd_harmony_rates[] = {
static const unsigned int snd_harmony_rates[] = {
	5512, 6615, 8000, 9600,
	11025, 16000, 18900, 22050,
	27428, 32000, 33075, 37800,
	44100, 48000
};

static unsigned int rate_bits[14] = {
static const unsigned int rate_bits[14] = {
	HARMONY_SR_5KHZ, HARMONY_SR_6KHZ, HARMONY_SR_8KHZ,
	HARMONY_SR_9KHZ, HARMONY_SR_11KHZ, HARMONY_SR_16KHZ,
	HARMONY_SR_18KHZ, HARMONY_SR_22KHZ, HARMONY_SR_27KHZ,
@@ -98,7 +98,7 @@ static unsigned int rate_bits[14] = {
	HARMONY_SR_44KHZ, HARMONY_SR_48KHZ
};

static struct snd_pcm_hw_constraint_list hw_constraint_rates = {
static const struct snd_pcm_hw_constraint_list hw_constraint_rates = {
	.count = ARRAY_SIZE(snd_harmony_rates),
	.list = snd_harmony_rates,
	.mask = 0,