All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH] alsactl: Do not run udev rule before datadir is mounted
@ 2014-06-13  8:15 David Henningsson
  2014-06-13  8:26 ` Jaroslav Kysela
  0 siblings, 1 reply; 14+ messages in thread
From: David Henningsson @ 2014-06-13  8:15 UTC (permalink / raw)
  To: perex, tiwai, alsa-devel; +Cc: 1289730, David Henningsson

The 90-alsa-restore.rules udev rule is primarily meant to handle hotplugging,
but sometimes it is also run before /usr is mounted,
and alsactl restore depends on /usr/share/alsa being present.

If /usr/share/alsa is not present, we're so early in the boot
process that alsa-restore.service (or upstart equivalent) will
run later on.

BugLink: https://bugs.launchpad.net/bugs/1289730
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
---

I'm not really sure of all quirks in the boot process, and I haven't tested the
patch either, hence the RFC above. Do you think it makes sense? Should we also
add @sbindir@ to the things to test for?

 alsactl/90-alsa-restore.rules.in | 2 +-
 alsactl/Makefile.am              | 1 +
 configure.ac                     | 1 +
 3 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/alsactl/90-alsa-restore.rules.in b/alsactl/90-alsa-restore.rules.in
index c68119d..c83c6b5 100644
--- a/alsactl/90-alsa-restore.rules.in
+++ b/alsactl/90-alsa-restore.rules.in
@@ -1,4 +1,4 @@
-ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", GOTO="alsa_restore_go"
+ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", TEST=="@datadir@", GOTO="alsa_restore_go"
 GOTO="alsa_restore_end"
 
 LABEL="alsa_restore_go"
diff --git a/alsactl/Makefile.am b/alsactl/Makefile.am
index b862412..afbedb3 100644
--- a/alsactl/Makefile.am
+++ b/alsactl/Makefile.am
@@ -44,6 +44,7 @@ endif
 
 edit = \
 	$(SED) -r -e 's,@sbindir\@,$(sbindir),g' \
+		  -e 's,@datadir\@,$(mydatadir),g' \
 		  -e 's,@daemonswitch\@,$(ALSACTL_DAEMONSWITCH),g' \
 							< $< > $@ || rm $@
 
diff --git a/configure.ac b/configure.ac
index 7e6894a..a4d2db3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -292,6 +292,7 @@ AC_DEFINE_UNQUOTED(SOUNDSDIR, "$soundsdir", [directory containing sample data])
 
 mydatadir="$dir/alsa"
 AC_DEFINE_UNQUOTED(DATADIR, "$mydatadir", [directory containing alsa configuration])
+AC_SUBST(mydatadir)
 
 AC_ARG_WITH(testsound,
   AS_HELP_STRING([--with-testsound=file], [give the path of test sound file for alsaconf]),
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [RFC PATCH] alsactl: Do not run udev rule before datadir is mounted
  2014-06-13  8:15 [RFC PATCH] alsactl: Do not run udev rule before datadir is mounted David Henningsson
@ 2014-06-13  8:26 ` Jaroslav Kysela
  2014-06-13  9:05   ` David Henningsson
  0 siblings, 1 reply; 14+ messages in thread
From: Jaroslav Kysela @ 2014-06-13  8:26 UTC (permalink / raw)
  To: David Henningsson, tiwai, alsa-devel; +Cc: 1289730

Date 13.6.2014 10:15, David Henningsson wrote:
> The 90-alsa-restore.rules udev rule is primarily meant to handle hotplugging,
> but sometimes it is also run before /usr is mounted,
> and alsactl restore depends on /usr/share/alsa being present.
> 
> If /usr/share/alsa is not present, we're so early in the boot
> process that alsa-restore.service (or upstart equivalent) will
> run later on.
> 
> BugLink: https://bugs.launchpad.net/bugs/1289730
> Signed-off-by: David Henningsson <david.henningsson@canonical.com>
> ---
> 
> I'm not really sure of all quirks in the boot process, and I haven't tested the
> patch either, hence the RFC above. Do you think it makes sense?

Yes, I think that's ok. Takashi?

> Should we also add @sbindir@ to the things to test for?

It shouldn't harm anything. Could you prepare a new patch?

>  alsactl/90-alsa-restore.rules.in | 2 +-
>  alsactl/Makefile.am              | 1 +
>  configure.ac                     | 1 +
>  3 files changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/alsactl/90-alsa-restore.rules.in b/alsactl/90-alsa-restore.rules.in
> index c68119d..c83c6b5 100644
> --- a/alsactl/90-alsa-restore.rules.in
> +++ b/alsactl/90-alsa-restore.rules.in
> @@ -1,4 +1,4 @@
> -ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", GOTO="alsa_restore_go"
> +ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", TEST=="@datadir@", GOTO="alsa_restore_go"
>  GOTO="alsa_restore_end"
>  
>  LABEL="alsa_restore_go"
> diff --git a/alsactl/Makefile.am b/alsactl/Makefile.am
> index b862412..afbedb3 100644
> --- a/alsactl/Makefile.am
> +++ b/alsactl/Makefile.am
> @@ -44,6 +44,7 @@ endif
>  
>  edit = \
>  	$(SED) -r -e 's,@sbindir\@,$(sbindir),g' \
> +		  -e 's,@datadir\@,$(mydatadir),g' \
>  		  -e 's,@daemonswitch\@,$(ALSACTL_DAEMONSWITCH),g' \
>  							< $< > $@ || rm $@
>  
> diff --git a/configure.ac b/configure.ac
> index 7e6894a..a4d2db3 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -292,6 +292,7 @@ AC_DEFINE_UNQUOTED(SOUNDSDIR, "$soundsdir", [directory containing sample data])
>  
>  mydatadir="$dir/alsa"
>  AC_DEFINE_UNQUOTED(DATADIR, "$mydatadir", [directory containing alsa configuration])
> +AC_SUBST(mydatadir)
>  
>  AC_ARG_WITH(testsound,
>    AS_HELP_STRING([--with-testsound=file], [give the path of test sound file for alsaconf]),
> 


-- 
Jaroslav Kysela <perex@perex.cz>
Linux Kernel Sound Maintainer
ALSA Project; Red Hat, Inc.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [RFC PATCH] alsactl: Do not run udev rule before datadir is mounted
  2014-06-13  8:26 ` Jaroslav Kysela
