From 19260818a9747768b09c1c1f10b4125b4d00595e Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Fri, 3 Jan 2020 09:16:38 +0100 Subject: ALSA: ac97: Treat snd_ac97_bus_ops as const This is a preliminary patch to allow const for snd_ac97_bus_ops definitions in each driver's code. The ops reference is read-only, hence it can be declared as const for further optimization. There should be no functional changes by this patch. Link: https://lore.kernel.org/r/20200103081714.9560-23-tiwai@suse.de Signed-off-by: Takashi Iwai --- sound/ac97_bus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sound/ac97_bus.c') diff --git a/sound/ac97_bus.c b/sound/ac97_bus.c index 3732a63a2a81..b4685c53ff11 100644 --- a/sound/ac97_bus.c +++ b/sound/ac97_bus.c @@ -55,7 +55,7 @@ static bool snd_ac97_check_id(struct snd_ac97 *ac97, unsigned int id, int snd_ac97_reset(struct snd_ac97 *ac97, bool try_warm, unsigned int id, unsigned int id_mask) { - struct snd_ac97_bus_ops *ops = ac97->bus->ops; + const struct snd_ac97_bus_ops *ops = ac97->bus->ops; if (try_warm && ops->warm_reset) { ops->warm_reset(ac97); -- cgit v1.2.3