* [PATCH v2.6.26] ucc_geth: Fix arguments to dma map/unmap functions
@ 2008-05-02 18:01 Andy Fleming
2008-05-06 16:18 ` Jeff Garzik
0 siblings, 1 reply; 5+ messages in thread
From: Andy Fleming @ 2008-05-02 18:01 UTC (permalink / raw)
To: jgarzik; +Cc: netdev, Andy Fleming
We were passing NULL as the device. When we actually start supporting
more interesting memory configurations, this will break things, so
we proactively are fixing the bug.
Signed-off-by: Andy Fleming <afleming@freescale.com>
---
drivers/net/ucc_geth.c | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/drivers/net/ucc_geth.c b/drivers/net/ucc_geth.c
index b3bbb2d..28e6450 100644
--- a/drivers/net/ucc_geth.c
+++ b/drivers/net/ucc_geth.c
@@ -237,7 +237,7 @@ static struct sk_buff *get_new_skb(struct ucc_geth_private *ugeth,
skb->dev = ugeth->dev;
out_be32(&((struct qe_bd __iomem *)bd)->buf,
- dma_map_single(NULL,
+ dma_map_single(&ugeth->dev->dev,
skb->data,
ugeth->ug_info->uf_info.max_rx_buf_length +
UCC_GETH_RX_DATA_BUF_ALIGNMENT,
@@ -2158,7 +2158,7 @@ static void ucc_geth_memclean(struct ucc_geth_private *ugeth)
continue;
for (j = 0; j < ugeth->ug_info->bdRingLenTx[i]; j++) {
if (ugeth->tx_skbuff[i][j]) {
- dma_unmap_single(NULL,
+ dma_unmap_single(&ugeth->dev->dev,
in_be32(&((struct qe_bd __iomem *)bd)->buf),
(in_be32((u32 __iomem *)bd) &
BD_LENGTH_MASK),
@@ -2186,7 +2186,7 @@ static void ucc_geth_memclean(struct ucc_geth_private *ugeth)
bd = ugeth->p_rx_bd_ring[i];
for (j = 0; j < ugeth->ug_info->bdRingLenRx[i]; j++) {
if (ugeth->rx_skbuff[i][j]) {
- dma_unmap_single(NULL,
+ dma_unmap_single(&ugeth->dev->dev,
in_be32(&((struct qe_bd __iomem *)bd)->buf),
ugeth->ug_info->
uf_info.max_rx_buf_length +
@@ -3406,7 +3406,8 @@ static int ucc_geth_start_xmit(struct sk_buff *skb, struct net_device *dev)
/* set up the buffer descriptor */
out_be32(&((struct qe_bd __iomem *)bd)->buf,
- dma_map_single(NULL, skb->data, skb->len, DMA_TO_DEVICE));
+ dma_map_single(&ugeth->dev->dev, skb->data,
+ skb->len, DMA_TO_DEVICE));
/* printk(KERN_DEBUG"skb->data is 0x%x\n",skb->data); */
--
1.5.4.GIT
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v2.6.26] ucc_geth: Fix arguments to dma map/unmap functions
2008-05-02 18:01 Andy Fleming
@ 2008-05-06 16:18 ` Jeff Garzik
2008-05-06 21:21 ` Andy Fleming
0 siblings, 1 reply; 5+ messages in thread
From: Jeff Garzik @ 2008-05-06 16:18 UTC (permalink / raw)
To: Andy Fleming; +Cc: netdev
Andy Fleming wrote:
> We were passing NULL as the device. When we actually start supporting
> more interesting memory configurations, this will break things, so
> we proactively are fixing the bug.
>
> Signed-off-by: Andy Fleming <afleming@freescale.com>
> ---
> drivers/net/ucc_geth.c | 9 +++++----
> 1 files changed, 5 insertions(+), 4 deletions(-)
ACK but failed to apply
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2.6.26] ucc_geth: Fix arguments to dma map/unmap functions
2008-05-06 16:18 ` Jeff Garzik
@ 2008-05-06 21:21 ` Andy Fleming
0 siblings, 0 replies; 5+ messages in thread
From: Andy Fleming @ 2008-05-06 21:21 UTC (permalink / raw)
To: Jeff Garzik; +Cc: netdev
On May 6, 2008, at 11:18, Jeff Garzik wrote:
> Andy Fleming wrote:
>> We were passing NULL as the device. When we actually start
>> supporting
>> more interesting memory configurations, this will break things, so
>> we proactively are fixing the bug.
>> Signed-off-by: Andy Fleming <afleming@freescale.com>
>> ---
>> drivers/net/ucc_geth.c | 9 +++++----
>> 1 files changed, 5 insertions(+), 4 deletions(-)
>
> ACK but failed to apply
Hmm...I think I got my patches sent out in the wrong order. I think
if you try this patch again, it will apply, now that you've applied
the ucc_geth sparse patch. I just rebased my tree against netdev/
upstream, and it applies without any problems. Sorry, next time I'll
make sure to number my patches when there's a dependency.
Andy
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v2.6.26] ucc_geth: Fix arguments to dma map/unmap functions
@ 2008-05-15 22:00 Andy Fleming
2008-05-22 10:21 ` Jeff Garzik
0 siblings, 1 reply; 5+ messages in thread
From: Andy Fleming @ 2008-05-15 22:00 UTC (permalink / raw)
To: jgarzik; +Cc: netdev, Andy Fleming
We were passing NULL as the device. When we actually start supporting
more interesting memory configurations, this will break things, so
we proactively are fixing the bug.
Signed-off-by: Andy Fleming <afleming@freescale.com>
---
drivers/net/ucc_geth.c | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/drivers/net/ucc_geth.c b/drivers/net/ucc_geth.c
index b3bbb2d..28e6450 100644
--- a/drivers/net/ucc_geth.c
+++ b/drivers/net/ucc_geth.c
@@ -237,7 +237,7 @@ static struct sk_buff *get_new_skb(struct ucc_geth_private *ugeth,
skb->dev = ugeth->dev;
out_be32(&((struct qe_bd __iomem *)bd)->buf,
- dma_map_single(NULL,
+ dma_map_single(&ugeth->dev->dev,
skb->data,
ugeth->ug_info->uf_info.max_rx_buf_length +
UCC_GETH_RX_DATA_BUF_ALIGNMENT,
@@ -2158,7 +2158,7 @@ static void ucc_geth_memclean(struct ucc_geth_private *ugeth)
continue;
for (j = 0; j < ugeth->ug_info->bdRingLenTx[i]; j++) {
if (ugeth->tx_skbuff[i][j]) {
- dma_unmap_single(NULL,
+ dma_unmap_single(&ugeth->dev->dev,
in_be32(&((struct qe_bd __iomem *)bd)->buf),
(in_be32((u32 __iomem *)bd) &
BD_LENGTH_MASK),
@@ -2186,7 +2186,7 @@ static void ucc_geth_memclean(struct ucc_geth_private *ugeth)
bd = ugeth->p_rx_bd_ring[i];
for (j = 0; j < ugeth->ug_info->bdRingLenRx[i]; j++) {
if (ugeth->rx_skbuff[i][j]) {
- dma_unmap_single(NULL,
+ dma_unmap_single(&ugeth->dev->dev,
in_be32(&((struct qe_bd __iomem *)bd)->buf),
ugeth->ug_info->
uf_info.max_rx_buf_length +
@@ -3406,7 +3406,8 @@ static int ucc_geth_start_xmit(struct sk_buff *skb, struct net_device *dev)
/* set up the buffer descriptor */
out_be32(&((struct qe_bd __iomem *)bd)->buf,
- dma_map_single(NULL, skb->data, skb->len, DMA_TO_DEVICE));
+ dma_map_single(&ugeth->dev->dev, skb->data,
+ skb->len, DMA_TO_DEVICE));
/* printk(KERN_DEBUG"skb->data is 0x%x\n",skb->data); */
--
1.5.4.GIT
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v2.6.26] ucc_geth: Fix arguments to dma map/unmap functions
2008-05-15 22:00 [PATCH v2.6.26] ucc_geth: Fix arguments to dma map/unmap functions Andy Fleming
@ 2008-05-22 10:21 ` Jeff Garzik
0 siblings, 0 replies; 5+ messages in thread
From: Jeff Garzik @ 2008-05-22 10:21 UTC (permalink / raw)
To: Andy Fleming; +Cc: netdev
Andy Fleming wrote:
> We were passing NULL as the device. When we actually start supporting
> more interesting memory configurations, this will break things, so
> we proactively are fixing the bug.
>
> Signed-off-by: Andy Fleming <afleming@freescale.com>
> ---
> drivers/net/ucc_geth.c | 9 +++++----
> 1 files changed, 5 insertions(+), 4 deletions(-)
applied
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2008-05-22 10:21 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-05-15 22:00 [PATCH v2.6.26] ucc_geth: Fix arguments to dma map/unmap functions Andy Fleming
2008-05-22 10:21 ` Jeff Garzik
-- strict thread matches above, loose matches on Subject: below --
2008-05-02 18:01 Andy Fleming
2008-05-06 16:18 ` Jeff Garzik
2008-05-06 21:21 ` Andy Fleming
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).