@ 2014-06-13  9:05   ` David Henningsson
  2014-06-13  9:11     ` Jaroslav Kysela
  2014-06-13  9:20     ` Takashi Iwai
  0 siblings, 2 replies; 14+ messages in thread
From: David Henningsson @ 2014-06-13  9:05 UTC (permalink / raw)
  To: Jaroslav Kysela, tiwai, alsa-devel; +Cc: 1289730

[-- Attachment #1: Type: text/plain, Size: 2791 bytes --]



On 2014-06-13 10:26, Jaroslav Kysela wrote:
> Date 13.6.2014 10:15, David Henningsson wrote:
>> The 90-alsa-restore.rules udev rule is primarily meant to handle hotplugging,
>> but sometimes it is also run before /usr is mounted,
>> and alsactl restore depends on /usr/share/alsa being present.
>>
>> If /usr/share/alsa is not present, we're so early in the boot
>> process that alsa-restore.service (or upstart equivalent) will
>> run later on.
>>
>> BugLink: https://bugs.launchpad.net/bugs/1289730
>> Signed-off-by: David Henningsson <david.henningsson@canonical.com>
>> ---
>>
>> I'm not really sure of all quirks in the boot process, and I haven't tested the
>> patch either, hence the RFC above. Do you think it makes sense?
>
> Yes, I think that's ok. Takashi?
>
>> Should we also add @sbindir@ to the things to test for?
>
> It shouldn't harm anything. Could you prepare a new patch?

Sure, please find it attached. I was also considering adding something 
under /var as well, but I didn't do that, because I think it will fall 
back to an "alsactl init" in that case (right?), so it still makes some 
sense to run alsactl without /var.

>
>>   alsactl/90-alsa-restore.rules.in | 2 +-
>>   alsactl/Makefile.am              | 1 +
>>   configure.ac                     | 1 +
>>   3 files changed, 3 insertions(+), 1 deletion(-)
>>
>> diff --git a/alsactl/90-alsa-restore.rules.in b/alsactl/90-alsa-restore.rules.in
>> index c68119d..c83c6b5 100644
>> --- a/alsactl/90-alsa-restore.rules.in
>> +++ b/alsactl/90-alsa-restore.rules.in
>> @@ -1,4 +1,4 @@
>> -ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", GOTO="alsa_restore_go"
>> +ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", TEST=="@datadir@", GOTO="alsa_restore_go"
>>   GOTO="alsa_restore_end"
>>
>>   LABEL="alsa_restore_go"
>> diff --git a/alsactl/Makefile.am b/alsactl/Makefile.am
>> index b862412..afbedb3 100644
>> --- a/alsactl/Makefile.am
>> +++ b/alsactl/Makefile.am
>> @@ -44,6 +44,7 @@ endif
>>
>>   edit = \
>>   	$(SED) -r -e 's,@sbindir\@,$(sbindir),g' \
>> +		  -e 's,@datadir\@,$(mydatadir),g' \
>>   		  -e 's,@daemonswitch\@,$(ALSACTL_DAEMONSWITCH),g' \
>>   							< $< > $@ || rm $@
>>
>> diff --git a/configure.ac b/configure.ac
>> index 7e6894a..a4d2db3 100644
>> --- a/configure.ac
>> +++ b/configure.ac
>> @@ -292,6 +292,7 @@ AC_DEFINE_UNQUOTED(SOUNDSDIR, "$soundsdir", [directory containing sample data])
>>
>>   mydatadir="$dir/alsa"
>>   AC_DEFINE_UNQUOTED(DATADIR, "$mydatadir", [directory containing alsa configuration])
>> +AC_SUBST(mydatadir)
>>
>>   AC_ARG_WITH(testsound,
>>     AS_HELP_STRING([--with-testsound=file], [give the path of test sound file for alsaconf]),
>>
>
>

-- 
David Henningsson, Canonical Ltd.
https://launchpad.net/~diwic

[-- Attachment #2: 0001-alsactl-Do-not-run-udev-rule-before-datadir-sbindir-.patch --]
[-- Type: text/x-patch, Size: 2119 bytes --]

>From 09a4abb5560448eb434a33fc237d578e14666940 Mon Sep 17 00:00:00 2001
From: David Henningsson <david.henningsson@canonical.com>
Date: Fri, 13 Jun 2014 10:04:25 +0200
Subject: [PATCH] alsactl: Do not run udev rule before datadir/sbindir are both
 mounted

Sometimes 90-alsa-restore.rules is run before /usr is mounted,
and alsactl restore depends on /usr/share/alsa being present.

If /usr/share/alsa is not present, we're so early in the boot
process that alsa-restore.service (or upstart equivalent) will
run later on.

BugLink: https://bugs.launchpad.net/bugs/1289730
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
---
 alsactl/90-alsa-restore.rules.in | 2 +-
 alsactl/Makefile.am              | 1 +
 configure.ac                     | 1 +
 3 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/alsactl/90-alsa-restore.rules.in b/alsactl/90-alsa-restore.rules.in
index c68119d..80fc043 100644
--- a/alsactl/90-alsa-restore.rules.in
+++ b/alsactl/90-alsa-restore.rules.in
@@ -1,4 +1,4 @@
-ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", GOTO="alsa_restore_go"
+ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", TEST=="@sbindir@", TEST=="@datadir@", GOTO="alsa_restore_go"
 GOTO="alsa_restore_end"
 
 LABEL="alsa_restore_go"
diff --git a/alsactl/Makefile.am b/alsactl/Makefile.am
index b862412..afbedb3 100644
--- a/alsactl/Makefile.am
+++ b/alsactl/Makefile.am
@@ -44,6 +44,7 @@ endif
 
 edit = \
 	$(SED) -r -e 's,@sbindir\@,$(sbindir),g' \
+		  -e 's,@datadir\@,$(mydatadir),g' \
 		  -e 's,@daemonswitch\@,$(ALSACTL_DAEMONSWITCH),g' \
 							< $< > $@ || rm $@
 
diff --git a/configure.ac b/configure.ac
index 7e6894a..a4d2db3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -292,6 +292,7 @@ AC_DEFINE_UNQUOTED(SOUNDSDIR, "$soundsdir", [directory containing sample data])
 
 mydatadir="$dir/alsa"
 AC_DEFINE_UNQUOTED(DATADIR, "$mydatadir", [directory containing alsa configuration])
+AC_SUBST(mydatadir)
 
 AC_ARG_WITH(testsound,
   AS_HELP_STRING([--with-testsound=file], [give the path of test sound file for alsaconf]),
-- 
1.9.1


[-- Attachment #3: Type: text/plain, Size: 0 bytes --]



^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [RFC PATCH] alsactl: Do not run udev rule before datadir is mounted
  2014-06-13  9:05   ` David Henningsson
