linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/15] Clean-up MMC's W=1 build warnings
@ 2020-07-01 12:46 Lee Jones
  2020-07-01 12:46 ` [PATCH 01/15] mmc: core: quirks: Mark fixups as __maybe_unused Lee Jones
                   ` (15 more replies)
  0 siblings, 16 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson; +Cc: linux-arm-kernel, linux-kernel, Lee Jones

This set is part of a larger effort attempting to clean-up W=1
kernel builds, which are currently overwhelmingly riddled with
niggly little warnings.

After these patches are applied, the build system no longer
complains about any W=0 nor W=1 level warnings in drivers/mmc.

Hurrah!

Lee Jones (15):
  mmc: core: quirks: Mark fixups as __maybe_unused
  mmc: core: sdio_io: Provide description for sdio_set_host_pm_flags()'s
    'flag' arg
  mmc: core: regulator: Add missing documetation for 'mmc' and 'ios'
  mmc: host: sdhci-s3c: Provide documentation for missing struct
    properties
  mmc: host: mtk-sd: Demote msdc_recheck_sdio_irq() function header
  mmc: host: atmel-mci: Provide 2 new and correct 1 existing property
    description
  mmc: core: queue: Correct misspelling of 'mq' in mmc_init_request()'s
    docs
  mmc: host: dw_mmc-exynos: Add kerneldoc descriptions of for 'dev' args
  mmc: host: rtsx_pci_sdmmc: Remove set but unused variable 'err'
  mmc: host: rtsx_usb_sdmmc: Remove set but unused variable 'err'
  mmc: host: sdhci-of-arasan: Correct formatting and provide missing
    function arg(s)
  mmc: host: sdhci-msm: Staticify local function
    sdhci_msm_dump_vendor_regs()
  mmc: host: sdhci-msm: Demote faux kerneldoc header down to basic
    comment block
  mmc: host: cqhci: Demote faux kerneldoc header down to basic comment
    block
  mmc: host: sdhci-iproc: Tell the compiler that ACPI functions may not
    be used

 drivers/mmc/core/queue.c           | 2 +-
 drivers/mmc/core/quirks.h          | 6 +++---
 drivers/mmc/core/regulator.c       | 2 ++
 drivers/mmc/core/sdio_io.c         | 1 +
 drivers/mmc/host/atmel-mci.c       | 4 +++-
 drivers/mmc/host/cqhci.c           | 2 +-
 drivers/mmc/host/dw_mmc-exynos.c   | 2 ++
 drivers/mmc/host/mtk-sd.c          | 3 +--
 drivers/mmc/host/rtsx_pci_sdmmc.c  | 4 ++--
 drivers/mmc/host/rtsx_usb_sdmmc.c  | 5 ++---
 drivers/mmc/host/sdhci-iproc.c     | 2 +-
 drivers/mmc/host/sdhci-msm.c       | 4 ++--
 drivers/mmc/host/sdhci-of-arasan.c | 3 ++-
 drivers/mmc/host/sdhci-s3c.c       | 4 ++++
 14 files changed, 27 insertions(+), 17 deletions(-)

-- 
2.25.1


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

* [PATCH 01/15] mmc: core: quirks: Mark fixups as __maybe_unused
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-01 12:46 ` [PATCH 02/15] mmc: core: sdio_io: Provide description for sdio_set_host_pm_flags()'s 'flag' arg Lee Jones
                   ` (14 subsequent siblings)
  15 siblings, 0 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Lee Jones, Andrei Warkentin,
	Martin Mares

Not all source files which include quirks.h make use of the all of
the available fixup information.  When this happens the compiler
complains that some constant variables are defined by never used.
We can fix this by telling the compiler that this intentional by
simply marking them as __maybe_unused.

