longname in sound/core/jack.c
Mark,
I'm not sure whether I've already asked it, but I find it ugly to refer to card->longname for the input device name in sound/core/jack.c.
Can it be changed to card->shortname, at least?
The long name is often really long like "HDA Intel at 0xf8400000 irq 21", thus the resultant name will be
"HDA Intel at 0xf8400000 irq 21 Line Out at Ext Left"
as the jack name.
Takashi
---
sound/core/jack.c +1 -1
@@ -55,7 +55,7 @@ static int snd_jack_dev_register(struct snd_device *device)int err;snprintf (jack->name,sizeof (jack->name),"%s %s" , - card->longname, jack->id); + card->shortname, jack->id); jack->input_dev->name = jack->name;/* Default to the sound card device. */
Quoted 3 lines · Takashi Iwai
I'm not sure whether I've already asked it, but I find it ugly to refer to
card->longnamefor the input device name insound/core/jack.c.
Yes, it was discussed at the time. This was chosen because the input subsystems tends towards the verbose when giving names to devices.
Quoted 1 line
Can it be changed to
card->shortname, at least?
Obviously, it's just a display string. I think what happened is that when I checked this on some desktop systems I misread card->id as being card->shortname in the /proc/asound output. The former is far too cryptic to be idiomatic in the input subsystem.
At Wed, 18 Feb 2009 14:39:14 +0000,
Quoted 9 lines · Mark Brown
Quoted 3 lines · Takashi Iwai
I'm not sure whether I've already asked it, but I find it ugly to refer to
card->longnamefor the input device name insound/core/jack.c.Yes, it was discussed at the time. This was chosen because the input subsystems tends towards the verbose when giving names to devices.
Ah yes, but longname is still too ugly as an identifier, IMHO. That's why I'm asking again.
At each time it's shown in kernel messages, I wonder what is that at all. It's hard to decode as "Jack..." string appears at the very last of the name.
Quoted 6 lines
Quoted 1 line
Can it be changed to
card->shortname, at least?Obviously, it's just a display string. I think what happened is that when I checked this on some desktop systems I misread
card->idas beingcard->shortnamein the/proc/asoundoutput. The former is far too cryptic to be idiomatic in the input subsystem.
Yeah, card->id is no good form. card->shortname usually contains the basic vendor and product names but without irq, i/o port or such information as in longname.
Takashi
Quoted 12 lines · Takashi Iwai
At Wed, 18 Feb 2009 14:39:14 +0000,
Quoted 9 lines · Mark Brown
Quoted 3 lines · Takashi Iwai
I'm not sure whether I've already asked it, but I find it ugly to refer to
card->longnamefor the input device name insound/core/jack.c.Yes, it was discussed at the time. This was chosen because the input subsystems tends towards the verbose when giving names to devices.
Quoted 6 lines
Ah yes, but longname is still too ugly as an identifier, IMHO. That's why I'm asking again.
At each time it's shown in kernel messages, I wonder what is that at all. It's hard to decode as "Jack..." string appears at the very last of the name.
Sorry, I wasn't clear - I agree with the proposed change.
Quoted 16 lines
Quoted 8 lines
Quoted 2 lines
Can it be changed to
card->shortname, at least?Obviously, it's just a display string. I think what happened is that when I checked this on some desktop systems I misread
card->idas beingcard->shortnamein the/proc/asoundoutput. The former is far too cryptic to be idiomatic in the input subsystem.Yeah,
card->idis no good form.card->shortnameusually contains the basic vendor and product names but without irq, i/o port or such information as in longname.Takashi
At Wed, 18 Feb 2009 15:36:00 +0000,
Quoted 15 lines · Mark Brown
Quoted 12 lines · Takashi Iwai
At Wed, 18 Feb 2009 14:39:14 +0000,
Quoted 9 lines · Mark Brown
Quoted 3 lines · Takashi Iwai
I'm not sure whether I've already asked it, but I find it ugly to refer to
card->longnamefor the input device name insound/core/jack.c.Yes, it was discussed at the time. This was chosen because the input subsystems tends towards the verbose when giving names to devices.
Quoted 8 lines
Quoted 6 lines
Ah yes, but longname is still too ugly as an identifier, IMHO. That's why I'm asking again.
At each time it's shown in kernel messages, I wonder what is that at all. It's hard to decode as "Jack..." string appears at the very last of the name.
Sorry, I wasn't clear - I agree with the proposed change.
OK, fixed now :)
thanks,
Takashi