mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Steffen Trumtrar <s.trumtrar@pengutronix.de>
To: Josh Cartwright <joshc@eso.teric.us>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH v2 0/5] ARM: add support for Zynq
Date: Tue, 19 Mar 2013 14:57:58 +0100	[thread overview]
Message-ID: <20130319135758.GE29295@pengutronix.de> (raw)
In-Reply-To: <20130319125927.GV16050@kryptos>

On Tue, Mar 19, 2013 at 07:59:27AM -0500, Josh Cartwright wrote:
> On Tue, Mar 19, 2013 at 10:21:55AM +0100, Steffen Trumtrar wrote:
> > Hi!
> > 
> > Still nothing fancy. Boots a little faster from SD and has a console.
> > For ethernet the macb-driver works fine,
> 
> I've also found the macb driver works, but it does require a change to
> prevent byteswapping during DMA, have you run into this on the ZedBoard?
> (patch below).

I already sent the same patch :-)
Xilinx decided to use a different reset default than Cadence uses.

> 
> Also, have you thought about how you'll handle the OCM mapping?  For my
> testing, I'm using a PBL image (which contains the lowlevel init), but I
> still need some hook into the decompressed image to remove the OCM
> mapping from the lower address space.  This can't be done during the
> execution of the PBL image, since it's running from OCM.
> 
> As far as I could tell, there was no good way to hook in early to the
> decompressed image.
> 
> I ran into this trying to boot the 14.4 release uImage, since it has a
> load address of 0x8000, and spans the 'hole' at 0x30000 configured out
> of BootROM to be 'Reserved' (writes to here trigger a Data Abort).
> 

You also need that for the mainline kernel. Or it won't even uncompress.


> > but needs to be "freed" from its at91 heritage (meaning: the struct
> > at91_ether_platform_data should be renamed first and defined someplace
> > else than a board.h)
> 
> I'm assuming you've done this, but if not, I've made this change in my
> tree.  For what it's worth, I went with 'struct macb_platform_data' and
> moved it into include/platform_data/macb.h.
> 

Actually, I haven't. If you have a series that renames tree-wide please
post that.

> >
> > Changelog:
> > 	- addressed all comments by Sascha and Josh
> > 	  (some uart stuff, defines, endianess, ...)
> > 	- squashed a little
> > 
> > Regards,
> > Steffen
> 
> -- 8< --
> Subject: [PATCH] macb: disable byte-order translation through DMA
> 
> Packet data already exists in memory in network byte-order.  Prevent the
> GEM from performing endianness translation through DMA.
> 
> Signed-off-by: Josh Cartwright <joshc@eso.teric.us>
> ---
>  drivers/net/macb.c | 1 +
>  drivers/net/macb.h | 2 ++
>  2 files changed, 3 insertions(+)
> 
> diff --git a/drivers/net/macb.c b/drivers/net/macb.c
> index 14a0689..25d1b9f 100644
> --- a/drivers/net/macb.c
> +++ b/drivers/net/macb.c
> @@ -307,6 +307,7 @@ static void macb_configure_dma(struct macb_device *bp)
>  		dmacfg |= GEM_BF(FBLDO, 16);
>  		dmacfg |= GEM_BIT(TXPBMS) | GEM_BF(RXBMS, -1L);
>  		dmacfg |= GEM_BIT(DDRP);
> +		dmacfg &= ~GEM_BIT(ENDIAN);
>  		gem_writel(bp, DMACFG, dmacfg);
>  	}
>  }
> diff --git a/drivers/net/macb.h b/drivers/net/macb.h
> index cadd561..fc4d1a9 100644
> --- a/drivers/net/macb.h
> +++ b/drivers/net/macb.h
> @@ -168,6 +168,8 @@
>  /* Bitfields in DMACFG. */
>  #define GEM_FBLDO_OFFSET			0
>  #define GEM_FBLDO_SIZE				5
> +#define GEM_ENDIAN_OFFSET			7
> +#define GEM_ENDIAN_SIZE				1
>  #define GEM_RXBMS_OFFSET			8
>  #define GEM_RXBMS_SIZE				2
>  #define GEM_TXPBMS_OFFSET			10
> -- 
> 1.8.1.5
> 
> 

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  reply	other threads:[~2013-03-19 13:58 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-19  9:21 Steffen Trumtrar
2013-03-19  9:21 ` [PATCH v2 1/5] serial: Add driver for Cadence UART Steffen Trumtrar
2013-03-19 15:22   ` Jean-Christophe PLAGNIOL-VILLARD
2013-03-19  9:21 ` [PATCH v2 2/5] ARM: zynq: Add new architecture zynq Steffen Trumtrar
2013-03-19 13:05   ` Josh Cartwright
2013-03-19 13:18   ` Josh Cartwright
2013-03-19 13:31     ` Steffen Trumtrar
2013-03-19 15:26   ` Jean-Christophe PLAGNIOL-VILLARD
2013-03-19  9:21 ` [PATCH v2 3/5] ARM: zynq: add clk support for zynq7000 Steffen Trumtrar
2013-03-19 13:29   ` Josh Cartwright
2013-03-19 13:35     ` Steffen Trumtrar
2013-03-19 13:48       ` Josh Cartwright
2013-03-19  9:21 ` [PATCH v2 4/5] ARM: zynq: add zynq fsbl checksum script Steffen Trumtrar
2013-03-19  9:22 ` [PATCH v2 5/5] ARM: zynq: Add support for the Avnet Zedboard Steffen Trumtrar
2013-03-19 13:40   ` Josh Cartwright
2013-03-19 13:47     ` Steffen Trumtrar
2013-03-19 15:28   ` Jean-Christophe PLAGNIOL-VILLARD
2013-03-19 12:59 ` [PATCH v2 0/5] ARM: add support for Zynq Josh Cartwright
2013-03-19 13:57   ` Steffen Trumtrar [this message]
2013-03-19 15:08     ` Josh Cartwright

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=20130319135758.GE29295@pengutronix.de \
    --to=s.trumtrar@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=joshc@eso.teric.us \
    /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