mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 00/15] constify pnp_device_id and pnp_card_device_id
@ 2017-08-17 10:06 Arvind Yadav
  2017-08-17 10:06 ` [PATCH 01/15] ALSA: drivers: mpu401: constify pnp_device_id Arvind Yadav
                   ` (15 more replies)
  0 siblings, 16 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

*_device_id are not supposed to change at runtime. All functions
working with *_device_id provided by <linux/pnp.h> work with
const *_device_id. So mark the non-const structs as const.

Arvind Yadav (15):
  [PATCH 01/15] ALSA: drivers: mpu401: constify pnp_device_id
  [PATCH 02/15] ALSA: es18xx: constify pnp_device_id and pnp_card_device_id
  [PATCH 03/15] ALSA: opl3sa2: constify pnp_device_id and pnp_card_device_id
  [PATCH 04/15] ALSA: ad1816a: constify pnp_card_device_id
  [PATCH 05/15] ALSA: als100: constify pnp_card_device_id
  [PATCH 06/15] ALSA: azt2320: constify pnp_card_device_id
  [PATCH 07/15] ALSA: cmi8330: constify pnp_card_device_id
  [PATCH 08/15] ALSA: cs4236: constify pnp_card_device_id
  [PATCH 09/15] ALSA: es1688: constify pnp_card_device_id
  [PATCH 10/15] ALSA: gus: constify pnp_card_device_id
  [PATCH 11/15] ALSA: msnd: constify pnp_card_device_id
  [PATCH 12/15] ALSA: opti9xx: constify pnp_card_device_id
  [PATCH 13/15] ALSA: sb16: constify pnp_card_device_id
  [PATCH 14/15] ALSA: sscape: constify pnp_card_device_id
  [PATCH 15/15] ALSA: wavefront: constify pnp_card_device_id

 sound/drivers/mpu401/mpu401.c      | 2 +-
 sound/isa/ad1816a/ad1816a.c        | 2 +-
 sound/isa/als100.c                 | 2 +-
 sound/isa/azt2320.c                | 2 +-
 sound/isa/cmi8330.c                | 2 +-
 sound/isa/cs423x/cs4236.c          | 2 +-
 sound/isa/es1688/es1688.c          | 2 +-
 sound/isa/es18xx.c                 | 4 ++--
 sound/isa/gus/interwave.c          | 2 +-
 sound/isa/msnd/msnd_pinnacle.c     | 2 +-
 sound/isa/opl3sa2.c                | 4 ++--
 sound/isa/opti9xx/miro.c           | 2 +-
 sound/isa/opti9xx/opti92x-ad1848.c | 2 +-
 sound/isa/sb/sb16.c                | 2 +-
 sound/isa/sscape.c                 | 2 +-
 sound/isa/wavefront/wavefront.c    | 2 +-
 16 files changed, 18 insertions(+), 18 deletions(-)