@ 2014-06-13  9:11     ` Jaroslav Kysela
  2014-06-13  9:20     ` Takashi Iwai
  1 sibling, 0 replies; 14+ messages in thread
From: Jaroslav Kysela @ 2014-06-13  9:11 UTC (permalink / raw)
  To: David Henningsson, tiwai, alsa-devel; +Cc: 1289730

Date 13.6.2014 11:05, David Henningsson wrote:
> 
> 
> On 2014-06-13 10:26, Jaroslav Kysela wrote:
>> Date 13.6.2014 10:15, David Henningsson wrote:
>>> The 90-alsa-restore.rules udev rule is primarily meant to handle hotplugging,
>>> but sometimes it is also run before /usr is mounted,
>>> and alsactl restore depends on /usr/share/alsa being present.
>>>
>>> If /usr/share/alsa is not present, we're so early in the boot
>>> process that alsa-restore.service (or upstart equivalent) will
>>> run later on.
>>>
>>> BugLink: https://bugs.launchpad.net/bugs/1289730
>>> Signed-off-by: David Henningsson <david.henningsson@canonical.com>
>>> ---
>>>
>>> I'm not really sure of all quirks in the boot process, and I haven't tested the
>>> patch either, hence the RFC above. Do you think it makes sense?
>>
>> Yes, I think that's ok. Takashi?
>>
>>> Should we also add @sbindir@ to the things to test for?
>>
>> It shouldn't harm anything. Could you prepare a new patch?
> 
> Sure, please find it attached. I was also considering adding something 
> under /var as well, but I didn't do that, because I think it will fall 
> back to an "alsactl init" in that case (right?), so it still makes some 
> sense to run alsactl without /var.

