]> err.no Git - linux-2.6/blobdiff - sound/pci/trident/trident_synth.c
Documentation: correct values in MPC8548E SEC example node
[linux-2.6] / sound / pci / trident / trident_synth.c
index a49682ef3e3e2d69f27dce3255792be2595b8ae0..9b7dee84743bc16b367a71307677ead56d822ed8 100644 (file)
@@ -914,7 +914,9 @@ static int snd_trident_synth_create_port(struct snd_trident * trident, int idx)
                                                   &callbacks,
                                                   SNDRV_SEQ_PORT_CAP_WRITE | SNDRV_SEQ_PORT_CAP_SUBS_WRITE,
                                                   SNDRV_SEQ_PORT_TYPE_DIRECT_SAMPLE |
-                                                  SNDRV_SEQ_PORT_TYPE_SYNTH,
+                                                  SNDRV_SEQ_PORT_TYPE_SYNTH |
+                                                  SNDRV_SEQ_PORT_TYPE_HARDWARE |
+                                                  SNDRV_SEQ_PORT_TYPE_SYNTHESIZER,
                                                   16, 0,
                                                   name);
        if (p->chset->port < 0) {
@@ -934,8 +936,6 @@ static int snd_trident_synth_new_device(struct snd_seq_device *dev)
 {
        struct snd_trident *trident;
        int client, i;
-       struct snd_seq_client_callback callbacks;
-       struct snd_seq_client_info cinfo;
        struct snd_seq_port_subscribe sub;
        struct snd_simple_ops *simpleops;
        char *str;
@@ -947,26 +947,16 @@ static int snd_trident_synth_new_device(struct snd_seq_device *dev)
        trident->synth.seq_client = -1;
 
        /* allocate new client */
-       memset(&callbacks, 0, sizeof(callbacks));
-       callbacks.private_data = trident;
-       callbacks.allow_output = callbacks.allow_input = 1;
-       client = trident->synth.seq_client =
-           snd_seq_create_kernel_client(trident->card, 1, &callbacks);
-       if (client < 0)
-               return client;
-
-       /* change name of client */
-       memset(&cinfo, 0, sizeof(cinfo));
-       cinfo.client = client;
-       cinfo.type = KERNEL_CLIENT;
        str = "???";
        switch (trident->device) {
        case TRIDENT_DEVICE_ID_DX:      str = "Trident 4DWave-DX"; break;
        case TRIDENT_DEVICE_ID_NX:      str = "Trident 4DWave-NX"; break;
        case TRIDENT_DEVICE_ID_SI7018:  str = "SiS 7018"; break;
        }
-       sprintf(cinfo.name, str);
-       snd_seq_kernel_client_ctl(client, SNDRV_SEQ_IOCTL_SET_CLIENT_INFO, &cinfo);
+       client = trident->synth.seq_client =
+               snd_seq_create_kernel_client(trident->card, 1, str);
+       if (client < 0)
+               return client;
 
        for (i = 0; i < 4; i++)
                snd_trident_synth_create_port(trident, i);