All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] ASoC: SOF: Remove unused members from struct sof_dev_desc
@ 2021-09-15  6:55 Peter Ujfalusi
  2021-09-15  6:55 ` [PATCH 1/2] ASoC: SOF: intel: Do no initialize resindex_dma_base Peter Ujfalusi
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Peter Ujfalusi @ 2021-09-15  6:55 UTC (permalink / raw)
  To: lgirdwood, broonie, pierre-louis.bossart
  Cc: guennadi.liakhovetski, alsa-devel, daniel.baluta,
	ranjani.sridharan, kai.vehmanen

Hi,

dma_engine, dma_size and resindex_dma_base is unused from sof_dev_desc, drop
them.

resindex_dma_base is initialized to -1 for Intel platforms, but it is not used.

Regards,
Peter
---
Peter Ujfalusi (2):
  ASoC: SOF: intel: Do no initialize resindex_dma_base
  ASoC: SOF: Drop resindex_dma_base, dma_engine, dma_size from
    sof_dev_desc

 include/sound/sof.h           | 5 -----
 sound/soc/sof/intel/pci-apl.c | 2 --
 sound/soc/sof/intel/pci-cnl.c | 3 ---
 sound/soc/sof/intel/pci-icl.c | 2 --
 sound/soc/sof/intel/pci-tgl.c | 5 -----
 sound/soc/sof/intel/pci-tng.c | 1 -
 6 files changed, 18 deletions(-)

-- 
2.33.0


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

* [PATCH 1/2] ASoC: SOF: intel: Do no initialize resindex_dma_base
  2021-09-15  6:55 [PATCH 0/2] ASoC: SOF: Remove unused members from struct sof_dev_desc Peter Ujfalusi
@ 2021-09-15  6:55 ` Peter Ujfalusi
  2021-09-15  6:55 ` [PATCH 2/2] ASoC: SOF: Drop resindex_dma_base, dma_engine, dma_size from sof_dev_desc Peter Ujfalusi
  2021-09-15 15:21 ` [PATCH 0/2] ASoC: SOF: Remove unused members from struct sof_dev_desc Mark Brown
  2 siblings, 0 replies; 4+ messages in thread
From: Peter Ujfalusi @ 2021-09-15  6:55 UTC (permalink / raw)
  To: lgirdwood, broonie, pierre-louis.bossart
  Cc: guennadi.liakhovetski, alsa-devel, daniel.baluta,
	ranjani.sridharan, kai.vehmanen

.resindex_dma_base is not used by the code and in all instances it is set
to -1.
To make it possible to remove it from the sof_dev_desc struct, first remove
all references from the intel drivers (initialization).

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
---
 sound/soc/sof/intel/pci-apl.c | 2 --
 sound/soc/sof/intel/pci-cnl.c | 3 ---
 sound/soc/sof/intel/pci-icl.c | 2 --
 sound/soc/sof/intel/pci-tgl.c | 5 -----
 sound/soc/sof/intel/pci-tng.c | 1 -
 5 files changed, 13 deletions(-)