Yes, /var contents is not mandatory. Thanks, I applied it to the
alsa-utils repository.

					Jaroslav

-- 
Jaroslav Kysela <perex@perex.cz>
Linux Kernel Sound Maintainer
ALSA Project; Red Hat, Inc.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [RFC PATCH] alsactl: Do not run udev rule before datadir is mounted
  2014-06-13  9:05   ` David Henningsson
  2014-06-13  9:11     ` Jaroslav Kysela
@ 2014-06-13  9:20     ` Takashi Iwai
  2014-06-13  9:33       ` David Henningsson
  1 sibling, 1 reply; 14+ messages in thread
From: Takashi Iwai @ 2014-06-13  9:20 UTC (permalink / raw)
  To: David Henningsson; +Cc: 1289730, alsa-devel

At Fri, 13 Jun 2014 11:05:52 +0200,
David Henningsson wrote:
> 
> 
> 
> On 2014-06-13 10:26, Jaroslav Kysela wrote:
> > Date 13.6.2014 10:15, David Henningsson wrote:
> >> The 90-alsa-restore.rules udev rule is primarily meant to handle hotplugging,
> >> but sometimes it is also run before /usr is mounted,
> >> and alsactl restore depends on /usr/share/alsa being present.
> >>
> >> If /usr/share/alsa is not present, we're so early in the boot
> >> process that alsa-restore.service (or upstart equivalent) will
> >> run later on.
> >>
> >> BugLink: https://bugs.launchpad.net/bugs/1289730
> >> Signed-off-by: David Henningsson <david.henningsson@canonical.com>
> >> ---
> >>
> >> I'm not really sure of all quirks in the boot process, and I haven't tested the
> >> patch either, hence the RFC above. Do you think it makes sense?
> >
> > Yes, I think that's ok. Takashi?
> >
> >> Should we also add @sbindir@ to the things to test for?
> >
> > It shouldn't harm anything. Could you prepare a new patch?
> 
> Sure, please find it attached. I was also considering adding something 
> under /var as well, but I didn't do that, because I think it will fall 
> back to an "alsactl init" in that case (right?), so it still makes some 
> sense to run alsactl without /var.
> 
> >
> >>   alsactl/90-alsa-restore.rules.in | 2 +-
> >>   alsactl/Makefile.am              | 1 +
> >>   configure.ac                     | 1 +
> >>   3 files changed, 3 insertions(+), 1 deletion(-)
> >>
> >> diff --git a/alsactl/90-alsa-restore.rules.in b/alsactl/90-alsa-restore.rules.in
> >> index c68119d..c83c6b5 100644
> >> --- a/alsactl/90-alsa-restore.rules.in
> >> +++ b/alsactl/90-alsa-restore.rules.in
> >> @@ -1,4 +1,4 @@
> >> -ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", GOTO="alsa_restore_go"
> >> +ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", TEST=="@datadir@", GOTO="alsa_restore_go"
> >>   GOTO="alsa_restore_end"
> >>
> >>   LABEL="alsa_restore_go"
> >> diff --git a/alsactl/Makefile.am b/alsactl/Makefile.am
> >> index b862412..afbedb3 100644
> >> --- a/alsactl/Makefile.am
> >> +++ b/alsactl/Makefile.am
> >> @@ -44,6 +44,7 @@ endif
> >>
> >>   edit = \
> >>   	$(SED) -r -e 's,@sbindir\@,$(sbindir),g' \
> >> +		  -e 's,@datadir\@,$(mydatadir),g' \
> >>   		  -e 's,@daemonswitch\@,$(ALSACTL_DAEMONSWITCH),g' \
> >>   							< $< > $@ || rm $@
> >>
> >> diff --git a/configure.ac b/configure.ac
> >> index 7e6894a..a4d2db3 100644
> >> --- a/configure.ac
> >> +++ b/configure.ac
> >> @@ -292,6 +292,7 @@ AC_DEFINE_UNQUOTED(SOUNDSDIR, "$soundsdir", [directory containing sample data])
> >>
> >>   mydatadir="$dir/alsa"
> >>   AC_DEFINE_UNQUOTED(DATADIR, "$mydatadir", [directory containing alsa configuration])
> >> +AC_SUBST(mydatadir)
> >>
> >>   AC_ARG_WITH(testsound,
> >>     AS_HELP_STRING([--with-testsound=file], [give the path of test sound file for alsaconf]),
> >>
> >
> >
> 
> -- 
> David Henningsson, Canonical Ltd.
> https://launchpad.net/~diwic
> >From 09a4abb5560448eb434a33fc237d578e14666940 Mon Sep 17 00:00:00 2001
> From: David Henningsson <david.henningsson@canonical.com>
> Date: Fri, 13 Jun 2014 10:04:25 +0200
> Subject: [PATCH] alsactl: Do not run udev rule before datadir/sbindir are both
>  mounted
> 
> Sometimes 90-alsa-restore.rules is run before /usr is mounted,
> and alsactl restore depends on /usr/share/alsa being present.
> 
> If /usr/share/alsa is not present, we're so early in the boot
> process that alsa-restore.service (or upstart equivalent) will
> run later on.
> 
> BugLink: https://bugs.launchpad.net/bugs/1289730
> Signed-off-by: David Henningsson <david.henningsson@canonical.com>
> ---
>  alsactl/90-alsa-restore.rules.in | 2 +-
>  alsactl/Makefile.am              | 1 +
>  configure.ac                     | 1 +
>  3 files changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/alsactl/90-alsa-restore.rules.in b/alsactl/90-alsa-restore.rules.in
> index c68119d..80fc043 100644
> --- a/alsactl/90-alsa-restore.rules.in
> +++ b/alsactl/90-alsa-restore.rules.in
> @@ -1,4 +1,4 @@
> -ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", GOTO="alsa_restore_go"
> +ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", TEST=="@sbindir@", TEST=="@datadir@", GOTO="alsa_restore_go"
>  GOTO="alsa_restore_end"

IMO, it's better to use @mydatadir@ instead of @datadir@ here and...

>  
>  LABEL="alsa_restore_go"
> diff --git a/alsactl/Makefile.am b/alsactl/Makefile.am
> index b862412..afbedb3 100644
> --- a/alsactl/Makefile.am
> +++ b/alsactl/Makefile.am
> @@ -44,6 +44,7 @@ endif
>  
>  edit = \
>  	$(SED) -r -e 's,@sbindir\@,$(sbindir),g' \
> +		  -e 's,@datadir\@,$(mydatadir),g' \

... here.  Otherwise it may be confusing.

Other than that, the change looks good to me.

Jaroslav, could you fix up quickly in your side?


thanks,

Takashi

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [RFC PATCH] alsactl: Do not run udev rule before datadir is mounted
  2014-06-13  9:20     ` Takashi Iwai
@ 2014-06-13  9:33       ` David Henningsson
  2014-06-13 10:08         ` ALSA 1.0.28 release - request for testing Jaroslav Kysela
  0 siblings, 1 reply; 14+ messages in thread
From: David Henningsson @ 2014-06-13  9:33 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: 1289730, alsa-devel

[-- Attachment #1: Type: text/plain, Size: 589 bytes --]



On 2014-06-13 11:20, Takashi Iwai wrote:

>> +++ b/alsactl/90-alsa-restore.rules.in
>> @@ -1,4 +1,4 @@
>> -ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", GOTO="alsa_restore_go"
>> +ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", TEST=="@sbindir@", TEST=="@datadir@", GOTO="alsa_restore_go"
>>   GOTO="alsa_restore_end"
>
> IMO, it's better to use @mydatadir@ instead of @datadir@ here and...

Oops, sorry about that. Thanks for the review!

Attaching a fixup patch.

-- 
David Henningsson, Canonical Ltd.
https://launchpad.net/~diwic

[-- Attachment #2: 0001-alsactl-Fixup-test-for-mydatadir-sbindir.patch --]
[-- Type: text/x-patch, Size: 1399 bytes --]

>From 7402d0421df6782dd7af9a30f3bc1223057cd9f3 Mon Sep 17 00:00:00 2001
From: David Henningsson <david.henningsson@canonical.com>
Date: Fri, 13 Jun 2014 11:31:44 +0200
Subject: [PATCH] alsactl: Fixup test for mydatadir/sbindir

Use the "mydatadir" name consistently.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
---
 alsactl/90-alsa-restore.rules.in | 2 +-
 alsactl/Makefile.am              | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/alsactl/90-alsa-restore.rules.in b/alsactl/90-alsa-restore.rules.in
index 80fc043..c0c1b23 100644
--- a/alsactl/90-alsa-restore.rules.in
+++ b/alsactl/90-alsa-restore.rules.in
@@ -1,4 +1,4 @@
-ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", TEST=="@sbindir@", TEST=="@datadir@", GOTO="alsa_restore_go"
+ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", TEST=="@sbindir@", TEST=="@mydatadir@", GOTO="alsa_restore_go"
 GOTO="alsa_restore_end"
 
 LABEL="alsa_restore_go"
diff --git a/alsactl/Makefile.am b/alsactl/Makefile.am
index afbedb3..47f06e9 100644
--- a/alsactl/Makefile.am
+++ b/alsactl/Makefile.am
@@ -44,7 +44,7 @@ endif
 
 edit = \
 	$(SED) -r -e 's,@sbindir\@,$(sbindir),g' \
-		  -e 's,@datadir\@,$(mydatadir),g' \
+		  -e 's,@mydatadir\@,$(mydatadir),g' \
 		  -e 's,@daemonswitch\@,$(ALSACTL_DAEMONSWITCH),g' \
 							< $< > $@ || rm $@
 
-- 
1.9.1


[-- Attachment #3: Type: text/plain, Size: 0 bytes --]



^ permalink raw reply related	[flat|nested] 14+ messages in thread

* ALSA 1.0.28 release - request for testing
  2014-06-13  9:33       ` David Henningsson
@ 2014-06-13 10:08         ` Jaroslav Kysela
  2014-06-13 10:52           ` David Henningsson
                             ` (3 more replies)
  0 siblings, 4 replies; 14+ messages in thread
From: Jaroslav Kysela @ 2014-06-13 10:08 UTC (permalink / raw)
  To: ALSA development; +Cc: Takashi Iwai, David Henningsson

Hello all,

  ALSA 1.0.28 packages are available for testing at

ftp://ftp.alsa-project.org/pub/testing/

  Please, report any issues. I expect to announce the release on Monday.

					Jaroslav

-----
Jaroslav Kysela <perex@perex.cz>
Linux Kernel Sound Maintainer
ALSA Project; Red Hat, Inc.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: ALSA 1.0.28 release - request for testing
  2014-06-13 10:08         ` ALSA 1.0.28 release - request for testing Jaroslav Kysela
@ 2014-06-13 10:52           ` David Henningsson
  2014-06-13 17:17             ` Jaroslav Kysela
  2014-06-13 10:59           ` Alexander E. Patrakov
                             ` (2 subsequent siblings)
  3 siblings, 1 reply; 14+ messages in thread
From: David Henningsson @ 2014-06-13 10:52 UTC (permalink / raw)
  To: Jaroslav Kysela, ALSA development; +Cc: Takashi Iwai



On 2014-06-13 12:08, Jaroslav Kysela wrote:
> Hello all,
>
>    ALSA 1.0.28 packages are available for testing at
>
> ftp://ftp.alsa-project.org/pub/testing/
>
>    Please, report any issues. I expect to announce the release on Monday.

Thanks!

I'm testing build of alsa-lib now and I have two questions:

1) the final so version seems to be libasound.so.2.0.0 for both 1.0.27 
and 1.0.28. I'm not sure how important it is, but shouldn't this be 
increased to 2.0.1 or 2.1.0 to reflect code changes?