-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 01/15] ALSA: drivers: mpu401: constify pnp_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 02/15] ALSA: es18xx: constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (14 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_device_id are not supposed to change at runtime. All functions
working with pnp_device_id provided by <linux/pnp.h> work with
const pnp_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/drivers/mpu401/mpu401.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/drivers/mpu401/mpu401.c b/sound/drivers/mpu401/mpu401.c
index 9b86e00..b671576 100644
--- a/sound/drivers/mpu401/mpu401.c
+++ b/sound/drivers/mpu401/mpu401.c
@@ -148,7 +148,7 @@ static struct platform_driver snd_mpu401_driver = {
 
 #define IO_EXTENT 2
 
-static struct pnp_device_id snd_mpu401_pnpids[] = {
+static const struct pnp_device_id snd_mpu401_pnpids[] = {
 	{ .id = "PNPb006" },
 	{ .id = "" }
 };
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 02/15] ALSA: es18xx: constify pnp_device_id and pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
  2017-08-17 10:06 ` [PATCH 01/15] ALSA: drivers: mpu401: constify pnp_device_id Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 03/15] ALSA: opl3sa2: " Arvind Yadav
                   ` (13 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

*_device_id are not supposed to change at runtime. All functions
working with *_device_id provided by <linux/pnp.h> work with
const *_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/es18xx.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sound/isa/es18xx.c b/sound/isa/es18xx.c
index ae17a65..5d4a30a 100644
--- a/sound/isa/es18xx.c
+++ b/sound/isa/es18xx.c
@@ -2017,7 +2017,7 @@ static int isa_registered;
 static int pnp_registered;
 static int pnpc_registered;
 
-static struct pnp_device_id snd_audiodrive_pnpbiosids[] = {
+static const struct pnp_device_id snd_audiodrive_pnpbiosids[] = {
 	{ .id = "ESS1869" },
 	{ .id = "ESS1879" },
 	{ .id = "" }		/* end */
@@ -2062,7 +2062,7 @@ static int snd_audiodrive_pnp(int dev, struct snd_es18xx *chip,
 	return 0;
 }
 
-static struct pnp_card_device_id snd_audiodrive_pnpids[] = {
+static const struct pnp_card_device_id snd_audiodrive_pnpids[] = {
 	/* ESS 1868 (integrated on Compaq dual P-Pro motherboard and Genius 18PnP 3D) */
 	{ .id = "ESS1868", .devs = { { "ESS1868" }, { "ESS0000" } } },
 	/* ESS 1868 (integrated on Maxisound Cards) */
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 03/15] ALSA: opl3sa2: constify pnp_device_id and pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
  2017-08-17 10:06 ` [PATCH 01/15] ALSA: drivers: mpu401: constify pnp_device_id Arvind Yadav
  2017-08-17 10:06 ` [PATCH 02/15] ALSA: es18xx: constify pnp_device_id and pnp_card_device_id Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 04/15] ALSA: ad1816a: constify pnp_card_device_id Arvind Yadav
                   ` (12 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

*_device_id are not supposed to change at runtime. All functions
working with *_device_id provided by <linux/pnp.h> work with
const *_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/opl3sa2.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sound/isa/opl3sa2.c b/sound/isa/opl3sa2.c
index 4098e3e0..7cce4cd 100644
--- a/sound/isa/opl3sa2.c
+++ b/sound/isa/opl3sa2.c
@@ -141,7 +141,7 @@ struct snd_opl3sa2 {
 
 #ifdef CONFIG_PNP
 
-static struct pnp_device_id snd_opl3sa2_pnpbiosids[] = {
+static const struct pnp_device_id snd_opl3sa2_pnpbiosids[] = {
 	{ .id = "YMH0021" },
 	{ .id = "NMX2210" },	/* Gateway Solo 2500 */
 	{ .id = "" }		/* end */
@@ -149,7 +149,7 @@ static struct pnp_device_id snd_opl3sa2_pnpbiosids[] = {
 
 MODULE_DEVICE_TABLE(pnp, snd_opl3sa2_pnpbiosids);
 
-static struct pnp_card_device_id snd_opl3sa2_pnpids[] = {
+static const struct pnp_card_device_id snd_opl3sa2_pnpids[] = {
 	/* Yamaha YMF719E-S (Genius Sound Maker 3DX) */
 	{ .id = "YMH0020", .devs = { { "YMH0021" } } },
 	/* Yamaha OPL3-SA3 (integrated on Intel's Pentium II AL440LX motherboard) */
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 04/15] ALSA: ad1816a: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (2 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 03/15] ALSA: opl3sa2: " Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 05/15] ALSA: als100: " Arvind Yadav
                   ` (11 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/ad1816a/ad1816a.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/isa/ad1816a/ad1816a.c b/sound/isa/ad1816a/ad1816a.c
index 7692265..4be6c12 100644
--- a/sound/isa/ad1816a/ad1816a.c
+++ b/sound/isa/ad1816a/ad1816a.c
@@ -63,7 +63,7 @@ MODULE_PARM_DESC(enable, "Enable ad1816a based soundcard.");
 module_param_array(clockfreq, int, NULL, 0444);
 MODULE_PARM_DESC(clockfreq, "Clock frequency for ad1816a driver (default = 0).");
 
-static struct pnp_card_device_id snd_ad1816a_pnpids[] = {
+static const struct pnp_card_device_id snd_ad1816a_pnpids[] = {
 	/* Analog Devices AD1815 */
 	{ .id = "ADS7150", .devs = { { .id = "ADS7150" }, { .id = "ADS7151" } } },
 	/* Analog Device AD1816? */
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 05/15] ALSA: als100: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (3 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 04/15] ALSA: ad1816a: constify pnp_card_device_id Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 06/15] ALSA: azt2320: " Arvind Yadav
                   ` (10 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/als100.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/isa/als100.c b/sound/isa/als100.c
index bc9ea30..dde6ba4 100644
--- a/sound/isa/als100.c
+++ b/sound/isa/als100.c
@@ -79,7 +79,7 @@ struct snd_card_als100 {
 	struct snd_sb *chip;
 };
 
-static struct pnp_card_device_id snd_als100_pnpids[] = {
+static const struct pnp_card_device_id snd_als100_pnpids[] = {
 	/* DT197A30 */
 	{ .id = "RWB1688",
 	  .devs = { { "@@@0001" }, { "@X@0001" }, { "@H@0001" } },
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 06/15] ALSA: azt2320: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (4 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 05/15] ALSA: als100: " Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 07/15] ALSA: cmi8330: " Arvind Yadav
                   ` (9 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/azt2320.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/isa/azt2320.c b/sound/isa/azt2320.c
index fff186f..4e6fad4 100644
--- a/sound/isa/azt2320.c
+++ b/sound/isa/azt2320.c
@@ -79,7 +79,7 @@ struct snd_card_azt2320 {
 	struct snd_wss *chip;
 };
 
-static struct pnp_card_device_id snd_azt2320_pnpids[] = {
+static const struct pnp_card_device_id snd_azt2320_pnpids[] = {
 	/* PRO16V */
 	{ .id = "AZT1008", .devs = { { "AZT1008" }, { "AZT2001" }, } },
 	/* Aztech Sound Galaxy 16 */
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 07/15] ALSA: cmi8330: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (5 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 06/15] ALSA: azt2320: " Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 08/15] ALSA: cs4236: " Arvind Yadav
                   ` (8 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/cmi8330.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/isa/cmi8330.c b/sound/isa/cmi8330.c
index f64b29a..6b8c469 100644
--- a/sound/isa/cmi8330.c
+++ b/sound/isa/cmi8330.c
@@ -182,7 +182,7 @@ struct snd_cmi8330 {
 
 #ifdef CONFIG_PNP
 
-static struct pnp_card_device_id snd_cmi8330_pnpids[] = {
+static const struct pnp_card_device_id snd_cmi8330_pnpids[] = {
 	{ .id = "CMI0001", .devs = { { "@X@0001" }, { "@@@0001" }, { "@H@0001" }, { "A@@0001" } } },
 	{ .id = "CMI0001", .devs = { { "@@@0001" }, { "@X@0001" }, { "@H@0001" } } },
 	{ .id = "" }
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 08/15] ALSA: cs4236: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (6 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 07/15] ALSA: cmi8330: " Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 09/15] ALSA: es1688: " Arvind Yadav
                   ` (7 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/cs423x/cs4236.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/isa/cs423x/cs4236.c b/sound/isa/cs423x/cs4236.c
index 1f9a3b2..14bba64 100644
--- a/sound/isa/cs423x/cs4236.c
+++ b/sound/isa/cs423x/cs4236.c
@@ -149,7 +149,7 @@ static const struct pnp_device_id snd_cs423x_pnpbiosids[] = {
 MODULE_DEVICE_TABLE(pnp, snd_cs423x_pnpbiosids);
 
 #define CS423X_ISAPNP_DRIVER	"cs4232_isapnp"
-static struct pnp_card_device_id snd_cs423x_pnpids[] = {
+static const struct pnp_card_device_id snd_cs423x_pnpids[] = {
 	/* Philips PCA70PS */
 	{ .id = "CSC0d32", .devs = { { "CSC0000" }, { "CSC0010" }, { "PNPb006" } } },
 	/* TerraTec Maestro 32/96 (CS4232) */
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 09/15] ALSA: es1688: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (7 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 08/15] ALSA: cs4236: " Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 10/15] ALSA: gus: " Arvind Yadav
                   ` (6 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/es1688/es1688.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/isa/es1688/es1688.c b/sound/isa/es1688/es1688.c
index 36320e7..a826c13 100644
--- a/sound/isa/es1688/es1688.c
+++ b/sound/isa/es1688/es1688.c
@@ -321,7 +321,7 @@ static int snd_es968_pnp_resume(struct pnp_card_link *pcard)
 }
 #endif
 
-static struct pnp_card_device_id snd_es968_pnpids[] = {
+static const struct pnp_card_device_id snd_es968_pnpids[] = {
 	{ .id = "ESS0968", .devs = { { "@@@0968" }, } },
 	{ .id = "ESS0968", .devs = { { "ESS0968" }, } },
 	{ .id = "", } /* end */
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 10/15] ALSA: gus: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (8 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 09/15] ALSA: es1688: " Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 11/15] ALSA: msnd: " Arvind Yadav
                   ` (5 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/gus/interwave.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/isa/gus/interwave.c b/sound/isa/gus/interwave.c
index 0687b7e..a6fc26b 100644
--- a/sound/isa/gus/interwave.c
+++ b/sound/isa/gus/interwave.c
@@ -136,7 +136,7 @@ struct snd_interwave {
 static int isa_registered;
 static int pnp_registered;
 
-static struct pnp_card_device_id snd_interwave_pnpids[] = {
+static const struct pnp_card_device_id snd_interwave_pnpids[] = {
 #ifndef SNDRV_STB
 	/* Gravis UltraSound Plug & Play */
 	{ .id = "GRV0001", .devs = { { .id = "GRV0000" } } },
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 11/15] ALSA: msnd: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (9 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 10/15] ALSA: gus: " Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 12/15] ALSA: opti9xx: " Arvind Yadav
                   ` (4 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/msnd/msnd_pinnacle.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/isa/msnd/msnd_pinnacle.c b/sound/isa/msnd/msnd_pinnacle.c
index ad48973..86db009 100644
--- a/sound/isa/msnd/msnd_pinnacle.c
+++ b/sound/isa/msnd/msnd_pinnacle.c
@@ -1191,7 +1191,7 @@ static void snd_msnd_pnp_remove(struct pnp_card_link *pcard)
 static int isa_registered;
 static int pnp_registered;
 
-static struct pnp_card_device_id msnd_pnpids[] = {
+static const struct pnp_card_device_id msnd_pnpids[] = {
 	/* Pinnacle PnP */
 	{ .id = "BVJ0440", .devs = { { "TBS0000" }, { "TBS0001" } } },
 	{ .id = "" }	/* end */
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 12/15] ALSA: opti9xx: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (10 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 11/15] ALSA: msnd: " Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 13/15] ALSA: sb16: " Arvind Yadav
                   ` (3 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/opti9xx/miro.c           | 2 +-
 sound/isa/opti9xx/opti92x-ad1848.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/sound/isa/opti9xx/miro.c b/sound/isa/opti9xx/miro.c
index bcbff56..3f760b3 100644
--- a/sound/isa/opti9xx/miro.c
+++ b/sound/isa/opti9xx/miro.c
@@ -143,7 +143,7 @@ static int snd_miro_pnp_is_probed;
 
 #ifdef CONFIG_PNP
 
-static struct pnp_card_device_id snd_miro_pnpids[] = {
+static const struct pnp_card_device_id snd_miro_pnpids[] = {
 	/* PCM20 and PCM12 in PnP mode */
 	{ .id = "MIR0924",
 	  .devs = { { "MIR0000" }, { "MIR0002" }, { "MIR0005" } }, },
diff --git a/sound/isa/opti9xx/opti92x-ad1848.c b/sound/isa/opti9xx/opti92x-ad1848.c
index ceddb39..040f06f 100644
--- a/sound/isa/opti9xx/opti92x-ad1848.c
+++ b/sound/isa/opti9xx/opti92x-ad1848.c
@@ -151,7 +151,7 @@ static int snd_opti9xx_pnp_is_probed;
 
 #ifdef CONFIG_PNP
 
-static struct pnp_card_device_id snd_opti9xx_pnpids[] = {
+static const struct pnp_card_device_id snd_opti9xx_pnpids[] = {
 #ifndef OPTi93X
 	/* OPTi 82C924 */
 	{ .id = "OPT0924",
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 13/15] ALSA: sb16: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (11 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 12/15] ALSA: opti9xx: " Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 14/15] ALSA: sscape: " Arvind Yadav
                   ` (2 subsequent siblings)
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/sb/sb16.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/isa/sb/sb16.c b/sound/isa/sb/sb16.c
index 917a93d..8f9ebeb 100644
--- a/sound/isa/sb/sb16.c
+++ b/sound/isa/sb/sb16.c
@@ -145,7 +145,7 @@ struct snd_card_sb16 {
 
 #ifdef CONFIG_PNP
 
-static struct pnp_card_device_id snd_sb16_pnpids[] = {
+static const struct pnp_card_device_id snd_sb16_pnpids[] = {
 #ifndef SNDRV_SBAWE
 	/* Sound Blaster 16 PnP */
 	{ .id = "CTL0024", .devs = { { "CTL0031" } } },
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 14/15] ALSA: sscape: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (12 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 13/15] ALSA: sb16: " Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:06 ` [PATCH 15/15] ALSA: wavefront: " Arvind Yadav
  2017-08-17 10:48 ` [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Takashi Iwai
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/sscape.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/isa/sscape.c b/sound/isa/sscape.c
index 1cd2908..733adee 100644
--- a/sound/isa/sscape.c
+++ b/sound/isa/sscape.c
@@ -88,7 +88,7 @@ MODULE_PARM_DESC(joystick, "Enable gameport.");
 static int isa_registered;
 static int pnp_registered;
 
-static struct pnp_card_device_id sscape_pnpids[] = {
+static const struct pnp_card_device_id sscape_pnpids[] = {
 	{ .id = "ENS3081", .devs = { { "ENS0000" } } }, /* Soundscape PnP */
 	{ .id = "ENS4081", .devs = { { "ENS1011" } } },	/* VIVO90 */
 	{ .id = "" }	/* end */
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* [PATCH 15/15] ALSA: wavefront: constify pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (13 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 14/15] ALSA: sscape: " Arvind Yadav
@ 2017-08-17 10:06 ` Arvind Yadav
  2017-08-17 10:48 ` [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Takashi Iwai
  15 siblings, 0 replies; 17+ messages in thread
From: Arvind Yadav @ 2017-08-17 10:06 UTC (permalink / raw)
  To: perex, tiwai, dhowells; +Cc: linux-kernel, alsa-devel

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 sound/isa/wavefront/wavefront.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/isa/wavefront/wavefront.c b/sound/isa/wavefront/wavefront.c
index da4e9a8..b1989fa 100644
--- a/sound/isa/wavefront/wavefront.c
+++ b/sound/isa/wavefront/wavefront.c
@@ -88,7 +88,7 @@ MODULE_PARM_DESC(use_cs4232_midi, "Use CS4232 MPU-401 interface (inaccessibly lo
 static int isa_registered;
 static int pnp_registered;
 
-static struct pnp_card_device_id snd_wavefront_pnpids[] = {
+static const struct pnp_card_device_id snd_wavefront_pnpids[] = {
 	/* Tropez */
 	{ .id = "CSC7532", .devs = { { "CSC0000" }, { "CSC0010" }, { "PnPb006" }, { "CSC0004" } } },
 	/* Tropez+ */
-- 
2.7.4

^ permalink raw reply	[flat|nested] 17+ messages in thread

* Re: [PATCH 00/15] constify pnp_device_id and pnp_card_device_id
  2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
                   ` (14 preceding siblings ...)
  2017-08-17 10:06 ` [PATCH 15/15] ALSA: wavefront: " Arvind Yadav
@ 2017-08-17 10:48 ` Takashi Iwai
  15 siblings, 0 replies; 17+ messages in thread
From: Takashi Iwai @ 2017-08-17 10:48 UTC (permalink / raw)
  To: Arvind Yadav; +Cc: perex, dhowells, alsa-devel, linux-kernel

On Thu, 17 Aug 2017 12:06:15 +0200,
Arvind Yadav wrote:
> 
> *_device_id are not supposed to change at runtime. All functions
> working with *_device_id provided by <linux/pnp.h> work with
> const *_device_id. So mark the non-const structs as const.
> 
> Arvind Yadav (15):
>   [PATCH 01/15] ALSA: drivers: mpu401: constify pnp_device_id
>   [PATCH 02/15] ALSA: es18xx: constify pnp_device_id and pnp_card_device_id
>   [PATCH 03/15] ALSA: opl3sa2: constify pnp_device_id and pnp_card_device_id
>   [PATCH 04/15] ALSA: ad1816a: constify pnp_card_device_id
>   [PATCH 05/15] ALSA: als100: constify pnp_card_device_id
>   [PATCH 06/15] ALSA: azt2320: constify pnp_card_device_id
>   [PATCH 07/15] ALSA: cmi8330: constify pnp_card_device_id
>   [PATCH 08/15] ALSA: cs4236: constify pnp_card_device_id
>   [PATCH 09/15] ALSA: es1688: constify pnp_card_device_id
>   [PATCH 10/15] ALSA: gus: constify pnp_card_device_id
>   [PATCH 11/15] ALSA: msnd: constify pnp_card_device_id
>   [PATCH 12/15] ALSA: opti9xx: constify pnp_card_device_id
>   [PATCH 13/15] ALSA: sb16: constify pnp_card_device_id
>   [PATCH 14/15] ALSA: sscape: constify pnp_card_device_id
>   [PATCH 15/15] ALSA: wavefront: constify pnp_card_device_id

Applied all patches now.  Thanks.


Takashi

^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2017-08-17 10:48 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-17 10:06 [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Arvind Yadav
2017-08-17 10:06 ` [PATCH 01/15] ALSA: drivers: mpu401: constify pnp_device_id Arvind Yadav
2017-08-17 10:06 ` [PATCH 02/15] ALSA: es18xx: constify pnp_device_id and pnp_card_device_id Arvind Yadav
2017-08-17 10:06 ` [PATCH 03/15] ALSA: opl3sa2: " Arvind Yadav
2017-08-17 10:06 ` [PATCH 04/15] ALSA: ad1816a: constify pnp_card_device_id Arvind Yadav
2017-08-17 10:06 ` [PATCH 05/15] ALSA: als100: " Arvind Yadav
2017-08-17 10:06 ` [PATCH 06/15] ALSA: azt2320: " Arvind Yadav
2017-08-17 10:06 ` [PATCH 07/15] ALSA: cmi8330: " Arvind Yadav
2017-08-17 10:06 ` [PATCH 08/15] ALSA: cs4236: " Arvind Yadav
2017-08-17 10:06 ` [PATCH 09/15] ALSA: es1688: " Arvind Yadav
2017-08-17 10:06 ` [PATCH 10/15] ALSA: gus: " Arvind Yadav
2017-08-17 10:06 ` [PATCH 11/15] ALSA: msnd: " Arvind Yadav
2017-08-17 10:06 ` [PATCH 12/15] ALSA: opti9xx: " Arvind Yadav
2017-08-17 10:06 ` [PATCH 13/15] ALSA: sb16: " Arvind Yadav
2017-08-17 10:06 ` [PATCH 14/15] ALSA: sscape: " Arvind Yadav
2017-08-17 10:06 ` [PATCH 15/15] ALSA: wavefront: " Arvind Yadav
2017-08-17 10:48 ` [PATCH 00/15] constify pnp_device_id and pnp_card_device_id Takashi Iwai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome