linux-next: build failure after merge of the net-next tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,

After merging the net-next tree, today's linux-next build (powepc
ppc44x_defconfig) failed like this:


Caused by commit

  0c65b2b90d13 ("net: of_get_phy_mode: Change API to solve int/unit warnings")

I applied the following patch, but there is probably a nicer and more
complete way to fix this.

From: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
Date: Tue, 5 Nov 2019 19:49:55 +1100
Subject: [PATCH] fix up for "net: of_get_phy_mode: Change API to solve int/unit warnings"

Signed-off-by: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
---
 drivers/net/ethernet/ibm/emac/core.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/ibm/emac/core.c b/drivers/net/ethernet/ibm/emac/core.c
index 2e40425d8a34..8cb682754bd4 100644
--- a/drivers/net/ethernet/ibm/emac/core.c
+++ b/drivers/net/ethernet/ibm/emac/core.c
@@ -2850,6 +2850,7 @@ static int emac_init_config(struct emac_instance *dev)
 	struct device_node *np = dev->ofdev->dev.of_node;
 	const void *p;
 	int err;
+	phy_interface_t phy_mode;
 
 	/* Read config from device-tree */
 	if (emac_read_uint_prop(np, "mal-device", &dev->mal_ph, 1))
@@ -2898,9 +2899,11 @@ static int emac_init_config(struct emac_instance *dev)
 		dev->mal_burst_size = 256;
 
 	/* PHY mode needs some decoding */
-	err = of_get_phy_mode(np, &dev->phy_mode);
+	err = of_get_phy_mode(np, &phy_mode);
 	if (err)
 		dev->phy_mode = PHY_INTERFACE_MODE_NA;
+	else
+		dev->phy_mode = phy_mode;
 
 	/* Check EMAC version */
 	if (of_device_is_compatible(np, "ibm,emac4sync")) {
-- 
2.23.0

-- 
Cheers,
Stephen Rothwell

Attachment: pgpqdxOcZdlmY.pgp
Description: OpenPGP digital signature


[Index of Archives]     [Linux Kernel]     [Linux USB Development]     [Yosemite News]     [Linux SCSI]

  Powered by Linux