2) This probably is not a new issue, but I was wondering about all the 
extra files created in configure.ac, e g ctl_symbols_list.c. Are they 
ever cleaned by some "clean", "maintainerclean" or similar rule?

-- 
David Henningsson, Canonical Ltd.
https://launchpad.net/~diwic

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: ALSA 1.0.28 release - request for testing
  2014-06-13 10:08         ` ALSA 1.0.28 release - request for testing Jaroslav Kysela
  2014-06-13 10:52           ` David Henningsson
@ 2014-06-13 10:59           ` Alexander E. Patrakov
  2014-06-13 17:19             ` Jaroslav Kysela
  2014-06-13 11:02           ` David Henningsson
  2014-06-14 12:11           ` ALSA 1.0.28 release - Assertion failed Sergey
  3 siblings, 1 reply; 14+ messages in thread
From: Alexander E. Patrakov @ 2014-06-13 10:59 UTC (permalink / raw)
  To: Jaroslav Kysela, ALSA development; +Cc: Takashi Iwai, David Henningsson

13.06.2014 16:08, Jaroslav Kysela пишет:
> Hello all,
>
>    ALSA 1.0.28 packages are available for testing at
>
> ftp://ftp.alsa-project.org/pub/testing/
>
>    Please, report any issues. I expect to announce the release on Monday.

