lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 21 Mar 2019 18:15:46 -0400
From:   "Cormier, Jonathan" <jcormier@...ticallink.com>
To:     Liam Girdwood <lgirdwood@...il.com>, devicetree@...r.kernel.org
Cc:     Bob Duke <bduke@...ticallink.com>,
        Mike Williamson <michael.williamson@...ticallink.com>,
        Greg Gluszek <greg.gluszek@...ticallink.com>,
        Rob Herring <robh+dt@...nel.org>,
        Mark Brown <broonie@...aro.org>,
        Jaroslav Kysela <perex@...ex.cz>,
        Takashi Iwai <tiwai@...e.com>,
        Peter Ujfalusi <peter.ujfalusi@...com>,
        Jyri Sarha <jsarha@...com>,
        Misael Lopez Cruz <misael.lopez@...com>,
        alsa-devel@...a-project.org, linux-kernel@...r.kernel.org
Subject: [PATCH v2 4/7] ASoC: tlv320aic26: Fix module autoload

Add the missing MODULE_DEVICE_TABLE() for OF and SPI to export
the information so modules have the correct aliases built-in and
autoloading works correctly.

A longer explanation by Javier Canillas can be found here:
https://lkml.org/lkml/2015/7/30/519
https://lkml.org/lkml/2014/9/11/458

Signed-off-by: Cormier, Jonathan <jcormier@...ticallink.com>
---
 sound/soc/codecs/tlv320aic26.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/sound/soc/codecs/tlv320aic26.c b/sound/soc/codecs/tlv320aic26.c
index 5c9b320b918c..db1d1704ae5c 100644
--- a/sound/soc/codecs/tlv320aic26.c
+++ b/sound/soc/codecs/tlv320aic26.c
@@ -368,6 +368,12 @@ static int aic26_spi_probe(struct spi_device *spi)
 	return ret;
 }
 
+static const struct spi_device_id tlv320aic26_id_table[] = {
+	{ "tlv320aic26" },
+	{},
+};
+MODULE_DEVICE_TABLE(spi, tlv320aic26_id_table);
+
 static const struct of_device_id tlv320aic26_of_match[] = {
 	{ .compatible = "ti,tlv320aic26", },
 	{},
@@ -380,6 +386,7 @@ static struct spi_driver aic26_spi = {
 		.of_match_table = of_match_ptr(tlv320aic26_of_match),
 	},
 	.probe = aic26_spi_probe,
+	.id_table = tlv320aic26_id_table,
 };
 
 module_spi_driver(aic26_spi);
-- 
2.21.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