Skip to contentSkip to conversation

drm/tegra: hdmi: make read-only const array possible_nvram_sizes static

PATCH Applied Colin Ian King 2 participants 3 messages Aug 22, 2024 – Aug 29, 2024

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/tegra: hdmi: make read-only const array possible_nvram_sizes static

Don't populate the const read-only array possible_nvram_sizes on the stack at run time, instead make it static.

---
 drivers/gpu/drm/tegra/hdmi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/tegra/hdmi.c +1 -1
index 09987e372e3e..6bf2dae82ca0 100644
@@ -434,7 +434,7 @@ tegra_hdmi_get_audio_config(unsigned int audio_freq, unsigned int pix_clock,
 
 static void tegra_hdmi_setup_audio_fs_tables(struct tegra_hdmi *hdmi)
 {
-	const unsigned int freqs[] = {
+	static const unsigned int freqs[] = {
 		32000, 44100, 48000, 88200, 96000, 176400, 192000
 	};
 	unsigned int i;
Signature · 1 line
2.39.2
#1 lore raw
Quoted 1 line · Colin Ian King

Don't populate the const read-only array possible_nvram_sizes on the

I've changed this (and the occurrence in the subject) to reflect the actual array name ("freqs") that's being changed here.

Applied, thanks.

Thierry

#2 lore raw
Quoted 5 lines · Thierry Reding
Quoted 1 line · Colin Ian King

Don't populate the const read-only array possible_nvram_sizes on the

I've changed this (and the occurrence in the subject) to reflect the actual array name ("freqs") that's being changed here.

Thanks, my bad.

Colin

Quoted 4 lines

Applied, thanks.

Thierry