~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/sound/soc/fsl/efika-audio-fabric.c

Version: ~ [ linux-6.12-rc7 ] ~ [ linux-6.11.7 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.60 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.116 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.171 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.229 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.285 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.323 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.12 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

Diff markup

Differences between /sound/soc/fsl/efika-audio-fabric.c (Version linux-6.12-rc7) and /sound/soc/fsl/efika-audio-fabric.c (Version linux-4.16.18)


  1 /*                                                  1 /*
  2  * Efika driver for the PSC of the Freescale M      2  * Efika driver for the PSC of the Freescale MPC52xx
  3  * configured as AC97 interface                     3  * configured as AC97 interface
  4  *                                                  4  *
  5  * Copyright 2008 Jon Smirl, Digispeaker            5  * Copyright 2008 Jon Smirl, Digispeaker
  6  * Author: Jon Smirl <jonsmirl@gmail.com>           6  * Author: Jon Smirl <jonsmirl@gmail.com>
  7  *                                                  7  *
  8  * This file is licensed under the terms of th      8  * This file is licensed under the terms of the GNU General Public License
  9  * version 2. This program is licensed "as is"      9  * version 2. This program is licensed "as is" without any warranty of any
 10  * kind, whether express or implied.               10  * kind, whether express or implied.
 11  */                                                11  */
 12                                                    12 
 13 #include <linux/init.h>                            13 #include <linux/init.h>
 14 #include <linux/module.h>                          14 #include <linux/module.h>
 15 #include <linux/interrupt.h>                       15 #include <linux/interrupt.h>
 16 #include <linux/device.h>                          16 #include <linux/device.h>
 17 #include <linux/delay.h>                           17 #include <linux/delay.h>
 18 #include <linux/of.h>                          !!  18 #include <linux/of_device.h>
 19 #include <linux/platform_device.h>             !!  19 #include <linux/of_platform.h>
 20 #include <linux/dma-mapping.h>                     20 #include <linux/dma-mapping.h>
 21                                                    21 
 22 #include <sound/core.h>                            22 #include <sound/core.h>
 23 #include <sound/pcm.h>                             23 #include <sound/pcm.h>
 24 #include <sound/pcm_params.h>                      24 #include <sound/pcm_params.h>
 25 #include <sound/initval.h>                         25 #include <sound/initval.h>
 26 #include <sound/soc.h>                             26 #include <sound/soc.h>
 27                                                    27 
 28 #include "mpc5200_dma.h"                           28 #include "mpc5200_dma.h"
 29                                                    29 
 30 #define DRV_NAME "efika-audio-fabric"              30 #define DRV_NAME "efika-audio-fabric"
 31                                                    31 
 32 SND_SOC_DAILINK_DEFS(analog,                   << 
 33         DAILINK_COMP_ARRAY(COMP_CPU("mpc5200-p << 
 34         DAILINK_COMP_ARRAY(COMP_CODEC("stac976 << 
 35                                       "stac976 << 
 36         DAILINK_COMP_ARRAY(COMP_PLATFORM("mpc5 << 
 37                                                << 
 38 SND_SOC_DAILINK_DEFS(iec958,                   << 
 39         DAILINK_COMP_ARRAY(COMP_CPU("mpc5200-p << 
 40         DAILINK_COMP_ARRAY(COMP_CODEC("stac976 << 
 41                                       "stac976 << 
 42         DAILINK_COMP_ARRAY(COMP_PLATFORM("mpc5 << 
 43                                                << 
 44 static struct snd_soc_dai_link efika_fabric_da     32 static struct snd_soc_dai_link efika_fabric_dai[] = {
 45 {                                                  33 {
 46         .name = "AC97",                            34         .name = "AC97",
 47         .stream_name = "AC97 Analog",              35         .stream_name = "AC97 Analog",
 48         SND_SOC_DAILINK_REG(analog),           !!  36         .codec_dai_name = "stac9766-hifi-analog",
                                                   >>  37         .cpu_dai_name = "mpc5200-psc-ac97.0",
                                                   >>  38         .platform_name = "mpc5200-pcm-audio",
                                                   >>  39         .codec_name = "stac9766-codec",
 49 },                                                 40 },
 50 {                                                  41 {
 51         .name = "AC97",                            42         .name = "AC97",
 52         .stream_name = "AC97 IEC958",              43         .stream_name = "AC97 IEC958",
 53         SND_SOC_DAILINK_REG(iec958),           !!  44         .codec_dai_name = "stac9766-hifi-IEC958",
                                                   >>  45         .cpu_dai_name = "mpc5200-psc-ac97.1",
                                                   >>  46         .platform_name = "mpc5200-pcm-audio",
                                                   >>  47         .codec_name = "stac9766-codec",
 54 },                                                 48 },
 55 };                                                 49 };
 56                                                    50 
 57 static struct snd_soc_card card = {                51 static struct snd_soc_card card = {
 58         .name = "Efika",                           52         .name = "Efika",
 59         .owner = THIS_MODULE,                      53         .owner = THIS_MODULE,
 60         .dai_link = efika_fabric_dai,              54         .dai_link = efika_fabric_dai,
 61         .num_links = ARRAY_SIZE(efika_fabric_d     55         .num_links = ARRAY_SIZE(efika_fabric_dai),
 62 };                                                 56 };
 63                                                    57 
 64 static __init int efika_fabric_init(void)          58 static __init int efika_fabric_init(void)
 65 {                                                  59 {
 66         struct platform_device *pdev;              60         struct platform_device *pdev;
 67         int rc;                                    61         int rc;
 68                                                    62 
 69         if (!of_machine_is_compatible("bplan,e     63         if (!of_machine_is_compatible("bplan,efika"))
 70                 return -ENODEV;                    64                 return -ENODEV;
 71                                                    65 
 72         pdev = platform_device_alloc("soc-audi     66         pdev = platform_device_alloc("soc-audio", 1);
 73         if (!pdev) {                               67         if (!pdev) {
 74                 pr_err("efika_fabric_init: pla     68                 pr_err("efika_fabric_init: platform_device_alloc() failed\n");
 75                 return -ENODEV;                    69                 return -ENODEV;
 76         }                                          70         }
 77                                                    71 
 78         platform_set_drvdata(pdev, &card);         72         platform_set_drvdata(pdev, &card);
 79                                                    73 
 80         rc = platform_device_add(pdev);            74         rc = platform_device_add(pdev);
 81         if (rc) {                                  75         if (rc) {
 82                 pr_err("efika_fabric_init: pla     76                 pr_err("efika_fabric_init: platform_device_add() failed\n");
 83                 platform_device_put(pdev);         77                 platform_device_put(pdev);
 84                 return -ENODEV;                    78                 return -ENODEV;
 85         }                                          79         }
 86         return 0;                                  80         return 0;
 87 }                                                  81 }
 88                                                    82 
 89 module_init(efika_fabric_init);                    83 module_init(efika_fabric_init);
 90                                                    84 
 91                                                    85 
 92 MODULE_AUTHOR("Jon Smirl <jonsmirl@gmail.com>"     86 MODULE_AUTHOR("Jon Smirl <jonsmirl@gmail.com>");
 93 MODULE_DESCRIPTION(DRV_NAME ": mpc5200 Efika f     87 MODULE_DESCRIPTION(DRV_NAME ": mpc5200 Efika fabric driver");
 94 MODULE_LICENSE("GPL");                             88 MODULE_LICENSE("GPL");
 95                                                    89 
 96                                                    90 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php