Commit 4a7d834b authored by Rusty Russell's avatar Rusty Russell Committed by Linus Torvalds

[PATCH] namespace pollution in opti92x driver

From:  Arnd Bergmann <arnd@bergmann-dalldorf.de>

  The opti92x driver has global variables named 'rates' and 'bits'
  that pollute the namespace. This makes them static.
parent 9825e033
...@@ -825,8 +825,9 @@ static unsigned int snd_opti93x_get_count(unsigned char format, ...@@ -825,8 +825,9 @@ static unsigned int snd_opti93x_get_count(unsigned char format,
return (format & OPTi93X_STEREO) ? (size >> 1) : size; return (format & OPTi93X_STEREO) ? (size >> 1) : size;
} }
unsigned int rates[] = { 5512, 6615, 8000, 9600, 11025, 16000, 18900, static unsigned int rates[] = { 5512, 6615, 8000, 9600, 11025, 16000,
22050, 27428, 32000, 33075, 37800, 44100, 48000 }; 18900, 22050, 27428, 32000, 33075, 37800,
44100, 48000 };
#define RATES sizeof(rates) / sizeof(rates[0]) #define RATES sizeof(rates) / sizeof(rates[0])
static snd_pcm_hw_constraint_list_t hw_constraints_rates = { static snd_pcm_hw_constraint_list_t hw_constraints_rates = {
...@@ -835,8 +836,9 @@ static snd_pcm_hw_constraint_list_t hw_constraints_rates = { ...@@ -835,8 +836,9 @@ static snd_pcm_hw_constraint_list_t hw_constraints_rates = {
.mask = 0, .mask = 0,
}; };
unsigned char bits[] = { 0x01, 0x0f, 0x00, 0x0e, 0x03, 0x02, 0x05, static unsigned char bits[] = { 0x01, 0x0f, 0x00, 0x0e, 0x03, 0x02,
0x07, 0x04, 0x06, 0x0d, 0x09, 0x0b, 0x0c}; 0x05, 0x07, 0x04, 0x06, 0x0d, 0x09,
0x0b, 0x0c};
static unsigned char snd_opti93x_get_freq(unsigned int rate) static unsigned char snd_opti93x_get_freq(unsigned int rate)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment