[pulseaudio-commits] [SCM] PulseAudio Sound Server branch, stable-queue, updated. v0.9.21-14-g1708127

Lennart Poettering gitmailer-noreply at 0pointer.de
Wed Jan 13 11:31:25 PST 2010


This is an automated email from the git hooks/post-receive script. It was
generated because of a push to the "PulseAudio Sound Server" repository.

The stable-queue branch has been updated
      from  9b37dce4223aaf7a5f48b04b52c89b46ad97cf73 (commit)

- Log -----------------------------------------------------------------
1708127 cpu: check for CMOV flag before using this intsruction in assembly
540ec7b alsa: ignore volume changes from the hw if we are not on the active console
-----------------------------------------------------------------------

Summary of changes:
 src/modules/alsa/alsa-sink.c   |    3 +++
 src/modules/alsa/alsa-source.c |    3 +++
 src/pulsecore/cpu-x86.c        |    6 +++++-
 src/pulsecore/cpu-x86.h        |    6 +++---
 src/pulsecore/svolume_mmx.c    |    2 +-
 5 files changed, 15 insertions(+), 5 deletions(-)

-----------------------------------------------------------------------

commit 540ec7b961256d6c7702448ca995f61268064190
Author: Lennart Poettering <lennart at poettering.net>
Date:   Wed Jan 13 20:30:36 2010 +0100

    alsa: ignore volume changes from the hw if we are not on the active console

diff --git a/src/modules/alsa/alsa-sink.c b/src/modules/alsa/alsa-sink.c
index ed16c83..690480f 100644
--- a/src/modules/alsa/alsa-sink.c
+++ b/src/modules/alsa/alsa-sink.c
@@ -1103,6 +1103,9 @@ static int mixer_callback(snd_mixer_elem_t *elem, unsigned int mask) {
     if (mask == SND_CTL_EVENT_MASK_REMOVE)
         return 0;
 
+    if (u->sink->suspend_cause & PA_SUSPEND_SESSION)
+        return 0;
+
     if (mask & SND_CTL_EVENT_MASK_VALUE) {
         pa_sink_get_volume(u->sink, TRUE);
         pa_sink_get_mute(u->sink, TRUE);
diff --git a/src/modules/alsa/alsa-source.c b/src/modules/alsa/alsa-source.c
index 157698e..f8b583e 100644
--- a/src/modules/alsa/alsa-source.c
+++ b/src/modules/alsa/alsa-source.c
@@ -1051,6 +1051,9 @@ static int mixer_callback(snd_mixer_elem_t *elem, unsigned int mask) {
     if (mask == SND_CTL_EVENT_MASK_REMOVE)
         return 0;
 
+    if (u->source->suspend_cause & PA_SUSPEND_SESSION)
+        return 0;
+
     if (mask & SND_CTL_EVENT_MASK_VALUE) {
         pa_source_get_volume(u->source, TRUE);
         pa_source_get_mute(u->source, TRUE);

commit 170812755e0ac235ed2b7182ef637eb317d8b2b2
Author: Lennart Poettering <lennart at poettering.net>
Date:   Wed Jan 13 20:31:17 2010 +0100

    cpu: check for CMOV flag before using this intsruction in assembly
    
    http://pulseaudio.org/ticket/776

diff --git a/src/pulsecore/cpu-x86.c b/src/pulsecore/cpu-x86.c
index f194a60..b173072 100644
--- a/src/pulsecore/cpu-x86.c
+++ b/src/pulsecore/cpu-x86.c
@@ -57,6 +57,9 @@ void pa_cpu_init_x86 (void) {
     if (level >= 1) {
         get_cpuid (0x00000001, &eax, &ebx, &ecx, &edx);
 
+        if (edx & (1<<15))
+          flags |= PA_CPU_X86_CMOV;
+
         if (edx & (1<<23))
           flags |= PA_CPU_X86_MMX;
 
@@ -97,7 +100,8 @@ void pa_cpu_init_x86 (void) {
           flags |= PA_CPU_X86_3DNOW;
     }
 
-    pa_log_info ("CPU flags: %s%s%s%s%s%s%s%s%s%s",
+    pa_log_info ("CPU flags: %s%s%s%s%s%s%s%s%s%s%s",
+    (flags & PA_CPU_X86_CMOV) ? "CMOV " : "",
     (flags & PA_CPU_X86_MMX) ? "MMX " : "",
     (flags & PA_CPU_X86_SSE) ? "SSE " : "",
     (flags & PA_CPU_X86_SSE2) ? "SSE2 " : "",
diff --git a/src/pulsecore/cpu-x86.h b/src/pulsecore/cpu-x86.h
index b40eb5c..285c203 100644
--- a/src/pulsecore/cpu-x86.h
+++ b/src/pulsecore/cpu-x86.h
@@ -5,7 +5,7 @@
   This file is part of PulseAudio.
 
   Copyright 2004-2006 Lennart Poettering
-  Copyright 2009 Wim Taymans <wim.taymans at collabora.co.uk> 
+  Copyright 2009 Wim Taymans <wim.taymans at collabora.co.uk>
 
   PulseAudio is free software; you can redistribute it and/or modify
   it under the terms of the GNU Lesser General Public License as published
@@ -35,12 +35,12 @@ typedef enum pa_cpu_x86_flag {
     PA_CPU_X86_SSE4_1    = (1 << 6),
     PA_CPU_X86_SSE4_2    = (1 << 7),
     PA_CPU_X86_3DNOW     = (1 << 8),
-    PA_CPU_X86_3DNOWEXT  = (1 << 9)
+    PA_CPU_X86_3DNOWEXT  = (1 << 9),
+    PA_CPU_X86_CMOV      = (1 << 10)
 } pa_cpu_x86_flag_t;
 
 void pa_cpu_init_x86 (void);
 
-
 #if defined (__i386__)
 typedef int32_t pa_reg_x86;
 #define PA_REG_a "eax"
diff --git a/src/pulsecore/svolume_mmx.c b/src/pulsecore/svolume_mmx.c
index 46923ed..e50ebee 100644
--- a/src/pulsecore/svolume_mmx.c
+++ b/src/pulsecore/svolume_mmx.c
@@ -305,7 +305,7 @@ void pa_volume_func_init_mmx (pa_cpu_x86_flag_t flags) {
     run_test ();
 #endif
 
-    if (flags & PA_CPU_X86_MMX) {
+    if ((flags & PA_CPU_X86_MMX) && (flags & PA_CPU_X86_CMOV)) {
         pa_log_info("Initialising MMX optimized functions.");
 
         pa_set_volume_func (PA_SAMPLE_S16NE, (pa_do_volume_func_t) pa_volume_s16ne_mmx);

-- 
hooks/post-receive
PulseAudio Sound Server



More information about the pulseaudio-commits mailing list