]> code.delx.au - pulseaudio/blobdiff - src/modules/module-udev-detect.c
volume: Rename 'sync volume' to 'deferred volume'.
[pulseaudio] / src / modules / module-udev-detect.c
index 1eaa84fd537d8d64eed11b8bd0efece27ac602dd..c5312a811446f01049702b7f1b5ec952e046767e 100644 (file)
@@ -46,7 +46,7 @@ PA_MODULE_LOAD_ONCE(TRUE);
 PA_MODULE_USAGE(
         "tsched=<enable system timer based scheduling mode?> "
         "ignore_dB=<ignore dB information from the device?> "
-        "sync_volume=<syncronize sw and hw voluchanges in IO-thread?>");
+        "deferred_volume=<syncronize sw and hw volume changes in IO-thread?>");
 
 struct device {
     char *path;
@@ -63,7 +63,7 @@ struct userdata {
 
     pa_bool_t use_tsched:1;
     pa_bool_t ignore_dB:1;
-    pa_bool_t sync_volume:1;
+    pa_bool_t deferred_volume:1;
 
     struct udev* udev;
     struct udev_monitor *monitor;
@@ -76,7 +76,7 @@ struct userdata {
 static const char* const valid_modargs[] = {
     "tsched",
     "ignore_dB",
-    "sync_volume",
+    "deferred_volume",
     NULL
 };
 
@@ -318,7 +318,7 @@ static void verify_access(struct userdata *u, struct device *d) {
                  * A clean fix would be if we would be able to ignore
                  * our own inotify close events. However, inotify
                  * lacks such functionality. Also, during probing of
-                 * the device we cannot really distuingish between
+                 * the device we cannot really distinguish between
                  * other processes causing EBUSY or ourselves, which
                  * means we have no way to figure out if the probing
                  * during opening was canceled by a "try again"
@@ -389,14 +389,14 @@ static void card_changed(struct userdata *u, struct udev_device *dev) {
                                 "namereg_fail=false "
                                 "tsched=%s "
                                 "ignore_dB=%s "
-                                "sync_volume=%s "
+                                "deferred_volume=%s "
                                 "card_properties=\"module-udev-detect.discovered=1\"",
                                 path_get_card_id(path),
                                 n,
                                 d->card_name,
                                 pa_yes_no(u->use_tsched),
                                 pa_yes_no(u->ignore_dB),
-                                pa_yes_no(u->sync_volume));
+                                pa_yes_no(u->deferred_volume));
     pa_xfree(n);
 
     pa_hashmap_put(u->devices, d->path, d);
@@ -442,8 +442,7 @@ static void process_device(struct userdata *u, struct udev_device *dev) {
 
     if (action && pa_streq(action, "remove"))
         remove_card(u, dev);
-    else if ((!action || pa_streq(action, "change")) &&
-             udev_device_get_property_value(dev, "SOUND_INITIALIZED"))
+    else if ((!action || pa_streq(action, "change")) && udev_device_get_property_value(dev, "SOUND_INITIALIZED"))
         card_changed(u, dev);
 
     /* For an explanation why we don't look for 'add' events here
@@ -666,7 +665,7 @@ int pa__init(pa_module *m) {
     struct udev_enumerate *enumerate = NULL;
     struct udev_list_entry *item = NULL, *first = NULL;
     int fd;
-    pa_bool_t use_tsched = TRUE, ignore_dB = FALSE, sync_volume = m->core->sync_volume;
+    pa_bool_t use_tsched = TRUE, ignore_dB = FALSE, deferred_volume = m->core->deferred_volume;
 
 
     pa_assert(m);
@@ -693,11 +692,11 @@ int pa__init(pa_module *m) {
     }
     u->ignore_dB = ignore_dB;
 
-    if (pa_modargs_get_value_boolean(ma, "sync_volume", &sync_volume) < 0) {
-        pa_log("Failed to parse sync_volume= argument.");
+    if (pa_modargs_get_value_boolean(ma, "deferred_volume", &deferred_volume) < 0) {
+        pa_log("Failed to parse deferred_volume= argument.");
         goto fail;
     }
-    u->sync_volume = sync_volume;
+    u->deferred_volume = deferred_volume;
 
     if (!(u->udev = udev_new())) {
         pa_log("Failed to initialize udev library.");
@@ -722,7 +721,7 @@ int pa__init(pa_module *m) {
         pa_log("Failed to enable monitor: %s", pa_cstrerror(errno));
         if (errno == EPERM)
             pa_log_info("Most likely your kernel is simply too old and "
-                        "allows only priviliged processes to listen to device events. "
+                        "allows only privileged processes to listen to device events. "
                         "Please upgrade your kernel to at least 2.6.30.");
         goto fail;
     }