Fixes the following W=1 kernel build warnings:

 In file included from drivers/mmc/core/sdio.c:22:
 drivers/mmc/core/quirks.h:105:31: warning: ‘mmc_ext_csd_fixups’ defined but not used [-Wunused-const-variable=]
 105 | static const struct mmc_fixup mmc_ext_csd_fixups[] = {
 | ^~~~~~~~~~~~~~~~~~
 drivers/mmc/core/quirks.h:17:31: warning: ‘mmc_blk_fixups’ defined but not used [-Wunused-const-variable=]
 17 | static const struct mmc_fixup mmc_blk_fixups[] = {
 | ^~~~~~~~~~~~~~
 In file included from drivers/mmc/core/mmc.c:25:
 drivers/mmc/core/quirks.h:123:31: warning: ‘sdio_fixup_methods’ defined but not used [-Wunused-const-variable=]
 123 | static const struct mmc_fixup sdio_fixup_methods[] = {
 | ^~~~~~~~~~~~~~~~~~
 drivers/mmc/core/quirks.h:17:31: warning: ‘mmc_blk_fixups’ defined but not used [-Wunused-const-variable=]
 17 | static const struct mmc_fixup mmc_blk_fixups[] = {
 | ^~~~~~~~~~~~~~

Cc: Andrei Warkentin <andreiw@motorola.com>
Cc: Martin Mares <mj@ucw.cz>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/core/quirks.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/mmc/core/quirks.h b/drivers/mmc/core/quirks.h
index 472fa2fdcf139..d68e6e513a4f4 100644
--- a/drivers/mmc/core/quirks.h
+++ b/drivers/mmc/core/quirks.h
@@ -14,7 +14,7 @@
 
 #include "card.h"
 
-static const struct mmc_fixup mmc_blk_fixups[] = {
+static const struct mmc_fixup __maybe_unused mmc_blk_fixups[] = {
 #define INAND_CMD38_ARG_EXT_CSD  113
 #define INAND_CMD38_ARG_ERASE    0x00
 #define INAND_CMD38_ARG_TRIM     0x01
@@ -102,7 +102,7 @@ static const struct mmc_fixup mmc_blk_fixups[] = {
 	END_FIXUP
 };
 
-static const struct mmc_fixup mmc_ext_csd_fixups[] = {
+static const struct mmc_fixup __maybe_unused mmc_ext_csd_fixups[] = {
 	/*
 	 * Certain Hynix eMMC 4.41 cards might get broken when HPI feature
 	 * is used so disable the HPI feature for such buggy cards.
@@ -120,7 +120,7 @@ static const struct mmc_fixup mmc_ext_csd_fixups[] = {
 };
 
 
-static const struct mmc_fixup sdio_fixup_methods[] = {
+static const struct mmc_fixup __maybe_unused sdio_fixup_methods[] = {
 	SDIO_FIXUP(SDIO_VENDOR_ID_TI_WL1251, SDIO_DEVICE_ID_TI_WL1251,
 		   add_quirk, MMC_QUIRK_NONSTD_FUNC_IF),
 
-- 
2.25.1


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

* [PATCH 02/15] mmc: core: sdio_io: Provide description for sdio_set_host_pm_flags()'s 'flag' arg
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
  2020-07-01 12:46 ` [PATCH 01/15] mmc: core: quirks: Mark fixups as __maybe_unused Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-01 12:46 ` [PATCH 03/15] mmc: core: regulator: Add missing documetation for 'mmc' and 'ios' Lee Jones
                   ` (13 subsequent siblings)
  15 siblings, 0 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson; +Cc: linux-arm-kernel, linux-kernel, Lee Jones, Pierre Ossman

Add missing kerneldoc entry for sdio_set_host_pm_flags()'s 'flag'
function argument.

Fixes the following W=1 kernel build warning:

 kernel/drivers/mmc/core/sdio_io.c:722: warning: Function parameter or member 'flags' not described in 'sdio_set_host_pm_flags'

Cc: Pierre Ossman <drzeus@drzeus.cx>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/core/sdio_io.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/mmc/core/sdio_io.c b/drivers/mmc/core/sdio_io.c
index 2ba00acf64e64..b5dd893bbcb6f 100644
--- a/drivers/mmc/core/sdio_io.c
+++ b/drivers/mmc/core/sdio_io.c
@@ -709,6 +709,7 @@ EXPORT_SYMBOL_GPL(sdio_get_host_pm_caps);
 /**
  *	sdio_set_host_pm_flags - set wanted host power management capabilities
  *	@func: SDIO function attached to host
+ *	@flags: Power Management flags to set
  *
  *	Set a capability bitmask corresponding to wanted host controller
  *	power management features for the upcoming suspend state.
-- 
2.25.1


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

* [PATCH 03/15] mmc: core: regulator: Add missing documetation for 'mmc' and 'ios'
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
  2020-07-01 12:46 ` [PATCH 01/15] mmc: core: quirks: Mark fixups as __maybe_unused Lee Jones
  2020-07-01 12:46 ` [PATCH 02/15] mmc: core: sdio_io: Provide description for sdio_set_host_pm_flags()'s 'flag' arg Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-01 12:46 ` [PATCH 04/15] mmc: host: sdhci-s3c: Provide documentation for missing struct properties Lee Jones
                   ` (12 subsequent siblings)
  15 siblings, 0 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson; +Cc: linux-arm-kernel, linux-kernel, Lee Jones

Remainder of the kerneldoc descriptions look present and correct.

Fixes the following W=1 kernel build warnings:

 drivers/mmc/core/regulator.c:178: warning: Function parameter or member 'mmc' not described in 'mmc_regulator_set_vqmmc'
 drivers/mmc/core/regulator.c:178: warning: Function parameter or member 'ios' not described in 'mmc_regulator_set_vqmmc'

Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/core/regulator.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/mmc/core/regulator.c b/drivers/mmc/core/regulator.c
index 96b1d15045d60..609201a467ef9 100644
--- a/drivers/mmc/core/regulator.c
+++ b/drivers/mmc/core/regulator.c
@@ -159,6 +159,8 @@ static int mmc_regulator_set_voltage_if_supported(struct regulator *regulator,
 
 /**
  * mmc_regulator_set_vqmmc - Set VQMMC as per the ios
+ * @mmc: the host to regulate
+ * @ios: io bus settings
  *
  * For 3.3V signaling, we try to match VQMMC to VMMC as closely as possible.
  * That will match the behavior of old boards where VQMMC and VMMC were supplied
-- 
2.25.1


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

* [PATCH 04/15] mmc: host: sdhci-s3c: Provide documentation for missing struct properties
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (2 preceding siblings ...)
  2020-07-01 12:46 ` [PATCH 03/15] mmc: core: regulator: Add missing documetation for 'mmc' and 'ios' Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-05 23:53   ` Jaehoon Chung
  2020-07-01 12:46 ` [PATCH 05/15] mmc: host: mtk-sd: Demote msdc_recheck_sdio_irq() function header Lee Jones
                   ` (11 subsequent siblings)
  15 siblings, 1 reply; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Lee Jones, Adrian Hunter,
	Ben Dooks, Jaehoon Chung

Describe properties; ext_cd_irq, clk_rates and no_divider (x2).

Squashes the following W=1 kernel build warnings:

 drivers/mmc/host/sdhci-s3c.c:126: warning: Function parameter or member 'ext_cd_irq' not described in 'sdhci_s3c'
 drivers/mmc/host/sdhci-s3c.c:126: warning: Function parameter or member 'clk_rates' not described in 'sdhci_s3c'
 drivers/mmc/host/sdhci-s3c.c:126: warning: Function parameter or member 'no_divider' not described in 'sdhci_s3c'
 drivers/mmc/host/sdhci-s3c.c:139: warning: Function parameter or member 'no_divider' not described in 'sdhci_s3c_drv_data'

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Ben Dooks <ben-linux@fluff.org>
Cc: Jaehoon Chung <jh80.chung@samsung.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/host/sdhci-s3c.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/mmc/host/sdhci-s3c.c b/drivers/mmc/host/sdhci-s3c.c
index 64200c78e90dc..9194bb73e601b 100644
--- a/drivers/mmc/host/sdhci-s3c.c
+++ b/drivers/mmc/host/sdhci-s3c.c
@@ -107,8 +107,11 @@
  * @ioarea: The resource created when we claimed the IO area.
  * @pdata: The platform data for this controller.
  * @cur_clk: The index of the current bus clock.
+ * @ext_cd_irq: External card detect interrupt.
  * @clk_io: The clock for the internal bus interface.
+ * @clk_rates: Clock frequencies.
  * @clk_bus: The clocks that are available for the SD/MMC bus clock.
+ * @no_divider: No or non-standard internal clock divider.
  */
 struct sdhci_s3c {
 	struct sdhci_host	*host;
@@ -128,6 +131,7 @@ struct sdhci_s3c {
 /**
  * struct sdhci_s3c_driver_data - S3C SDHCI platform specific driver data
  * @sdhci_quirks: sdhci host specific quirks.
+ * @no_divider: no or non-standard internal clock divider.
  *
  * Specifies platform specific configuration of sdhci controller.
  * Note: A structure for driver specific platform data is used for future
-- 
2.25.1


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

* [PATCH 05/15] mmc: host: mtk-sd: Demote msdc_recheck_sdio_irq() function header
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (3 preceding siblings ...)
  2020-07-01 12:46 ` [PATCH 04/15] mmc: host: sdhci-s3c: Provide documentation for missing struct properties Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-01 13:09   ` Matthias Brugger
  2020-07-01 12:46 ` [PATCH 06/15] mmc: host: atmel-mci: Provide 2 new and correct 1 existing property description Lee Jones
                   ` (10 subsequent siblings)
  15 siblings, 1 reply; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Lee Jones, Chaotian Jing,
	Matthias Brugger, linux-mediatek

No other function in the file is documented using kerneldoc and no
effort to document the function arguments have been made.  It's a
bit of an oddity to say the least.  Let's downgrade it from
kerneldoc to a standard comment block instead.

Fixes the following W=1 kernel build warning:

 drivers/mmc/host/mtk-sd.c:1030: warning: Function parameter or member 'host' not described in 'msdc_recheck_sdio_irq'

Cc: Chaotian Jing <chaotian.jing@mediatek.com>
Cc: Matthias Brugger <matthias.bgg@gmail.com>
Cc: linux-mediatek@lists.infradead.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/host/mtk-sd.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/mmc/host/mtk-sd.c b/drivers/mmc/host/mtk-sd.c
index 39e7fc54c438f..49ac802ebbfeb 100644
--- a/drivers/mmc/host/mtk-sd.c
+++ b/drivers/mmc/host/mtk-sd.c
@@ -1018,13 +1018,12 @@ static int msdc_auto_cmd_done(struct msdc_host *host, int events,
 	return cmd->error;
 }
 
-/**
+/*
  * msdc_recheck_sdio_irq - recheck whether the SDIO irq is lost
  *
  * Host controller may lost interrupt in some special case.
  * Add SDIO irq recheck mechanism to make sure all interrupts
  * can be processed immediately
- *
  */
 static void msdc_recheck_sdio_irq(struct msdc_host *host)
 {
-- 
2.25.1


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

* [PATCH 06/15] mmc: host: atmel-mci: Provide 2 new and correct 1 existing property description
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (4 preceding siblings ...)
  2020-07-01 12:46 ` [PATCH 05/15] mmc: host: mtk-sd: Demote msdc_recheck_sdio_irq() function header Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-01 12:46 ` [PATCH 07/15] mmc: core: queue: Correct misspelling of 'mq' in mmc_init_request()'s docs Lee Jones
                   ` (9 subsequent siblings)
  15 siblings, 0 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Lee Jones, Ludovic Desroches,
	Nicolas Ferre, Alexandre Belloni

'sg_len' and 'dma_conf' are missing correct kerneldoc documentation and
'buf_phys_addr' was misspelled.  Correcting these issues fixes the
following W=1 kernel build issues:

 mmc/host/atmel-mci.c:352: warning: Function parameter or member 'sg_len' not described in 'atmel_mci'
 mmc/host/atmel-mci.c:352: warning: Function parameter or member 'buf_phys_addr' not described in 'atmel_mci'
 mmc/host/atmel-mci.c:352: warning: Function parameter or member 'dma_conf' not described in 'atmel_mci'

Cc: Ludovic Desroches <ludovic.desroches@microchip.com>
Cc: Nicolas Ferre <nicolas.ferre@microchip.com>
Cc: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/host/atmel-mci.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/atmel-mci.c b/drivers/mmc/host/atmel-mci.c
index 5cb6926876981..300901415aa20 100644
--- a/drivers/mmc/host/atmel-mci.c
+++ b/drivers/mmc/host/atmel-mci.c
@@ -225,12 +225,13 @@ struct atmel_mci_dma {
  * @lock: Spinlock protecting the queue and associated data.
  * @regs: Pointer to MMIO registers.
  * @sg: Scatterlist entry currently being processed by PIO or PDC code.
+ * @sg_len: Size of the scatterlist
  * @pio_offset: Offset into the current scatterlist entry.
  * @buffer: Buffer used if we don't have the r/w proof capability. We
  *      don't have the time to switch pdc buffers so we have to use only
  *      one buffer for the full transaction.
  * @buf_size: size of the buffer.
- * @phys_buf_addr: buffer address needed for pdc.
+ * @buf_phys_addr: buffer address needed for pdc.
  * @cur_slot: The slot which is currently using the controller.
  * @mrq: The request currently being processed on @cur_slot,
  *	or NULL if the controller is idle.
@@ -240,6 +241,7 @@ struct atmel_mci_dma {
  * @data_size: just data->blocks * data->blksz.
  * @dma: DMA client state.
  * @data_chan: DMA channel being used for the current data transfer.
+ * @dma_conf: Configuration for the DMA slave
  * @cmd_status: Snapshot of SR taken upon completion of the current
  *	command. Only valid when EVENT_CMD_COMPLETE is pending.
  * @data_status: Snapshot of SR taken upon completion of the current
-- 
2.25.1


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

* [PATCH 07/15] mmc: core: queue: Correct misspelling of 'mq' in mmc_init_request()'s docs
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (5 preceding siblings ...)
  2020-07-01 12:46 ` [PATCH 06/15] mmc: host: atmel-mci: Provide 2 new and correct 1 existing property description Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-01 12:46 ` [PATCH 08/15] mmc: host: dw_mmc-exynos: Add kerneldoc descriptions of for 'dev' args Lee Jones
                   ` (8 subsequent siblings)
  15 siblings, 0 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson; +Cc: linux-arm-kernel, linux-kernel, Lee Jones

Correcting this misspelling squashes the following W=1 build warning(s):

 mmc/core/queue.c:212: warning: Function parameter or member 'mq' not described in '__mmc_init_request'
 mmc/core/queue.c:212: warning: Excess function parameter 'q' description in '__mmc_init_request'

Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/core/queue.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/core/queue.c b/drivers/mmc/core/queue.c
index 4b1eb89b401d9..6c022ef0f84d7 100644
--- a/drivers/mmc/core/queue.c
+++ b/drivers/mmc/core/queue.c
@@ -203,7 +203,7 @@ static unsigned int mmc_get_max_segments(struct mmc_host *host)
 
 /**
  * mmc_init_request() - initialize the MMC-specific per-request data
- * @q: the request queue
+ * @mq: the request queue
  * @req: the request
  * @gfp: memory allocation policy
  */
-- 
2.25.1


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

* [PATCH 08/15] mmc: host: dw_mmc-exynos: Add kerneldoc descriptions of for 'dev' args
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (6 preceding siblings ...)
  2020-07-01 12:46 ` [PATCH 07/15] mmc: core: queue: Correct misspelling of 'mq' in mmc_init_request()'s docs Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-05 23:53   ` Jaehoon Chung
  2020-07-01 12:46 ` [PATCH 09/15] mmc: host: rtsx_pci_sdmmc: Remove set but unused variable 'err' Lee Jones
                   ` (7 subsequent siblings)
  15 siblings, 1 reply; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Lee Jones, Jaehoon Chung,
	Kukjin Kim, Krzysztof Kozlowski, Thomas Abraham,
	linux-samsung-soc

Provide missing documentation for dw_mci_exynos_suspend_noirq() and
dw_mci_exynos_resume_noirq() function headers.

Fixes the following W=1 kernel build warnings:

 drivers/mmc/host/dw_mmc-exynos.c:184: warning: Function parameter or member 'dev' not described in 'dw_mci_exynos_suspend_noirq'
 drivers/mmc/host/dw_mmc-exynos.c:200: warning: Function parameter or member 'dev' not described in 'dw_mci_exynos_resume_noirq'

Cc: Jaehoon Chung <jh80.chung@samsung.com>
Cc: Kukjin Kim <kgene@kernel.org>
Cc: Krzysztof Kozlowski <krzk@kernel.org>
Cc: Thomas Abraham <thomas.ab@samsung.com>
Cc: linux-samsung-soc@vger.kernel.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/host/dw_mmc-exynos.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/mmc/host/dw_mmc-exynos.c b/drivers/mmc/host/dw_mmc-exynos.c
index 5e3d95b636769..bd59186f59b39 100644
--- a/drivers/mmc/host/dw_mmc-exynos.c
+++ b/drivers/mmc/host/dw_mmc-exynos.c
@@ -176,6 +176,7 @@ static int dw_mci_exynos_runtime_resume(struct device *dev)
 #ifdef CONFIG_PM_SLEEP
 /**
  * dw_mci_exynos_suspend_noirq - Exynos-specific suspend code
+ * @dev: Device to suspend (this device)
  *
  * This ensures that device will be in runtime active state in
  * dw_mci_exynos_resume_noirq after calling pm_runtime_force_resume()
@@ -188,6 +189,7 @@ static int dw_mci_exynos_suspend_noirq(struct device *dev)
 
 /**
  * dw_mci_exynos_resume_noirq - Exynos-specific resume code
+ * @dev: Device to resume (this device)
  *
  * On exynos5420 there is a silicon errata that will sometimes leave the
  * WAKEUP_INT bit in the CLKSEL register asserted.  This bit is 1 to indicate
-- 
2.25.1


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

* [PATCH 09/15] mmc: host: rtsx_pci_sdmmc: Remove set but unused variable 'err'
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (7 preceding siblings ...)
  2020-07-01 12:46 ` [PATCH 08/15] mmc: host: dw_mmc-exynos: Add kerneldoc descriptions of for 'dev' args Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-01 12:46 ` [PATCH 10/15] mmc: host: rtsx_usb_sdmmc: " Lee Jones
                   ` (6 subsequent siblings)
  15 siblings, 0 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson; +Cc: linux-arm-kernel, linux-kernel, Lee Jones, Wei WANG

Seeing as sd_wait_data_idle() returns void and only a very specific
read value is checked, there doesn't seem to be a good reason to
check the return value of rtsx_pci_read_register().  So remove
the assignment and definition of 'err'.

Squashes the following W=1 kernel build warning:

 drivers/mmc/host/rtsx_pci_sdmmc.c: In function ‘sd_wait_data_idle’:
 drivers/mmc/host/rtsx_pci_sdmmc.c:678:6: warning: variable ‘err’ set but not used [-Wunused-but-set-variable]
 678 | int err, i;
 | ^~~

Cc: Wei WANG <wei_wang@realsil.com.cn>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/host/rtsx_pci_sdmmc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/mmc/host/rtsx_pci_sdmmc.c b/drivers/mmc/host/rtsx_pci_sdmmc.c
index 5a71f6678fd3a..dc0dbd64a2a78 100644
--- a/drivers/mmc/host/rtsx_pci_sdmmc.c
+++ b/drivers/mmc/host/rtsx_pci_sdmmc.c
@@ -675,11 +675,11 @@ static u8 sd_search_final_phase(struct realtek_pci_sdmmc *host, u32 phase_map)
 
 static void sd_wait_data_idle(struct realtek_pci_sdmmc *host)
 {
-	int err, i;
+	int i;
 	u8 val = 0;
 
 	for (i = 0; i < 100; i++) {
-		err = rtsx_pci_read_register(host->pcr, SD_DATA_STATE, &val);
+		rtsx_pci_read_register(host->pcr, SD_DATA_STATE, &val);
 		if (val & SD_DATA_IDLE)
 			return;
 
-- 
2.25.1


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

* [PATCH 10/15] mmc: host: rtsx_usb_sdmmc: Remove set but unused variable 'err'
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (8 preceding siblings ...)
  2020-07-01 12:46 ` [PATCH 09/15] mmc: host: rtsx_pci_sdmmc: Remove set but unused variable 'err' Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-01 12:46 ` [PATCH 11/15] mmc: host: sdhci-of-arasan: Correct formatting and provide missing function arg(s) Lee Jones
                   ` (5 subsequent siblings)
  15 siblings, 0 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson; +Cc: linux-arm-kernel, linux-kernel, Lee Jones, Roger Tseng

Seeing as sd_wait_data_idle() returns void and only a very specific
read value is checked, there doesn't seem to be a good reason to
check the return value of rtsx_pci_read_register().  So remove
the assignment and definition of 'err'.

Squashes the following W=1 kernel build warning:

 drivers/mmc/host/rtsx_usb_sdmmc.c: In function ‘sd_wait_data_idle’:
 drivers/mmc/host/rtsx_usb_sdmmc.c:657:6: warning: variable ‘err’ set but not used [-Wunused-but-set-variable]
 657 | int err, i;
 | ^~~

Cc: Roger Tseng <rogerable@realtek.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/host/rtsx_usb_sdmmc.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/mmc/host/rtsx_usb_sdmmc.c b/drivers/mmc/host/rtsx_usb_sdmmc.c
index a7084c50ad65f..7225d9312af8c 100644
--- a/drivers/mmc/host/rtsx_usb_sdmmc.c
+++ b/drivers/mmc/host/rtsx_usb_sdmmc.c
@@ -654,12 +654,11 @@ static u8 sd_search_final_phase(struct rtsx_usb_sdmmc *host, u32 phase_map)
 
 static void sd_wait_data_idle(struct rtsx_usb_sdmmc *host)
 {
-	int err, i;
+	int i;
 	u8 val = 0;
 
 	for (i = 0; i < 100; i++) {
-		err = rtsx_usb_ep0_read_register(host->ucr,
-				SD_DATA_STATE, &val);
+		rtsx_usb_ep0_read_register(host->ucr, SD_DATA_STATE, &val);
 		if (val & SD_DATA_IDLE)
 			return;
 
-- 
2.25.1


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

* [PATCH 11/15] mmc: host: sdhci-of-arasan: Correct formatting and provide missing function arg(s)
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (9 preceding siblings ...)
  2020-07-01 12:46 ` [PATCH 10/15] mmc: host: rtsx_usb_sdmmc: " Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-08  7:53   ` Michal Simek
  2020-07-01 12:46 ` [PATCH 12/15] mmc: host: sdhci-msm: Staticify local function sdhci_msm_dump_vendor_regs() Lee Jones
                   ` (4 subsequent siblings)
  15 siblings, 1 reply; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Lee Jones, Adrian Hunter,
	Michal Simek, Xiaobo Xie, Anton Vorontsov, Soeren Brinkmann

Kerneldoc expects arg descriptions to be in the format '@.*: '.  If either
the '@' or the ':' is omitted then kerneldoc complains that the description
is missing.  Add the missing ':' here and provide a new description for
'value'.

Fixes the following kernel build W=1 warnings:

 drivers/mmc/host/sdhci-of-arasan.c:1394: warning: Function parameter or member 'host' not described in 'sdhci_arasan_update_support64b'
 drivers/mmc/host/sdhci-of-arasan.c:1394: warning: Function parameter or member 'value' not described in 'sdhci_arasan_update_support64b'
 drivers/mmc/host/sdhci-msm.c:1887:6: warning: no previous prototype for ‘sdhci_msm_dump_vendor_regs’ [-Wmissing-prototypes]

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Michal Simek <michal.simek@xilinx.com>
Cc: Xiaobo Xie <X.Xie@freescale.com>
Cc: Anton Vorontsov <avorontsov@ru.mvista.com>
Cc: Soeren Brinkmann <soren.brinkmann@xilinx.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/host/sdhci-of-arasan.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sdhci-of-arasan.c b/drivers/mmc/host/sdhci-of-arasan.c
index db9b544465cda..260e06e238f7e 100644
--- a/drivers/mmc/host/sdhci-of-arasan.c
+++ b/drivers/mmc/host/sdhci-of-arasan.c
@@ -1388,7 +1388,8 @@ static void sdhci_arasan_unregister_sdclk(struct device *dev)
  * - For Keem Bay, it is required to clear this bit. Its default value is 1'b1.
  *   Keem Bay does not support 64-bit access.
  *
- * @host		The sdhci_host
+ * @host:		The sdhci_host
+ * @value:		The value to write
  */
 static void sdhci_arasan_update_support64b(struct sdhci_host *host, u32 value)
 {
-- 
2.25.1


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

* [PATCH 12/15] mmc: host: sdhci-msm: Staticify local function sdhci_msm_dump_vendor_regs()
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (10 preceding siblings ...)
  2020-07-01 12:46 ` [PATCH 11/15] mmc: host: sdhci-of-arasan: Correct formatting and provide missing function arg(s) Lee Jones
@ 2020-07-01 12:46 ` Lee Jones
  2020-07-01 12:47 ` [PATCH 13/15] mmc: host: sdhci-msm: Demote faux kerneldoc header down to basic comment block Lee Jones
                   ` (3 subsequent siblings)
  15 siblings, 0 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:46 UTC (permalink / raw)
  To: ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Lee Jones, Adrian Hunter,
	Andy Gross, Bjorn Andersson, linux-arm-msm

sdhci_msm_dump_vendor_regs() is only used via the .dump_vendor_regs()
call-back.  It is never exported nor used externally, so it can be static.

Squashes the following W=1 kernel build warning:

 drivers/mmc/host/sdhci-msm.c:1887:6: warning: no previous prototype for ‘sdhci_msm_dump_vendor_regs’ [-Wmissing-prototypes]
 1887 | void sdhci_msm_dump_vendor_regs(struct sdhci_host *host)
 | ^~~~~~~~~~~~~~~~~~~~~~~~~~

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Andy Gross <agross@kernel.org>
Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
Cc: linux-arm-msm@vger.kernel.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/host/sdhci-msm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c
index b277dd7fbdb5d..0c02f8a2d11ab 100644
--- a/drivers/mmc/host/sdhci-msm.c
+++ b/drivers/mmc/host/sdhci-msm.c
@@ -1884,7 +1884,7 @@ static void sdhci_msm_reset(struct sdhci_host *host, u8 mask)
 #define SDHCI_MSM_DUMP(f, x...) \
 	pr_err("%s: " DRIVER_NAME ": " f, mmc_hostname(host->mmc), ## x)
 
-void sdhci_msm_dump_vendor_regs(struct sdhci_host *host)
+static void sdhci_msm_dump_vendor_regs(struct sdhci_host *host)
 {
 	struct sdhci_pltfm_host *pltfm_host = sdhci_priv(host);
 	struct sdhci_msm_host *msm_host = sdhci_pltfm_priv(pltfm_host);
-- 
2.25.1


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

* [PATCH 13/15] mmc: host: sdhci-msm: Demote faux kerneldoc header down to basic comment block
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (11 preceding siblings ...)
  2020-07-01 12:46 ` [PATCH 12/15] mmc: host: sdhci-msm: Staticify local function sdhci_msm_dump_vendor_regs() Lee Jones
@ 2020-07-01 12:47 ` Lee Jones
  2020-07-01 12:47 ` [PATCH 14/15] mmc: host: cqhci: " Lee Jones
                   ` (2 subsequent siblings)
  15 siblings, 0 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:47 UTC (permalink / raw)
  To: ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Lee Jones, Adrian Hunter,
	Andy Gross, Bjorn Andersson, linux-arm-msm

__sdhci_msm_set_clock()'s function header is the only one in
kerneldoc format.  Which seems odd as it's not part of an
external API and isn't referenced anywhere else.  Seeing as
there has also been no attempt to describe the expected
function arguments either, we're going to assume that this is
not actually a bona fide kerneldoc use-case.

Fixes the following W=1 kernel build warnings:

 drivers/mmc/host/sdhci-msm.c:1595: warning: Function parameter or member 'host' not described in '__sdhci_msm_set_clock'
 drivers/mmc/host/sdhci-msm.c:1595: warning: Function parameter or member 'clock' not described in '__sdhci_msm_set_clock'

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Andy Gross <agross@kernel.org>
Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
Cc: linux-arm-msm@vger.kernel.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/host/sdhci-msm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sdhci-msm.c b/drivers/mmc/host/sdhci-msm.c
index 0c02f8a2d11ab..7a574fc7635c4 100644
--- a/drivers/mmc/host/sdhci-msm.c
+++ b/drivers/mmc/host/sdhci-msm.c
@@ -1583,7 +1583,7 @@ static unsigned int sdhci_msm_get_min_clock(struct sdhci_host *host)
 	return SDHCI_MSM_MIN_CLOCK;
 }
 
-/**
+/*
  * __sdhci_msm_set_clock - sdhci_msm clock control.
  *
  * Description:
-- 
2.25.1


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

* [PATCH 14/15] mmc: host: cqhci: Demote faux kerneldoc header down to basic comment block
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (12 preceding siblings ...)
  2020-07-01 12:47 ` [PATCH 13/15] mmc: host: sdhci-msm: Demote faux kerneldoc header down to basic comment block Lee Jones
@ 2020-07-01 12:47 ` Lee Jones
  2020-07-02  6:43   ` Adrian Hunter
  2020-07-01 12:47 ` [PATCH 15/15] mmc: host: sdhci-iproc: Tell the compiler that ACPI functions may not be used Lee Jones
  2020-07-07  6:50 ` [PATCH 00/15] Clean-up MMC's W=1 build warnings Ulf Hansson
  15 siblings, 1 reply; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:47 UTC (permalink / raw)
  To: ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Lee Jones, Adrian Hunter,
	Ritesh Harjani, Asutosh Das, Venkat Gopalakrishnan

cqhci_host_alloc_tdl()'s function header is the only one in
kerneldoc format.  Which seems odd as it's not part of an
external API and isn't referenced anywhere else.  Seeing as
there has also been no attempt to describe the expected
function arguments either, we're going to assume that this is
not actually a bona fide kerneldoc use-case.

Fixes the following W=1 kernel build warning:

 drivers/mmc/host/cqhci.c:163: warning: Function parameter or member 'cq_host' not described in 'cqhci_host_alloc_tdl'

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Ritesh Harjani <riteshh@codeaurora.org>
Cc: Asutosh Das <asutoshd@codeaurora.org>
Cc: Venkat Gopalakrishnan <venkatg@codeaurora.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/host/cqhci.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/cqhci.c b/drivers/mmc/host/cqhci.c
index 75934f3c117eb..8cc277b4ffe9e 100644
--- a/drivers/mmc/host/cqhci.c
+++ b/drivers/mmc/host/cqhci.c
@@ -144,7 +144,7 @@ static void cqhci_dumpregs(struct cqhci_host *cq_host)
 		CQHCI_DUMP(": ===========================================\n");
 }
 
-/**
+/*
  * The allocated descriptor table for task, link & transfer descritors
  * looks like:
  * |----------|
-- 
2.25.1


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

* [PATCH 15/15] mmc: host: sdhci-iproc: Tell the compiler that ACPI functions may not be used
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (13 preceding siblings ...)
  2020-07-01 12:47 ` [PATCH 14/15] mmc: host: cqhci: " Lee Jones
@ 2020-07-01 12:47 ` Lee Jones
  2020-07-02 19:42   ` Scott Branden
  2020-07-07  6:47   ` [PATCH v2 15/15] mmc: host: sdhci-iproc: Do not define 'struct acpi_device_id' when !CONFIG_ACPI Lee Jones
  2020-07-07  6:50 ` [PATCH 00/15] Clean-up MMC's W=1 build warnings Ulf Hansson
  15 siblings, 2 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-01 12:47 UTC (permalink / raw)
  To: ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Lee Jones, Adrian Hunter,
	Ray Jui, Scott Branden, bcm-kernel-feedback-list

... as is the case when !CONFIG_ACPI.

Fixes the following W=1 kernel build warning:

 mmc/host/sdhci-iproc.c:297:36: warning: ‘sdhci_iproc_acpi_ids’ defined but not used [-Wunused-const-variable=]

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Ray Jui <rjui@broadcom.com>
Cc: Scott Branden <sbranden@broadcom.com>
Cc: bcm-kernel-feedback-list@broadcom.com
Signed-off-by: Lee Jones <lee.jones@linaro.org>
---
 drivers/mmc/host/sdhci-iproc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sdhci-iproc.c b/drivers/mmc/host/sdhci-iproc.c
index 225603148d7de..9c7d130205edd 100644
--- a/drivers/mmc/host/sdhci-iproc.c
+++ b/drivers/mmc/host/sdhci-iproc.c
@@ -294,7 +294,7 @@ static const struct of_device_id sdhci_iproc_of_match[] = {
 };
 MODULE_DEVICE_TABLE(of, sdhci_iproc_of_match);
 
-static const struct acpi_device_id sdhci_iproc_acpi_ids[] = {
+static const struct acpi_device_id __maybe_unused sdhci_iproc_acpi_ids[] = {
 	{ .id = "BRCM5871", .driver_data = (kernel_ulong_t)&iproc_cygnus_data },
 	{ .id = "BRCM5872", .driver_data = (kernel_ulong_t)&iproc_data },
 	{ /* sentinel */ }
-- 
2.25.1


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

* Re: [PATCH 05/15] mmc: host: mtk-sd: Demote msdc_recheck_sdio_irq() function header
  2020-07-01 12:46 ` [PATCH 05/15] mmc: host: mtk-sd: Demote msdc_recheck_sdio_irq() function header Lee Jones
@ 2020-07-01 13:09   ` Matthias Brugger
  0 siblings, 0 replies; 28+ messages in thread
From: Matthias Brugger @ 2020-07-01 13:09 UTC (permalink / raw)
  To: Lee Jones, ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Chaotian Jing, linux-mediatek



On 01/07/2020 14:46, Lee Jones wrote:
> No other function in the file is documented using kerneldoc and no
> effort to document the function arguments have been made.  It's a
> bit of an oddity to say the least.  Let's downgrade it from
> kerneldoc to a standard comment block instead.
> 
> Fixes the following W=1 kernel build warning:
> 
>  drivers/mmc/host/mtk-sd.c:1030: warning: Function parameter or member 'host' not described in 'msdc_recheck_sdio_irq'
> 
> Cc: Chaotian Jing <chaotian.jing@mediatek.com>
> Cc: Matthias Brugger <matthias.bgg@gmail.com>
> Cc: linux-mediatek@lists.infradead.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com>

> ---
>  drivers/mmc/host/mtk-sd.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/mmc/host/mtk-sd.c b/drivers/mmc/host/mtk-sd.c
> index 39e7fc54c438f..49ac802ebbfeb 100644
> --- a/drivers/mmc/host/mtk-sd.c
> +++ b/drivers/mmc/host/mtk-sd.c
> @@ -1018,13 +1018,12 @@ static int msdc_auto_cmd_done(struct msdc_host *host, int events,
>  	return cmd->error;
>  }
>  
> -/**
> +/*
>   * msdc_recheck_sdio_irq - recheck whether the SDIO irq is lost
>   *
>   * Host controller may lost interrupt in some special case.
>   * Add SDIO irq recheck mechanism to make sure all interrupts
>   * can be processed immediately
> - *
>   */
>  static void msdc_recheck_sdio_irq(struct msdc_host *host)
>  {
> 

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

* Re: [PATCH 14/15] mmc: host: cqhci: Demote faux kerneldoc header down to basic comment block
  2020-07-01 12:47 ` [PATCH 14/15] mmc: host: cqhci: " Lee Jones
@ 2020-07-02  6:43   ` Adrian Hunter
  0 siblings, 0 replies; 28+ messages in thread
From: Adrian Hunter @ 2020-07-02  6:43 UTC (permalink / raw)
  To: Lee Jones, ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Ritesh Harjani, Asutosh Das,
	Venkat Gopalakrishnan

On 1/07/20 3:47 pm, Lee Jones wrote:
> cqhci_host_alloc_tdl()'s function header is the only one in
> kerneldoc format.  Which seems odd as it's not part of an
> external API and isn't referenced anywhere else.  Seeing as
> there has also been no attempt to describe the expected
> function arguments either, we're going to assume that this is
> not actually a bona fide kerneldoc use-case.
> 
> Fixes the following W=1 kernel build warning:
> 
>  drivers/mmc/host/cqhci.c:163: warning: Function parameter or member 'cq_host' not described in 'cqhci_host_alloc_tdl'
> 
> Cc: Adrian Hunter <adrian.hunter@intel.com>
> Cc: Ritesh Harjani <riteshh@codeaurora.org>
> Cc: Asutosh Das <asutoshd@codeaurora.org>
> Cc: Venkat Gopalakrishnan <venkatg@codeaurora.org>
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Acked-by: Adrian Hunter <adrian.hunter@intel.com>

> ---
>  drivers/mmc/host/cqhci.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/mmc/host/cqhci.c b/drivers/mmc/host/cqhci.c
> index 75934f3c117eb..8cc277b4ffe9e 100644
> --- a/drivers/mmc/host/cqhci.c
> +++ b/drivers/mmc/host/cqhci.c
> @@ -144,7 +144,7 @@ static void cqhci_dumpregs(struct cqhci_host *cq_host)
>  		CQHCI_DUMP(": ===========================================\n");
>  }
>  
> -/**
> +/*
>   * The allocated descriptor table for task, link & transfer descritors
>   * looks like:
>   * |----------|
> 


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

* Re: [PATCH 15/15] mmc: host: sdhci-iproc: Tell the compiler that ACPI functions may not be used
  2020-07-01 12:47 ` [PATCH 15/15] mmc: host: sdhci-iproc: Tell the compiler that ACPI functions may not be used Lee Jones
@ 2020-07-02 19:42   ` Scott Branden
  2020-07-02 20:13     ` Lee Jones
  2020-07-07  6:47   ` [PATCH v2 15/15] mmc: host: sdhci-iproc: Do not define 'struct acpi_device_id' when !CONFIG_ACPI Lee Jones
  1 sibling, 1 reply; 28+ messages in thread
From: Scott Branden @ 2020-07-02 19:42 UTC (permalink / raw)
  To: Lee Jones, ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Adrian Hunter, Ray Jui,
	Scott Branden, bcm-kernel-feedback-list

Hi Lee,

On 2020-07-01 5:47 a.m., Lee Jones wrote:
> ... as is the case when !CONFIG_ACPI.
>
> Fixes the following W=1 kernel build warning:
>
>   mmc/host/sdhci-iproc.c:297:36: warning: ‘sdhci_iproc_acpi_ids’ defined but not used [-Wunused-const-variable=]
>
> Cc: Adrian Hunter <adrian.hunter@intel.com>
> Cc: Ray Jui <rjui@broadcom.com>
> Cc: Scott Branden <sbranden@broadcom.com>
> Cc: bcm-kernel-feedback-list@broadcom.com
> Signed-off-by: Lee Jones <lee.jones@linaro.org>
> ---
>   drivers/mmc/host/sdhci-iproc.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mmc/host/sdhci-iproc.c b/drivers/mmc/host/sdhci-iproc.c
> index 225603148d7de..9c7d130205edd 100644
> --- a/drivers/mmc/host/sdhci-iproc.c
> +++ b/drivers/mmc/host/sdhci-iproc.c
> @@ -294,7 +294,7 @@ static const struct of_device_id sdhci_iproc_of_match[] = {
>   };
>   MODULE_DEVICE_TABLE(of, sdhci_iproc_of_match);
>   
Would it better to compile this in if CONFIG_ACPI is defined instead?
#if CONFIG_ACPI
> -static const struct acpi_device_id sdhci_iproc_acpi_ids[] = {
> +static const struct acpi_device_id __maybe_unused sdhci_iproc_acpi_ids[] = {
>   	{ .id = "BRCM5871", .driver_data = (kernel_ulong_t)&iproc_cygnus_data },
>   	{ .id = "BRCM5872", .driver_data = (kernel_ulong_t)&iproc_data },
>   	{ /* sentinel */ }


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

* Re: [PATCH 15/15] mmc: host: sdhci-iproc: Tell the compiler that ACPI functions may not be used
  2020-07-02 19:42   ` Scott Branden
@ 2020-07-02 20:13     ` Lee Jones
  2020-07-02 20:49       ` Scott Branden
  0 siblings, 1 reply; 28+ messages in thread
From: Lee Jones @ 2020-07-02 20:13 UTC (permalink / raw)
  To: Scott Branden
  Cc: ulf.hansson, linux-arm-kernel, linux-kernel, Adrian Hunter,
	Ray Jui, Scott Branden, bcm-kernel-feedback-list

On Thu, 02 Jul 2020, Scott Branden wrote:

> Hi Lee,
> 
> On 2020-07-01 5:47 a.m., Lee Jones wrote:
> > ... as is the case when !CONFIG_ACPI.
> > 
> > Fixes the following W=1 kernel build warning:
> > 
> >   mmc/host/sdhci-iproc.c:297:36: warning: ‘sdhci_iproc_acpi_ids’ defined but not used [-Wunused-const-variable=]
> > 
> > Cc: Adrian Hunter <adrian.hunter@intel.com>
> > Cc: Ray Jui <rjui@broadcom.com>
> > Cc: Scott Branden <sbranden@broadcom.com>
> > Cc: bcm-kernel-feedback-list@broadcom.com
> > Signed-off-by: Lee Jones <lee.jones@linaro.org>
> > ---
> >   drivers/mmc/host/sdhci-iproc.c | 2 +-
> >   1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/drivers/mmc/host/sdhci-iproc.c b/drivers/mmc/host/sdhci-iproc.c
> > index 225603148d7de..9c7d130205edd 100644
> > --- a/drivers/mmc/host/sdhci-iproc.c
> > +++ b/drivers/mmc/host/sdhci-iproc.c
> > @@ -294,7 +294,7 @@ static const struct of_device_id sdhci_iproc_of_match[] = {
> >   };
> >   MODULE_DEVICE_TABLE(of, sdhci_iproc_of_match);

> Would it better to compile this in if CONFIG_ACPI is defined instead?
> #if CONFIG_ACPI

Literally can't win.

 https://lore.kernel.org/linux-arm-kernel/CAGb2v66Ws4WNPZbOYQvikKoozj_2WjzS-Jq-o2VxT77=k0vODw@mail.gmail.com/

Damned if we do, damned if we don't. ;)

> > -static const struct acpi_device_id sdhci_iproc_acpi_ids[] = {
> > +static const struct acpi_device_id __maybe_unused sdhci_iproc_acpi_ids[] = {
> >   	{ .id = "BRCM5871", .driver_data = (kernel_ulong_t)&iproc_cygnus_data },
> >   	{ .id = "BRCM5872", .driver_data = (kernel_ulong_t)&iproc_data },
> >   	{ /* sentinel */ }
> 

-- 
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog

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

* Re: [PATCH 15/15] mmc: host: sdhci-iproc: Tell the compiler that ACPI functions may not be used
  2020-07-02 20:13     ` Lee Jones
@ 2020-07-02 20:49       ` Scott Branden
  0 siblings, 0 replies; 28+ messages in thread
From: Scott Branden @ 2020-07-02 20:49 UTC (permalink / raw)
  To: Lee Jones
  Cc: ulf.hansson, linux-arm-kernel, linux-kernel, Adrian Hunter,
	Ray Jui, Scott Branden, bcm-kernel-feedback-list



On 2020-07-02 1:13 p.m., Lee Jones wrote:
> On Thu, 02 Jul 2020, Scott Branden wrote:
>
>> Hi Lee,
>>
>> On 2020-07-01 5:47 a.m., Lee Jones wrote:
>>> ... as is the case when !CONFIG_ACPI.
>>>
>>> Fixes the following W=1 kernel build warning:
>>>
>>>    mmc/host/sdhci-iproc.c:297:36: warning: ‘sdhci_iproc_acpi_ids’ defined but not used [-Wunused-const-variable=]
>>>
>>> Cc: Adrian Hunter <adrian.hunter@intel.com>
>>> Cc: Ray Jui <rjui@broadcom.com>
>>> Cc: Scott Branden <sbranden@broadcom.com>
>>> Cc: bcm-kernel-feedback-list@broadcom.com
>>> Signed-off-by: Lee Jones <lee.jones@linaro.org>
>>> ---
>>>    drivers/mmc/host/sdhci-iproc.c | 2 +-
>>>    1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/drivers/mmc/host/sdhci-iproc.c b/drivers/mmc/host/sdhci-iproc.c
>>> index 225603148d7de..9c7d130205edd 100644
>>> --- a/drivers/mmc/host/sdhci-iproc.c
>>> +++ b/drivers/mmc/host/sdhci-iproc.c
>>> @@ -294,7 +294,7 @@ static const struct of_device_id sdhci_iproc_of_match[] = {
>>>    };
>>>    MODULE_DEVICE_TABLE(of, sdhci_iproc_of_match);
>> Would it better to compile this in if CONFIG_ACPI is defined instead?
>> #if CONFIG_ACPI
> Literally can't win.
>
>   https://lore.kernel.org/linux-arm-kernel/CAGb2v66Ws4WNPZbOYQvikKoozj_2WjzS-Jq-o2VxT77=k0vODw@mail.gmail.com/
>
> Damned if we do, damned if we don't. ;)
This is very minor in this one change here, but it's just more bloat of 
things that really should be compiled out if they're not used.
I don't understand why __maybe_unused would be preferred approach - 
unless it is not linked in when it is not used?
>
>>> -static const struct acpi_device_id sdhci_iproc_acpi_ids[] = {
>>> +static const struct acpi_device_id __maybe_unused sdhci_iproc_acpi_ids[] = {
>>>    	{ .id = "BRCM5871", .driver_data = (kernel_ulong_t)&iproc_cygnus_data },
>>>    	{ .id = "BRCM5872", .driver_data = (kernel_ulong_t)&iproc_data },
>>>    	{ /* sentinel */ }


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

* Re: [PATCH 08/15] mmc: host: dw_mmc-exynos: Add kerneldoc descriptions of for 'dev' args
  2020-07-01 12:46 ` [PATCH 08/15] mmc: host: dw_mmc-exynos: Add kerneldoc descriptions of for 'dev' args Lee Jones
@ 2020-07-05 23:53   ` Jaehoon Chung
  0 siblings, 0 replies; 28+ messages in thread
From: Jaehoon Chung @ 2020-07-05 23:53 UTC (permalink / raw)
  To: Lee Jones, ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Kukjin Kim, Krzysztof Kozlowski,
	linux-samsung-soc

On 7/1/20 9:46 PM, Lee Jones wrote:
> Provide missing documentation for dw_mci_exynos_suspend_noirq() and
> dw_mci_exynos_resume_noirq() function headers.
> 
> Fixes the following W=1 kernel build warnings:
> 
>  drivers/mmc/host/dw_mmc-exynos.c:184: warning: Function parameter or member 'dev' not described in 'dw_mci_exynos_suspend_noirq'
>  drivers/mmc/host/dw_mmc-exynos.c:200: warning: Function parameter or member 'dev' not described in 'dw_mci_exynos_resume_noirq'
> 
> Cc: Jaehoon Chung <jh80.chung@samsung.com>
> Cc: Kukjin Kim <kgene@kernel.org>
> Cc: Krzysztof Kozlowski <krzk@kernel.org>
> Cc: Thomas Abraham <thomas.ab@samsung.com>
> Cc: linux-samsung-soc@vger.kernel.org
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>

> ---
>  drivers/mmc/host/dw_mmc-exynos.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/mmc/host/dw_mmc-exynos.c b/drivers/mmc/host/dw_mmc-exynos.c
> index 5e3d95b636769..bd59186f59b39 100644
> --- a/drivers/mmc/host/dw_mmc-exynos.c
> +++ b/drivers/mmc/host/dw_mmc-exynos.c
> @@ -176,6 +176,7 @@ static int dw_mci_exynos_runtime_resume(struct device *dev)
>  #ifdef CONFIG_PM_SLEEP
>  /**
>   * dw_mci_exynos_suspend_noirq - Exynos-specific suspend code
> + * @dev: Device to suspend (this device)
>   *
>   * This ensures that device will be in runtime active state in
>   * dw_mci_exynos_resume_noirq after calling pm_runtime_force_resume()
> @@ -188,6 +189,7 @@ static int dw_mci_exynos_suspend_noirq(struct device *dev)
>  
>  /**
>   * dw_mci_exynos_resume_noirq - Exynos-specific resume code
> + * @dev: Device to resume (this device)
>   *
>   * On exynos5420 there is a silicon errata that will sometimes leave the
>   * WAKEUP_INT bit in the CLKSEL register asserted.  This bit is 1 to indicate
> 


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

* Re: [PATCH 04/15] mmc: host: sdhci-s3c: Provide documentation for missing struct properties
  2020-07-01 12:46 ` [PATCH 04/15] mmc: host: sdhci-s3c: Provide documentation for missing struct properties Lee Jones
@ 2020-07-05 23:53   ` Jaehoon Chung
  0 siblings, 0 replies; 28+ messages in thread
From: Jaehoon Chung @ 2020-07-05 23:53 UTC (permalink / raw)
  To: Lee Jones, ulf.hansson; +Cc: linux-arm-kernel, linux-kernel, Ben Dooks

On 7/1/20 9:46 PM, Lee Jones wrote:
> Describe properties; ext_cd_irq, clk_rates and no_divider (x2).
> 
> Squashes the following W=1 kernel build warnings:
> 
>  drivers/mmc/host/sdhci-s3c.c:126: warning: Function parameter or member 'ext_cd_irq' not described in 'sdhci_s3c'
>  drivers/mmc/host/sdhci-s3c.c:126: warning: Function parameter or member 'clk_rates' not described in 'sdhci_s3c'
>  drivers/mmc/host/sdhci-s3c.c:126: warning: Function parameter or member 'no_divider' not described in 'sdhci_s3c'
>  drivers/mmc/host/sdhci-s3c.c:139: warning: Function parameter or member 'no_divider' not described in 'sdhci_s3c_drv_data'
> 
> Cc: Adrian Hunter <adrian.hunter@intel.com>
> Cc: Ben Dooks <ben-linux@fluff.org>
> Cc: Jaehoon Chung <jh80.chung@samsung.com>
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>

> ---
>  drivers/mmc/host/sdhci-s3c.c | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/drivers/mmc/host/sdhci-s3c.c b/drivers/mmc/host/sdhci-s3c.c
> index 64200c78e90dc..9194bb73e601b 100644
> --- a/drivers/mmc/host/sdhci-s3c.c
> +++ b/drivers/mmc/host/sdhci-s3c.c
> @@ -107,8 +107,11 @@
>   * @ioarea: The resource created when we claimed the IO area.
>   * @pdata: The platform data for this controller.
>   * @cur_clk: The index of the current bus clock.
> + * @ext_cd_irq: External card detect interrupt.
>   * @clk_io: The clock for the internal bus interface.
> + * @clk_rates: Clock frequencies.
>   * @clk_bus: The clocks that are available for the SD/MMC bus clock.
> + * @no_divider: No or non-standard internal clock divider.
>   */
>  struct sdhci_s3c {
>  	struct sdhci_host	*host;
> @@ -128,6 +131,7 @@ struct sdhci_s3c {
>  /**
>   * struct sdhci_s3c_driver_data - S3C SDHCI platform specific driver data
>   * @sdhci_quirks: sdhci host specific quirks.
> + * @no_divider: no or non-standard internal clock divider.
>   *
>   * Specifies platform specific configuration of sdhci controller.
>   * Note: A structure for driver specific platform data is used for future
> 


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

* [PATCH v2 15/15] mmc: host: sdhci-iproc: Do not define 'struct acpi_device_id' when !CONFIG_ACPI
  2020-07-01 12:47 ` [PATCH 15/15] mmc: host: sdhci-iproc: Tell the compiler that ACPI functions may not be used Lee Jones
  2020-07-02 19:42   ` Scott Branden
@ 2020-07-07  6:47   ` Lee Jones
  2020-07-07 15:47     ` Scott Branden
  2020-07-08 13:20     ` Ulf Hansson
  1 sibling, 2 replies; 28+ messages in thread
From: Lee Jones @ 2020-07-07  6:47 UTC (permalink / raw)
  To: ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Adrian Hunter, Ray Jui,
	Scott Branden, bcm-kernel-feedback-list

Since ACPI_PTR() is used to NULLify the value when !CONFIG_ACPI,
'struct sdhci_iproc_acpi_ids' becomes defined but unused.

Fixes the following W=1 kernel build warning:

 mmc/host/sdhci-iproc.c:297:36: warning: ‘sdhci_iproc_acpi_ids’ defined but not used [-Wunused-const-variable=]

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Ray Jui <rjui@broadcom.com>
Cc: Scott Branden <sbranden@broadcom.com>
Cc: bcm-kernel-feedback-list@broadcom.com
Signed-off-by: Lee Jones <lee.jones@linaro.org>

diff --git a/drivers/mmc/host/sdhci-iproc.c b/drivers/mmc/host/sdhci-iproc.c
index 225603148d7de..e2d8dfe90077e 100644
--- a/drivers/mmc/host/sdhci-iproc.c
+++ b/drivers/mmc/host/sdhci-iproc.c
@@ -294,12 +294,14 @@ static const struct of_device_id sdhci_iproc_of_match[] = {
 };
 MODULE_DEVICE_TABLE(of, sdhci_iproc_of_match);
 
+#ifdef CONFIG_ACPI
 static const struct acpi_device_id sdhci_iproc_acpi_ids[] = {
        { .id = "BRCM5871", .driver_data = (kernel_ulong_t)&iproc_cygnus_data },
        { .id = "BRCM5872", .driver_data = (kernel_ulong_t)&iproc_data },
        { /* sentinel */ }
 };
 MODULE_DEVICE_TABLE(acpi, sdhci_iproc_acpi_ids);
+#endif
 
 static int sdhci_iproc_probe(struct platform_device *pdev)
 {

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

* Re: [PATCH 00/15] Clean-up MMC's W=1 build warnings
  2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
                   ` (14 preceding siblings ...)
  2020-07-01 12:47 ` [PATCH 15/15] mmc: host: sdhci-iproc: Tell the compiler that ACPI functions may not be used Lee Jones
@ 2020-07-07  6:50 ` Ulf Hansson
  15 siblings, 0 replies; 28+ messages in thread
From: Ulf Hansson @ 2020-07-07  6:50 UTC (permalink / raw)
  To: Lee Jones; +Cc: Linux ARM, Linux Kernel Mailing List

On Wed, 1 Jul 2020 at 14:47, Lee Jones <lee.jones@linaro.org> wrote:
>
> This set is part of a larger effort attempting to clean-up W=1
> kernel builds, which are currently overwhelmingly riddled with
> niggly little warnings.
>
> After these patches are applied, the build system no longer
> complains about any W=0 nor W=1 level warnings in drivers/mmc.
>
> Hurrah!
>
> Lee Jones (15):
>   mmc: core: quirks: Mark fixups as __maybe_unused
>   mmc: core: sdio_io: Provide description for sdio_set_host_pm_flags()'s
>     'flag' arg
>   mmc: core: regulator: Add missing documetation for 'mmc' and 'ios'
>   mmc: host: sdhci-s3c: Provide documentation for missing struct
>     properties
>   mmc: host: mtk-sd: Demote msdc_recheck_sdio_irq() function header
>   mmc: host: atmel-mci: Provide 2 new and correct 1 existing property
>     description
>   mmc: core: queue: Correct misspelling of 'mq' in mmc_init_request()'s
>     docs
>   mmc: host: dw_mmc-exynos: Add kerneldoc descriptions of for 'dev' args
>   mmc: host: rtsx_pci_sdmmc: Remove set but unused variable 'err'
>   mmc: host: rtsx_usb_sdmmc: Remove set but unused variable 'err'
>   mmc: host: sdhci-of-arasan: Correct formatting and provide missing
>     function arg(s)
>   mmc: host: sdhci-msm: Staticify local function
>     sdhci_msm_dump_vendor_regs()
>   mmc: host: sdhci-msm: Demote faux kerneldoc header down to basic
>     comment block
>   mmc: host: cqhci: Demote faux kerneldoc header down to basic comment
>     block
>   mmc: host: sdhci-iproc: Tell the compiler that ACPI functions may not
>     be used
>
>  drivers/mmc/core/queue.c           | 2 +-
>  drivers/mmc/core/quirks.h          | 6 +++---
>  drivers/mmc/core/regulator.c       | 2 ++
>  drivers/mmc/core/sdio_io.c         | 1 +
>  drivers/mmc/host/atmel-mci.c       | 4 +++-
>  drivers/mmc/host/cqhci.c           | 2 +-
>  drivers/mmc/host/dw_mmc-exynos.c   | 2 ++
>  drivers/mmc/host/mtk-sd.c          | 3 +--
>  drivers/mmc/host/rtsx_pci_sdmmc.c  | 4 ++--
>  drivers/mmc/host/rtsx_usb_sdmmc.c  | 5 ++---
>  drivers/mmc/host/sdhci-iproc.c     | 2 +-
>  drivers/mmc/host/sdhci-msm.c       | 4 ++--
>  drivers/mmc/host/sdhci-of-arasan.c | 3 ++-
>  drivers/mmc/host/sdhci-s3c.c       | 4 ++++
>  14 files changed, 27 insertions(+), 17 deletions(-)
>
> --
> 2.25.1
>

Applied for next (except patch12, which I already had a patch for), thanks!

Kind regards
Uffe

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

* Re: [PATCH v2 15/15] mmc: host: sdhci-iproc: Do not define 'struct acpi_device_id' when !CONFIG_ACPI
  2020-07-07  6:47   ` [PATCH v2 15/15] mmc: host: sdhci-iproc: Do not define 'struct acpi_device_id' when !CONFIG_ACPI Lee Jones
@ 2020-07-07 15:47     ` Scott Branden
  2020-07-08 13:20     ` Ulf Hansson
  1 sibling, 0 replies; 28+ messages in thread
From: Scott Branden @ 2020-07-07 15:47 UTC (permalink / raw)
  To: Lee Jones, ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Adrian Hunter, Ray Jui,
	Scott Branden, bcm-kernel-feedback-list

thanks

On 2020-07-06 11:47 p.m., Lee Jones wrote:
> Since ACPI_PTR() is used to NULLify the value when !CONFIG_ACPI,
> 'struct sdhci_iproc_acpi_ids' becomes defined but unused.
>
> Fixes the following W=1 kernel build warning:
>
>   mmc/host/sdhci-iproc.c:297:36: warning: ‘sdhci_iproc_acpi_ids’ defined but not used [-Wunused-const-variable=]
>
> Cc: Adrian Hunter <adrian.hunter@intel.com>
> Cc: Ray Jui <rjui@broadcom.com>
> Cc: Scott Branden <sbranden@broadcom.com>
> Cc: bcm-kernel-feedback-list@broadcom.com
> Signed-off-by: Lee Jones <lee.jones@linaro.org>
Acked-by: Scott Branden <scott.branden@broadcom.com>
>
> diff --git a/drivers/mmc/host/sdhci-iproc.c b/drivers/mmc/host/sdhci-iproc.c
> index 225603148d7de..e2d8dfe90077e 100644
> --- a/drivers/mmc/host/sdhci-iproc.c
> +++ b/drivers/mmc/host/sdhci-iproc.c
> @@ -294,12 +294,14 @@ static const struct of_device_id sdhci_iproc_of_match[] = {
>   };
>   MODULE_DEVICE_TABLE(of, sdhci_iproc_of_match);
>   
> +#ifdef CONFIG_ACPI
>   static const struct acpi_device_id sdhci_iproc_acpi_ids[] = {
>          { .id = "BRCM5871", .driver_data = (kernel_ulong_t)&iproc_cygnus_data },
>          { .id = "BRCM5872", .driver_data = (kernel_ulong_t)&iproc_data },
>          { /* sentinel */ }
>   };
>   MODULE_DEVICE_TABLE(acpi, sdhci_iproc_acpi_ids);
> +#endif
>   
>   static int sdhci_iproc_probe(struct platform_device *pdev)
>   {


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

* Re: [PATCH 11/15] mmc: host: sdhci-of-arasan: Correct formatting and provide missing function arg(s)
  2020-07-01 12:46 ` [PATCH 11/15] mmc: host: sdhci-of-arasan: Correct formatting and provide missing function arg(s) Lee Jones
@ 2020-07-08  7:53   ` Michal Simek
  0 siblings, 0 replies; 28+ messages in thread
From: Michal Simek @ 2020-07-08  7:53 UTC (permalink / raw)
  To: Lee Jones, ulf.hansson
  Cc: linux-arm-kernel, linux-kernel, Adrian Hunter, Michal Simek,
	Xiaobo Xie, Anton Vorontsov, Soeren Brinkmann



On 01. 07. 20 14:46, Lee Jones wrote:
> Kerneldoc expects arg descriptions to be in the format '@.*: '.  If either
> the '@' or the ':' is omitted then kerneldoc complains that the description
> is missing.  Add the missing ':' here and provide a new description for
> 'value'.
> 
> Fixes the following kernel build W=1 warnings:
> 
>  drivers/mmc/host/sdhci-of-arasan.c:1394: warning: Function parameter or member 'host' not described in 'sdhci_arasan_update_support64b'
>  drivers/mmc/host/sdhci-of-arasan.c:1394: warning: Function parameter or member 'value' not described in 'sdhci_arasan_update_support64b'
>  drivers/mmc/host/sdhci-msm.c:1887:6: warning: no previous prototype for ‘sdhci_msm_dump_vendor_regs’ [-Wmissing-prototypes]
> 
> Cc: Adrian Hunter <adrian.hunter@intel.com>
> Cc: Michal Simek <michal.simek@xilinx.com>
> Cc: Xiaobo Xie <X.Xie@freescale.com>
> Cc: Anton Vorontsov <avorontsov@ru.mvista.com>
> Cc: Soeren Brinkmann <soren.brinkmann@xilinx.com>
> Signed-off-by: Lee Jones <lee.jones@linaro.org>
> ---
>  drivers/mmc/host/sdhci-of-arasan.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/mmc/host/sdhci-of-arasan.c b/drivers/mmc/host/sdhci-of-arasan.c
> index db9b544465cda..260e06e238f7e 100644
> --- a/drivers/mmc/host/sdhci-of-arasan.c
> +++ b/drivers/mmc/host/sdhci-of-arasan.c
> @@ -1388,7 +1388,8 @@ static void sdhci_arasan_unregister_sdclk(struct device *dev)
>   * - For Keem Bay, it is required to clear this bit. Its default value is 1'b1.
>   *   Keem Bay does not support 64-bit access.
>   *
> - * @host		The sdhci_host
> + * @host:		The sdhci_host
> + * @value:		The value to write
>   */
>  static void sdhci_arasan_update_support64b(struct sdhci_host *host, u32 value)
>  {
> 

Acked-by: Michal Simek <michal.simek@xilinx.com>

Thanks,
Michal

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

* Re: [PATCH v2 15/15] mmc: host: sdhci-iproc: Do not define 'struct acpi_device_id' when !CONFIG_ACPI
  2020-07-07  6:47   ` [PATCH v2 15/15] mmc: host: sdhci-iproc: Do not define 'struct acpi_device_id' when !CONFIG_ACPI Lee Jones
  2020-07-07 15:47     ` Scott Branden
@ 2020-07-08 13:20     ` Ulf Hansson
  1 sibling, 0 replies; 28+ messages in thread
From: Ulf Hansson @ 2020-07-08 13:20 UTC (permalink / raw)
  To: Lee Jones
  Cc: Linux ARM, Linux Kernel Mailing List, Adrian Hunter, Ray Jui,
	Scott Branden, BCM Kernel Feedback

On Tue, 7 Jul 2020 at 08:47, Lee Jones <lee.jones@linaro.org> wrote:
>
> Since ACPI_PTR() is used to NULLify the value when !CONFIG_ACPI,
> 'struct sdhci_iproc_acpi_ids' becomes defined but unused.
>
> Fixes the following W=1 kernel build warning:
>
>  mmc/host/sdhci-iproc.c:297:36: warning: ‘sdhci_iproc_acpi_ids’ defined but not used [-Wunused-const-variable=]
>
> Cc: Adrian Hunter <adrian.hunter@intel.com>
> Cc: Ray Jui <rjui@broadcom.com>
> Cc: Scott Branden <sbranden@broadcom.com>
> Cc: bcm-kernel-feedback-list@broadcom.com
> Signed-off-by: Lee Jones <lee.jones@linaro.org>

Alright, so I have replaced v1 with this v2 on my next branch, thanks!

Kind regards
Uffe

>
> diff --git a/drivers/mmc/host/sdhci-iproc.c b/drivers/mmc/host/sdhci-iproc.c
> index 225603148d7de..e2d8dfe90077e 100644
> --- a/drivers/mmc/host/sdhci-iproc.c
> +++ b/drivers/mmc/host/sdhci-iproc.c
> @@ -294,12 +294,14 @@ static const struct of_device_id sdhci_iproc_of_match[] = {
>  };
>  MODULE_DEVICE_TABLE(of, sdhci_iproc_of_match);
>
> +#ifdef CONFIG_ACPI
>  static const struct acpi_device_id sdhci_iproc_acpi_ids[] = {
>         { .id = "BRCM5871", .driver_data = (kernel_ulong_t)&iproc_cygnus_data },
>         { .id = "BRCM5872", .driver_data = (kernel_ulong_t)&iproc_data },
>         { /* sentinel */ }
>  };
>  MODULE_DEVICE_TABLE(acpi, sdhci_iproc_acpi_ids);
> +#endif
>
>  static int sdhci_iproc_probe(struct platform_device *pdev)
>  {

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

end of thread, other threads:[~2020-07-08 13:21 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-01 12:46 [PATCH 00/15] Clean-up MMC's W=1 build warnings Lee Jones
2020-07-01 12:46 ` [PATCH 01/15] mmc: core: quirks: Mark fixups as __maybe_unused Lee Jones
2020-07-01 12:46 ` [PATCH 02/15] mmc: core: sdio_io: Provide description for sdio_set_host_pm_flags()'s 'flag' arg Lee Jones
2020-07-01 12:46 ` [PATCH 03/15] mmc: core: regulator: Add missing documetation for 'mmc' and 'ios' Lee Jones
2020-07-01 12:46 ` [PATCH 04/15] mmc: host: sdhci-s3c: Provide documentation for missing struct properties Lee Jones
2020-07-05 23:53   ` Jaehoon Chung
2020-07-01 12:46 ` [PATCH 05/15] mmc: host: mtk-sd: Demote msdc_recheck_sdio_irq() function header Lee Jones
2020-07-01 13:09   ` Matthias Brugger
2020-07-01 12:46 ` [PATCH 06/15] mmc: host: atmel-mci: Provide 2 new and correct 1 existing property description Lee Jones
2020-07-01 12:46 ` [PATCH 07/15] mmc: core: queue: Correct misspelling of 'mq' in mmc_init_request()'s docs Lee Jones
2020-07-01 12:46 ` [PATCH 08/15] mmc: host: dw_mmc-exynos: Add kerneldoc descriptions of for 'dev' args Lee Jones
2020-07-05 23:53   ` Jaehoon Chung
2020-07-01 12:46 ` [PATCH 09/15] mmc: host: rtsx_pci_sdmmc: Remove set but unused variable 'err' Lee Jones
2020-07-01 12:46 ` [PATCH 10/15] mmc: host: rtsx_usb_sdmmc: " Lee Jones
2020-07-01 12:46 ` [PATCH 11/15] mmc: host: sdhci-of-arasan: Correct formatting and provide missing function arg(s) Lee Jones
2020-07-08  7:53   ` Michal Simek
2020-07-01 12:46 ` [PATCH 12/15] mmc: host: sdhci-msm: Staticify local function sdhci_msm_dump_vendor_regs() Lee Jones
2020-07-01 12:47 ` [PATCH 13/15] mmc: host: sdhci-msm: Demote faux kerneldoc header down to basic comment block Lee Jones
2020-07-01 12:47 ` [PATCH 14/15] mmc: host: cqhci: " Lee Jones
2020-07-02  6:43   ` Adrian Hunter
2020-07-01 12:47 ` [PATCH 15/15] mmc: host: sdhci-iproc: Tell the compiler that ACPI functions may not be used Lee Jones
2020-07-02 19:42   ` Scott Branden
2020-07-02 20:13     ` Lee Jones
2020-07-02 20:49       ` Scott Branden
2020-07-07  6:47   ` [PATCH v2 15/15] mmc: host: sdhci-iproc: Do not define 'struct acpi_device_id' when !CONFIG_ACPI Lee Jones
2020-07-07 15:47     ` Scott Branden
2020-07-08 13:20     ` Ulf Hansson
2020-07-07  6:50 ` [PATCH 00/15] Clean-up MMC's W=1 build warnings Ulf Hansson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).