diff --git a/sound/soc/sof/intel/pci-apl.c b/sound/soc/sof/intel/pci-apl.c
index f89e746c2570..a023b3cc0af4 100644
--- a/sound/soc/sof/intel/pci-apl.c
+++ b/sound/soc/sof/intel/pci-apl.c
@@ -26,7 +26,6 @@ static const struct sof_dev_desc bxt_desc = {
 	.resindex_pcicfg_base	= -1,
 	.resindex_imr_base	= -1,
 	.irqindex_host_ipc	= -1,
-	.resindex_dma_base	= -1,
 	.chip_info = &apl_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
@@ -42,7 +41,6 @@ static const struct sof_dev_desc glk_desc = {
 	.resindex_pcicfg_base	= -1,
 	.resindex_imr_base	= -1,
 	.irqindex_host_ipc	= -1,
-	.resindex_dma_base	= -1,
 	.chip_info = &apl_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
diff --git a/sound/soc/sof/intel/pci-cnl.c b/sound/soc/sof/intel/pci-cnl.c
index f23257adf2ab..40cf1cd00042 100644
--- a/sound/soc/sof/intel/pci-cnl.c
+++ b/sound/soc/sof/intel/pci-cnl.c
@@ -27,7 +27,6 @@ static const struct sof_dev_desc cnl_desc = {
 	.resindex_pcicfg_base	= -1,
 	.resindex_imr_base	= -1,
 	.irqindex_host_ipc	= -1,
-	.resindex_dma_base	= -1,
 	.chip_info = &cnl_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
@@ -44,7 +43,6 @@ static const struct sof_dev_desc cfl_desc = {
 	.resindex_pcicfg_base	= -1,
 	.resindex_imr_base	= -1,
 	.irqindex_host_ipc	= -1,
-	.resindex_dma_base	= -1,
 	.chip_info = &cnl_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
@@ -61,7 +59,6 @@ static const struct sof_dev_desc cml_desc = {
 	.resindex_pcicfg_base	= -1,
 	.resindex_imr_base	= -1,
 	.irqindex_host_ipc	= -1,
-	.resindex_dma_base	= -1,
 	.chip_info = &cnl_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
diff --git a/sound/soc/sof/intel/pci-icl.c b/sound/soc/sof/intel/pci-icl.c
index 2f60c28ae81f..39c84121b313 100644
--- a/sound/soc/sof/intel/pci-icl.c
+++ b/sound/soc/sof/intel/pci-icl.c
@@ -27,7 +27,6 @@ static const struct sof_dev_desc icl_desc = {
 	.resindex_pcicfg_base   = -1,
 	.resindex_imr_base      = -1,
 	.irqindex_host_ipc      = -1,
-	.resindex_dma_base      = -1,
 	.chip_info = &icl_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
@@ -43,7 +42,6 @@ static const struct sof_dev_desc jsl_desc = {
 	.resindex_pcicfg_base   = -1,
 	.resindex_imr_base      = -1,
 	.irqindex_host_ipc      = -1,
-	.resindex_dma_base      = -1,
 	.chip_info = &jsl_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
diff --git a/sound/soc/sof/intel/pci-tgl.c b/sound/soc/sof/intel/pci-tgl.c
index d04ce84fe7cc..f2ea34df9741 100644
--- a/sound/soc/sof/intel/pci-tgl.c
+++ b/sound/soc/sof/intel/pci-tgl.c
@@ -27,7 +27,6 @@ static const struct sof_dev_desc tgl_desc = {
 	.resindex_pcicfg_base   = -1,
 	.resindex_imr_base      = -1,
 	.irqindex_host_ipc      = -1,
-	.resindex_dma_base      = -1,
 	.chip_info = &tgl_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
@@ -44,7 +43,6 @@ static const struct sof_dev_desc tglh_desc = {
 	.resindex_pcicfg_base   = -1,
 	.resindex_imr_base      = -1,
 	.irqindex_host_ipc      = -1,
-	.resindex_dma_base      = -1,
 	.chip_info = &tglh_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
@@ -60,7 +58,6 @@ static const struct sof_dev_desc ehl_desc = {
 	.resindex_pcicfg_base   = -1,
 	.resindex_imr_base      = -1,
 	.irqindex_host_ipc      = -1,
-	.resindex_dma_base      = -1,
 	.chip_info = &ehl_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
@@ -77,7 +74,6 @@ static const struct sof_dev_desc adls_desc = {
 	.resindex_pcicfg_base   = -1,
 	.resindex_imr_base      = -1,
 	.irqindex_host_ipc      = -1,
-	.resindex_dma_base      = -1,
 	.chip_info = &adls_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
@@ -94,7 +90,6 @@ static const struct sof_dev_desc adl_desc = {
 	.resindex_pcicfg_base   = -1,
 	.resindex_imr_base      = -1,
 	.irqindex_host_ipc      = -1,
-	.resindex_dma_base      = -1,
 	.chip_info = &tgl_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
diff --git a/sound/soc/sof/intel/pci-tng.c b/sound/soc/sof/intel/pci-tng.c
index 4bded668b672..2f14082bd0ad 100644
--- a/sound/soc/sof/intel/pci-tng.c
+++ b/sound/soc/sof/intel/pci-tng.c
@@ -201,7 +201,6 @@ static const struct sof_dev_desc tng_desc = {
 	.resindex_pcicfg_base	= -1,
 	.resindex_imr_base	= 0,
 	.irqindex_host_ipc	= -1,
-	.resindex_dma_base	= -1,
 	.chip_info = &tng_chip_info,
 	.default_fw_path = "intel/sof",
 	.default_tplg_path = "intel/sof-tplg",
-- 
2.33.0


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

* [PATCH 2/2] ASoC: SOF: Drop resindex_dma_base, dma_engine, dma_size from sof_dev_desc
  2021-09-15  6:55 [PATCH 0/2] ASoC: SOF: Remove unused members from struct sof_dev_desc Peter Ujfalusi
  2021-09-15  6:55 ` [PATCH 1/2] ASoC: SOF: intel: Do no initialize resindex_dma_base Peter Ujfalusi
@ 2021-09-15  6:55 ` Peter Ujfalusi
  2021-09-15 15:21 ` [PATCH 0/2] ASoC: SOF: Remove unused members from struct sof_dev_desc Mark Brown
  2 siblings, 0 replies; 4+ messages in thread
From: Peter Ujfalusi @ 2021-09-15  6:55 UTC (permalink / raw)
  To: lgirdwood, broonie, pierre-louis.bossart
  Cc: guennadi.liakhovetski, alsa-devel, daniel.baluta,
	ranjani.sridharan, kai.vehmanen

resindex_dma_base, dma_engine and dma_size is unused, remove them.
There is no hint in the comments how this supposed to be used, when the
need arises it can be added back.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
---
 include/sound/sof.h | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/include/sound/sof.h b/include/sound/sof.h
index 6a1cd8e783d8..23b374311d16 100644
--- a/include/sound/sof.h
+++ b/include/sound/sof.h
@@ -74,11 +74,6 @@ struct sof_dev_desc {
 	int resindex_pcicfg_base;
 	int resindex_imr_base;
 	int irqindex_host_ipc;
-	int resindex_dma_base;
-
-	/* DMA only valid when resindex_dma_base != -1*/
-	int dma_engine;
-	int dma_size;
 
 	/* IPC timeouts in ms */
 	int ipc_timeout;
-- 
2.33.0


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

* Re: [PATCH 0/2] ASoC: SOF: Remove unused members from struct sof_dev_desc
  2021-09-15  6:55 [PATCH 0/2] ASoC: SOF: Remove unused members from struct sof_dev_desc Peter Ujfalusi
  2021-09-15  6:55 ` [PATCH 1/2] ASoC: SOF: intel: Do no initialize resindex_dma_base Peter Ujfalusi
  2021-09-15  6:55 ` [PATCH 2/2] ASoC: SOF: Drop resindex_dma_base, dma_engine, dma_size from sof_dev_desc Peter Ujfalusi
@ 2021-09-15 15:21 ` Mark Brown
  2 siblings, 0 replies; 4+ messages in thread
From: Mark Brown @ 2021-09-15 15:21 UTC (permalink / raw)
  To: pierre-louis.bossart, lgirdwood, Peter Ujfalusi
  Cc: guennadi.liakhovetski, alsa-devel, kai.vehmanen,
	ranjani.sridharan, Mark Brown, daniel.baluta

On Wed, 15 Sep 2021 09:55:39 +0300, Peter Ujfalusi wrote:
> dma_engine, dma_size and resindex_dma_base is unused from sof_dev_desc, drop
> them.
> 
> resindex_dma_base is initialized to -1 for Intel platforms, but it is not used.
> 
> Regards,
> Peter
> 
> [...]

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/2] ASoC: SOF: intel: Do no initialize resindex_dma_base
      commit: 7e7d5ffa37e34ec2a6e8aa2e1fd846fb296fc8a1
[2/2] ASoC: SOF: Drop resindex_dma_base, dma_engine, dma_size from sof_dev_desc
      commit: 2395fea7ae7f0cf6dfd37a8bb3cd9dbcf2d0e492

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

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

end of thread, other threads:[~2021-09-15 15:25 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-15  6:55 [PATCH 0/2] ASoC: SOF: Remove unused members from struct sof_dev_desc Peter Ujfalusi
2021-09-15  6:55 ` [PATCH 1/2] ASoC: SOF: intel: Do no initialize resindex_dma_base Peter Ujfalusi
2021-09-15  6:55 ` [PATCH 2/2] ASoC: SOF: Drop resindex_dma_base, dma_engine, dma_size from sof_dev_desc Peter Ujfalusi
2021-09-15 15:21 ` [PATCH 0/2] ASoC: SOF: Remove unused members from struct sof_dev_desc Mark Brown

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.