/usr/share/alsa/cards/Loopback.conf talks about "Intel HD audio 
(ICH6/ICH7)". This looks suspicious.

-- 
Alexander E. Patrakov
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: ALSA 1.0.28 release - request for testing
  2014-06-13 10:08         ` ALSA 1.0.28 release - request for testing Jaroslav Kysela
  2014-06-13 10:52           ` David Henningsson
  2014-06-13 10:59           ` Alexander E. Patrakov
@ 2014-06-13 11:02           ` David Henningsson
  2014-06-13 17:19             ` Jaroslav Kysela
  2014-06-14 12:11           ` ALSA 1.0.28 release - Assertion failed Sergey
  3 siblings, 1 reply; 14+ messages in thread
From: David Henningsson @ 2014-06-13 11:02 UTC (permalink / raw)
  To: Jaroslav Kysela, ALSA development; +Cc: Takashi Iwai, jordi

[-- Attachment #1: Type: text/plain, Size: 561 bytes --]

While testing alsa-lib I found that the attached patch - which comes 
from Debian - probably should be applied upstream as well.

On 2014-06-13 12:08, Jaroslav Kysela wrote:
> Hello all,
>
>    ALSA 1.0.28 packages are available for testing at
>
> ftp://ftp.alsa-project.org/pub/testing/
>
>    Please, report any issues. I expect to announce the release on Monday.
>
> 					Jaroslav
>
> -----
> Jaroslav Kysela <perex@perex.cz>
> Linux Kernel Sound Maintainer
> ALSA Project; Red Hat, Inc.
>

-- 
David Henningsson, Canonical Ltd.
https://launchpad.net/~diwic

[-- Attachment #2: tests_lm_ftbfs.patch --]
[-- Type: text/x-patch, Size: 895 bytes --]

>From 7a794ce0d1e28f191e113742ce1604334b4187f2 Mon Sep 17 00:00:00 2001
From: Jordi Mallach <jordi@debian.org>
Date: Fri, 28 Jun 2013 15:01:40 +0200
Subject: [PATCH] Add -lm to test programs to fix build failure.

Add -lm to test programs that use sin(), to fix a build failure with recent
binutils.

Signed-off-by: Jordi Mallach <jordi@debian.org>
---
 test/Makefile.am | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/test/Makefile.am b/test/Makefile.am
index 8705402..c1896f8 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -7,8 +7,10 @@ check_PROGRAMS=control pcm pcm_min latency seq \
 
 control_LDADD=../src/libasound.la
 pcm_LDADD=../src/libasound.la
+pcm_LDFLAGS= -lm
 pcm_min_LDADD=../src/libasound.la
 latency_LDADD=../src/libasound.la
+latency_LDFLAGS= -lm
 seq_LDADD=../src/libasound.la
 playmidi1_LDADD=../src/libasound.la
 timer_LDADD=../src/libasound.la
-- 
1.8.3.1


[-- Attachment #3: Type: text/plain, Size: 0 bytes --]



^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: ALSA 1.0.28 release - request for testing
  2014-06-13 10:52           ` David Henningsson
@ 2014-06-13 17:17             ` Jaroslav Kysela
  0 siblings, 0 replies; 14+ messages in thread
From: Jaroslav Kysela @ 2014-06-13 17:17 UTC (permalink / raw)
  To: David Henningsson, ALSA development; +Cc: Takashi Iwai

Date 13.6.2014 12:52, David Henningsson wrote:
> 
> 
> On 2014-06-13 12:08, Jaroslav Kysela wrote:
>> Hello all,
>>
>>    ALSA 1.0.28 packages are available for testing at
>>
>> ftp://ftp.alsa-project.org/pub/testing/
>>
>>    Please, report any issues. I expect to announce the release on Monday.
> 
> Thanks!
> 
> I'm testing build of alsa-lib now and I have two questions:
> 
> 1) the final so version seems to be libasound.so.2.0.0 for both 1.0.27 
> and 1.0.28. I'm not sure how important it is, but shouldn't this be 
> increased to 2.0.1 or 2.1.0 to reflect code changes?

I think that we had some discussion about this and we use different
system to identify new libraries:

1) there is snd_asoundlib_version() function
2) the packaging system identifies the exact used library version
3) we use deprecated linker warning for obsolete symbols
4) only "current" libtool version number will be changed when
   the library is not backwards compatible, otherwise all symbols must
   be present and compatible

