Commit 4afc71c2 authored by Krzysztof Kozlowski's avatar Krzysztof Kozlowski Committed by Damien Le Moal
Browse files

ata: ahci-imx: Fix Wvoid-pointer-to-enum-cast warning



"imxpriv->type" is an enum, thus cast of pointer on 64-bit compile test
with clang W=1 causes:

  ahci_imx.c:872:18: error: cast to smaller integer type 'enum ahci_imx_type' from 'const void *' [-Werror,-Wvoid-pointer-to-enum-cast]

Signed-off-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Signed-off-by: default avatarDamien Le Moal <dlemoal@kernel.org>
parent 602f6612
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -869,7 +869,7 @@ static int imx_ahci_probe(struct platform_device *pdev)
	imxpriv->ahci_pdev = pdev;
	imxpriv->no_device = false;
	imxpriv->first_time = true;
	imxpriv->type = (enum ahci_imx_type)device_get_match_data(dev);
	imxpriv->type = (unsigned long)device_get_match_data(dev);

	imxpriv->sata_clk = devm_clk_get(dev, "sata");
	if (IS_ERR(imxpriv->sata_clk)) {