From: Li Yang <leoli@freescale.com>
To: jeff@garzik.org
Cc: netdev@vger.kernel.org, linuxppc-dev@ozlabs.org
Subject: [PATCH 1/4] ucc_geth: Change private immrbar_virt_to_phys to generic iopa
Date: Tue, 06 Feb 2007 19:31:33 +0800 [thread overview]
Message-ID: <45C86715.6090600@freescale.com> (raw)
Get rid of private immrbar_virt_to_phys() routine and
use generic iopa().
Signed-off-by: Li Yang <leoli@freescale.com>
---
drivers/net/ucc_geth.c | 29 ++++++-----------------------
1 files changed, 6 insertions(+), 23 deletions(-)
diff --git a/drivers/net/ucc_geth.c b/drivers/net/ucc_geth.c
index 7e4b23c..722a89f 100644
--- a/drivers/net/ucc_geth.c
+++ b/drivers/net/ucc_geth.c
@@ -3065,21 +3065,11 @@ static int ucc_geth_startup(struct ucc_geth_private *ugeth)
endOfRing =
ugeth->p_tx_bd_ring[i] + (ug_info->bdRingLenTx[i] -
1) * sizeof(struct qe_bd);
- if (ugeth->ug_info->uf_info.bd_mem_part == MEM_PART_SYSTEM) {
- out_be32(&ugeth->p_send_q_mem_reg->sqqd[i].bd_ring_base,
- (u32) virt_to_phys(ugeth->p_tx_bd_ring[i]));
- out_be32(&ugeth->p_send_q_mem_reg->sqqd[i].
+ out_be32(&ugeth->p_send_q_mem_reg->sqqd[i].bd_ring_base,
+ iopa((unsigned long)ugeth->p_tx_bd_ring[i]));
+ out_be32(&ugeth->p_send_q_mem_reg->sqqd[i].
last_bd_completed_address,
- (u32) virt_to_phys(endOfRing));
- } else if (ugeth->ug_info->uf_info.bd_mem_part ==
- MEM_PART_MURAM) {
- out_be32(&ugeth->p_send_q_mem_reg->sqqd[i].bd_ring_base,
- (u32) immrbar_virt_to_phys(ugeth->
- p_tx_bd_ring[i]));
- out_be32(&ugeth->p_send_q_mem_reg->sqqd[i].
- last_bd_completed_address,
- (u32) immrbar_virt_to_phys(endOfRing));
- }
+ iopa((unsigned long)endOfRing));
}
/* schedulerbasepointer */
@@ -3331,15 +3321,8 @@ static int ucc_geth_startup(struct ucc_geth_private *ugeth)
/* Setup the table */
/* Assume BD rings are already established */
for (i = 0; i < ug_info->numQueuesRx; i++) {
- if (ugeth->ug_info->uf_info.bd_mem_part == MEM_PART_SYSTEM) {
- out_be32(&ugeth->p_rx_bd_qs_tbl[i].externalbdbaseptr,
- (u32) virt_to_phys(ugeth->p_rx_bd_ring[i]));
- } else if (ugeth->ug_info->uf_info.bd_mem_part ==
- MEM_PART_MURAM) {
- out_be32(&ugeth->p_rx_bd_qs_tbl[i].externalbdbaseptr,
- (u32) immrbar_virt_to_phys(ugeth->
- p_rx_bd_ring[i]));
- }
+ out_be32(&ugeth->p_rx_bd_qs_tbl[i].externalbdbaseptr,
+ iopa((unsigned long)ugeth->p_rx_bd_ring[i]));
/* rest of fields handled by QE */
}
next reply other threads:[~2007-02-06 11:30 UTC|newest]
Thread overview: 40+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-02-06 11:31 Li Yang [this message]
2007-02-06 14:26 ` [PATCH 1/4] ucc_geth: Change private immrbar_virt_to_phys to generic iopa Kumar Gala
2007-02-07 9:34 ` Li Yang-r58472
2007-02-07 16:36 ` Kumar Gala
2007-02-07 16:43 ` Timur Tabi
2007-02-07 16:49 ` Kumar Gala
2007-02-07 17:03 ` Timur Tabi
2007-02-08 5:52 ` Li Yang-r58472
2007-02-08 5:57 ` Kumar Gala
2007-02-08 6:48 ` Li Yang-r58472
2007-02-08 6:53 ` Kumar Gala
2007-02-08 7:06 ` Li Yang-r58472
2007-02-08 7:16 ` Kumar Gala
2007-02-08 7:36 ` Li Yang-r58472
2007-02-08 7:41 ` Kumar Gala
2007-02-08 9:22 ` Discussion about iopa() Li Yang-r58472
2007-02-08 13:41 ` Timur Tabi
2007-02-09 17:08 ` Dan Malek
2007-02-10 2:37 ` Benjamin Herrenschmidt
2007-02-10 18:04 ` Dan Malek
2007-02-10 21:40 ` Benjamin Herrenschmidt
2007-02-10 22:27 ` Dan Malek
2007-02-10 22:42 ` Benjamin Herrenschmidt
2007-02-08 21:26 ` Benjamin Herrenschmidt
2007-02-09 17:13 ` Dan Malek
2007-02-09 22:06 ` Benjamin Herrenschmidt
2007-02-09 22:46 ` Kumar Gala
2007-02-09 22:51 ` Timur Tabi
2007-02-09 23:06 ` Kumar Gala
2007-02-09 23:10 ` Timur Tabi
2007-02-09 23:19 ` Benjamin Herrenschmidt
2007-02-09 23:22 ` Kumar Gala
2007-02-09 23:33 ` Timur Tabi
2007-02-09 23:43 ` Kumar Gala
2007-02-09 17:06 ` Dan Malek
2007-02-08 13:35 ` [PATCH 1/4] ucc_geth: Change private immrbar_virt_to_phys to generic iopa Timur Tabi
2007-02-09 17:22 ` Dan Malek
2007-02-09 17:26 ` Timur Tabi
2007-02-08 13:27 ` Timur Tabi
2007-02-07 0:19 ` Jeff Garzik
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=45C86715.6090600@freescale.com \
--to=leoli@freescale.com \
--cc=jeff@garzik.org \
--cc=linuxppc-dev@ozlabs.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).