Basically, we haven't found the current:revision:age numbering useable
for our rules and as the libtool documentation states, it should not
reflect the release number at all.

Even if the age is increased, nobody will have/known a correlation
between the package release version and the library version. It means -
we would update a number for nothing in this case.

Eventually (contradicting to the paragraphs above) the age might reflect
the release number in form like:

1.0.28.3  ->  2:0:283

Future alsa-lib numbering:

2.33.5 -> 3:0:335 or 2:1:335 (if the library is backward compatible)

And this makes the question, if the version of packages should be
increased to 2.0.0 in next release to lower the last number :-)

> 2) This probably is not a new issue, but I was wondering about all the 
> extra files created in configure.ac, e g ctl_symbols_list.c. Are they 
> ever cleaned by some "clean", "maintainerclean" or similar rule?

Nobody has required this. Patches are welcome. I'm using the 'git
archive' to obtain the sources without these extra files for the
packaging purposes and 'make dist'.

				Jaroslav

-- 
Jaroslav Kysela <perex@perex.cz>
Linux Kernel Sound Maintainer
ALSA Project; Red Hat, Inc.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: ALSA 1.0.28 release - request for testing
  2014-06-13 10:59           ` Alexander E. Patrakov
@ 2014-06-13 17:19             ` Jaroslav Kysela
  0 siblings, 0 replies; 14+ messages in thread
