lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 30 Mar 2009 12:53:14 -0600
From:	Grant Likely <grant.likely@...retlab.ca>
To:	netdev@...r.kernel.org, linuxppc-dev@...abs.org,
	David Miller <davem@...emloft.net>
Subject: [PATCH] net/fec_mpc52xx: fix BUG on missing dma_ops

From: Grant Likely <grant.likely@...retlab.ca>

The driver triggers a BUG_ON() when allocating DMA buffers if the
arch/powerpc dma_ops from the of_platform device are not copied
into net_device structure.

Signed-off-by: Grant Likely <grant.likely@...retlab.ca>
---
David, do you want to pick this one up right away, or should I merge it
through Ben's powerpc tree?

g.

 drivers/net/fec_mpc52xx.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)


diff --git a/drivers/net/fec_mpc52xx.c b/drivers/net/fec_mpc52xx.c
index 049b0a7..215207d 100644
--- a/drivers/net/fec_mpc52xx.c
+++ b/drivers/net/fec_mpc52xx.c
@@ -928,6 +928,9 @@ mpc52xx_fec_probe(struct of_device *op, const struct of_device_id *match)
 	if (!request_mem_region(mem.start, sizeof(struct mpc52xx_fec), DRIVER_NAME))
 		return -EBUSY;
 
+	/* Copy the PowerPC dma_ops from the of_device */
+	set_dma_ops(&ndev->dev, get_dma_ops(&op->dev));
+
 	/* Init ether ndev with what we have */
 	ndev->open		= mpc52xx_fec_open;
 	ndev->stop		= mpc52xx_fec_close;

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