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

From: Stephen Rothwell
Date: Tue Jan 29 2019 - 00:17:52 EST


Hi all,

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

drivers/net/ethernet/freescale/enetc/enetc.c: In function 'enetc_alloc_txbdr':
drivers/net/ethernet/freescale/enetc/enetc.c:685:17: error: implicit declaration of function 'vzalloc'; did you mean 'kzalloc'? [-Werror=implicit-function-declaration]
txr->tx_swbd = vzalloc(txr->bd_count * sizeof(struct enetc_tx_swbd));
^~~~~~~
kzalloc
drivers/net/ethernet/freescale/enetc/enetc.c:685:15: warning: assignment to 'struct enetc_tx_swbd *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
txr->tx_swbd = vzalloc(txr->bd_count * sizeof(struct enetc_tx_swbd));
^
drivers/net/ethernet/freescale/enetc/enetc.c:691:3: error: implicit declaration of function 'vfree'; did you mean 'kfree'? [-Werror=implicit-function-declaration]
vfree(txr->tx_swbd);
^~~~~
kfree
drivers/net/ethernet/freescale/enetc/enetc.c: In function 'enetc_alloc_rxbdr':
drivers/net/ethernet/freescale/enetc/enetc.c:749:15: warning: assignment to 'struct enetc_rx_swbd *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
rxr->rx_swbd = vzalloc(rxr->bd_count * sizeof(struct enetc_rx_swbd));
^

Caused by commit

d4fd0404c1c9 ("enetc: Introduce basic PF and VF ENETC ethernet drivers")

I have added the following fix patch for today:

From: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
Date: Tue, 29 Jan 2019 16:13:08 +1100
Subject: [PATCH] enetc: include linux/vmalloc.h for vzalloc etc

Fixes: d4fd0404c1c9 ("enetc: Introduce basic PF and VF ENETC ethernet drivers")
Signed-off-by: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
---
drivers/net/ethernet/freescale/enetc/enetc.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/drivers/net/ethernet/freescale/enetc/enetc.c b/drivers/net/ethernet/freescale/enetc/enetc.c
index 37b587c541ee..5bb9eb35d76d 100644
--- a/drivers/net/ethernet/freescale/enetc/enetc.c
+++ b/drivers/net/ethernet/freescale/enetc/enetc.c
@@ -5,6 +5,7 @@
#include <linux/tcp.h>
#include <linux/udp.h>
#include <linux/of_mdio.h>
+#include <linux/vmalloc.h>

/* ENETC overhead: optional extension BD + 1 BD gap */
#define ENETC_TXBDS_NEEDED(val) ((val) + 2)
--
2.20.1

--
Cheers,
Stephen Rothwell

Attachment: pgpiiO2CuCT9f.pgp
Description: OpenPGP digital signature