From: Jaroslav Kysela @ 2014-06-13 17:19 UTC (permalink / raw)
  To: Alexander E. Patrakov, ALSA development; +Cc: Takashi Iwai, David Henningsson

Date 13.6.2014 12:59, Alexander E. Patrakov wrote:
> 13.06.2014 16:08, Jaroslav Kysela пишет:
>> Hello all,
>>
>>    ALSA 1.0.28 packages are available for testing at
>>
>> ftp://ftp.alsa-project.org/pub/testing/
>>
>>    Please, report any issues. I expect to announce the release on Monday.
> 
> /usr/share/alsa/cards/Loopback.conf talks about "Intel HD audio 
> (ICH6/ICH7)". This looks suspicious.
> 

Thanks. Fixed.

                    Jaroslav


-- 
Jaroslav Kysela <perex@perex.cz>
Linux Kernel Sound Maintainer
ALSA Project; Red Hat, Inc.
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: ALSA 1.0.28 release - request for testing
  2014-06-13 11:02           ` David Henningsson
@ 2014-06-13 17:19             ` Jaroslav Kysela
  0 siblings, 0 replies; 14+ messages in thread
From: Jaroslav Kysela @ 2014-06-13 17:19 UTC (permalink / raw)
  To: David Henningsson, ALSA development; +Cc: Takashi Iwai, jordi

Date 13.6.2014 13:02, David Henningsson wrote:
> While testing alsa-lib I found that the attached patch - which comes 
> from Debian - probably should be applied upstream as well.

Thanks. Applied.

                   Jaroslav

> 
> On 2014-06-13 12:08, Jaroslav Kysela wrote:
>> Hello all,
>>
>>    ALSA 1.0.28 packages are available for testing at
>>
>> ftp://ftp.alsa-project.org/pub/testing/
>>
>>    Please, report any issues. I expect to announce the release on Monday.
>>
>> 					Jaroslav
>>
>> -----
>> Jaroslav Kysela <perex@perex.cz>
>> Linux Kernel Sound Maintainer
>> ALSA Project; Red Hat, Inc.
>>
> 


-- 
Jaroslav Kysela <perex@perex.cz>
Linux Kernel Sound Maintainer
ALSA Project; Red Hat, Inc.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: ALSA 1.0.28 release - Assertion failed
  2014-06-13 10:08         ` ALSA 1.0.28 release - request for testing Jaroslav Kysela
                             ` (2 preceding siblings ...)
  2014-06-13 11:02           ` David Henningsson
@ 2014-06-14 12:11           ` Sergey
  3 siblings, 0 replies; 14+ messages in thread
From: Sergey @ 2014-06-14 12:11 UTC (permalink / raw)
  To: alsa-devel

Fri, 13 Jun 2014, Jaroslav Kysela wrote:

>   ALSA 1.0.28 packages are available for testing at
> 
> ftp://ftp.alsa-project.org/pub/testing/
> 
>   Please, report any issues. I expect to announce the release on Monday.

I get "Assertion failed" with plug for float data.
No patch yet. I'm still trying to understand how "plug" works.
The bug was in earlier alsa versions too. Was almost fixed by 2da7b0c2
(discussion http://thread.gmane.org/gmane.linux.alsa.devel/119358)

I first found it with a complex ladspa upmix config, like:
  http://forums.gentoo.org/viewtopic-p-4528619.html#4528619
An easy way to see the assertion:
pcm.!default {
    type plug
    slave.pcm { type null }
    ttable.0.0 1
}
# aplay -fFLOAT_LE /dev/zero
Playing raw data '/dev/zero' : Float 32 bit Little Endian, Rate 8000 Hz, Mono
aplay: pcm_plug.c:388: snd_pcm_plug_change_channels: Assertion `snd_pcm_format_linear(slv->format)' failed.
Aborted by signal Aborted...

-- 
  Sergey

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2014-06-14 12:11 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-13  8:15 [RFC PATCH] alsactl: Do not run udev rule before datadir is mounted David Henningsson
2014-06-13  8:26 ` Jaroslav Kysela
2014-06-13  9:05   ` David Henningsson
2014-06-13  9:11     ` Jaroslav Kysela
2014-06-13  9:20     ` Takashi Iwai
2014-06-13  9:33       ` David Henningsson
2014-06-13 10:08         ` ALSA 1.0.28 release - request for testing Jaroslav Kysela
2014-06-13 10:52           ` David Henningsson
2014-06-13 17:17             ` Jaroslav Kysela
2014-06-13 10:59           ` Alexander E. Patrakov
2014-06-13 17:19             ` Jaroslav Kysela
2014-06-13 11:02           ` David Henningsson
2014-06-13 17:19             ` Jaroslav Kysela
2014-06-14 12:11           ` ALSA 1.0.28 release - Assertion failed Sergey

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.