diff mbox series

[v1] ahci: imx: fix the build warning

Message ID 1521599821-16354-1-git-send-email-hongxing.zhu@nxp.com
State Not Applicable
Delegated to: David Miller
Headers show
Series [v1] ahci: imx: fix the build warning | expand

Commit Message

Hongxing Zhu March 21, 2018, 2:37 a.m. UTC
Add the default as the last entry to fix the following
build warning introduced by commit.
e5878732a521 ("ahci: imx: add the imx6qp ahci sata support")

drivers/ata/ahci_imx.c: In function 'imx_sata_disable':
drivers/ata/ahci_imx.c:478:2: warning: enumeration value 'AHCI_IMX53'
not handled in switch [-Wswitch]
  switch (imxpriv->type) {
	    ^~~~~~

Signed-off-by: Richard Zhu <hongxing.zhu@nxp.com>
---
 drivers/ata/ahci_imx.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

Tejun Heo March 21, 2018, 3:05 p.m. UTC | #1
On Wed, Mar 21, 2018 at 10:37:01AM +0800, Richard Zhu wrote:
> Add the default as the last entry to fix the following
> build warning introduced by commit.
> e5878732a521 ("ahci: imx: add the imx6qp ahci sata support")
> 
> drivers/ata/ahci_imx.c: In function 'imx_sata_disable':
> drivers/ata/ahci_imx.c:478:2: warning: enumeration value 'AHCI_IMX53'
> not handled in switch [-Wswitch]
>   switch (imxpriv->type) {
> 	    ^~~~~~
> 
> Signed-off-by: Richard Zhu <hongxing.zhu@nxp.com>

Applied to libata/for-4.17.

Thanks.
diff mbox series

Patch

diff --git a/drivers/ata/ahci_imx.c b/drivers/ata/ahci_imx.c
index 577458f..1c69e88 100644
--- a/drivers/ata/ahci_imx.c
+++ b/drivers/ata/ahci_imx.c
@@ -490,6 +490,9 @@  static void imx_sata_disable(struct ahci_host_priv *hpriv)
 				   IMX6Q_GPR13_SATA_MPLL_CLK_EN,
 				   !IMX6Q_GPR13_SATA_MPLL_CLK_EN);
 		break;
+
+	default:
+		break;
 	}
 
 	clk_disable_unprepare(imxpriv->sata_ref_clk);