Re: [U-Boot] [PATCH v2] Add support for Bluegiga APX4 Development Kit
On 09/07/2012 15:14, Veli-Pekka Peltola wrote: > This adds support for Bluegiga APX4 Development Kit. It is built around > Freescale i.MX28. Currently supported features are: ethernet, I2C, MMC, > RTC and USB. APX4 has only one ethernet port. > > Signed-off-by: Veli-Pekka Peltola > Signed-off-by: Lauri Hintsala > Cc: Stefano Babic > --- Applied to u-boot-imx, -next branch, thanks. Best regards, Stefano Babic -- = DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sba...@denx.de = ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v2] Add support for Bluegiga APX4 Development Kit
On 07/31/2012 01:26 PM, Stefano Babic wrote: I see no problems in your patch - I will push it into the -next branch. Thanks, We'll continue developing. Lauri ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v2] Add support for Bluegiga APX4 Development Kit
On 09/07/2012 15:14, Veli-Pekka Peltola wrote: > This adds support for Bluegiga APX4 Development Kit. It is built around > Freescale i.MX28. Currently supported features are: ethernet, I2C, MMC, > RTC and USB. APX4 has only one ethernet port. > > Signed-off-by: Veli-Pekka Peltola > Signed-off-by: Lauri Hintsala > Cc: Stefano Babic > --- Hi Veli-Pekka, hi Laurie, sorry for late review. And thanks for the remind ! > Changes after v1 from last December: > - Updating MAINTAINERS file which I missed last time > - Started to use SPL > - Increased size of environment on NAND > - Better commit message > > Our strategy to use fuses differs from other i.MX28 based boards. We store > serial number to CUST3. We don't have ethernet MAC address on fuses so our > customers could use their own address range. If I have some time later this > week or next week, I will do some refactorization on that so we could have > generic OTP reading function. Well, this sounds very promising .. ;-) > > MAINTAINERS|4 + > board/bluegiga/apx4devkit/Makefile | 47 +++ > board/bluegiga/apx4devkit/apx4devkit.c | 150 > board/bluegiga/apx4devkit/spl_boot.c | 164 ++ > board/bluegiga/apx4devkit/u-boot.bd| 14 ++ > boards.cfg |1 + > include/configs/apx4devkit.h | 238 > > 7 files changed, 618 insertions(+) > create mode 100644 board/bluegiga/apx4devkit/Makefile > create mode 100644 board/bluegiga/apx4devkit/apx4devkit.c > create mode 100644 board/bluegiga/apx4devkit/spl_boot.c > create mode 100644 board/bluegiga/apx4devkit/u-boot.bd > create mode 100644 include/configs/apx4devkit.h > > diff --git a/MAINTAINERS b/MAINTAINERS > index 54eeab7..5c3fc6e 100644 > --- a/MAINTAINERS > +++ b/MAINTAINERS > @@ -784,6 +784,10 @@ Linus Walleij > integratorapvarious > integratorcpvarious > > +Veli-Pekka Peltola > + > + apx4devkit i.MX28 > + > Luka Perkov I thought that your entry is not sorted, but really Linus' (and Helmut's before that) are in wrong order. Your is ok. > diff --git a/include/configs/apx4devkit.h b/include/configs/apx4devkit.h > new file mode 100644 > index 000..9e7ead5 > --- /dev/null > +++ b/include/configs/apx4devkit.h > @@ -0,0 +1,238 @@ > +/* > + * Copyright (C) 2012 Bluegiga Technologies Oy > + * > + * Authors: > + * Veli-Pekka Peltola > + * Lauri Hintsala > + * > + * Based on m28evk.h: > + * Copyright (C) 2011 Marek Vasut > + * on behalf of DENX Software Engineering GmbH > + * > + * This program is free software; you can redistribute it and/or > + * modify it under the terms of the GNU General Public License as > + * published by the Free Software Foundation; either version 2 of > + * the License, or (at your option) any later version. > + * > + * This program is distributed in the hope that it will be useful, > + * but WITHOUT ANY WARRANTY; without even the implied warranty of > + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the > + * GNU General Public License for more details. > + */ > +#ifndef __CONFIG_H > +#define __CONFIG_H > + > +#include > + > +/* SoC configurations */ > +#define CONFIG_MX28 /* i.MX28 SoC */ > +#define CONFIG_MXS_GPIO /* GPIO control */ > +#define CONFIG_SYS_HZ1000/* Ticks per second */ > + > +#define MACH_TYPE_APX4DEVKIT 3712 > +#define CONFIG_MACH_TYPE MACH_TYPE_APX4DEVKIT You do not use MACH_TYPE_APX4DEVKIT at all, you could set directly CONFIG_MACH_TYPE. But it is not an issue, and you do not need to resend a new version. I see no problems in your patch - I will push it into the -next branch. Best regards, Stefano Babic -- = DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sba...@denx.de = ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v2] Add support for Bluegiga APX4 Development Kit
Hello Stefano, Could you review the patch? Thanks! Best Regards, Lauri Hintsala On 07/09/2012 04:14 PM, Veli-Pekka Peltola wrote: This adds support for Bluegiga APX4 Development Kit. It is built around Freescale i.MX28. Currently supported features are: ethernet, I2C, MMC, RTC and USB. APX4 has only one ethernet port. Signed-off-by: Veli-Pekka Peltola Signed-off-by: Lauri Hintsala Cc: Stefano Babic --- Changes after v1 from last December: - Updating MAINTAINERS file which I missed last time - Started to use SPL - Increased size of environment on NAND - Better commit message Our strategy to use fuses differs from other i.MX28 based boards. We store serial number to CUST3. We don't have ethernet MAC address on fuses so our customers could use their own address range. If I have some time later this week or next week, I will do some refactorization on that so we could have generic OTP reading function. MAINTAINERS|4 + board/bluegiga/apx4devkit/Makefile | 47 +++ board/bluegiga/apx4devkit/apx4devkit.c | 150 board/bluegiga/apx4devkit/spl_boot.c | 164 ++ board/bluegiga/apx4devkit/u-boot.bd| 14 ++ boards.cfg |1 + include/configs/apx4devkit.h | 238 7 files changed, 618 insertions(+) create mode 100644 board/bluegiga/apx4devkit/Makefile create mode 100644 board/bluegiga/apx4devkit/apx4devkit.c create mode 100644 board/bluegiga/apx4devkit/spl_boot.c create mode 100644 board/bluegiga/apx4devkit/u-boot.bd create mode 100644 include/configs/apx4devkit.h diff --git a/MAINTAINERS b/MAINTAINERS index 54eeab7..5c3fc6e 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -784,6 +784,10 @@ Linus Walleij integratorapvarious integratorcpvarious +Veli-Pekka Peltola + + apx4devkit i.MX28 + Luka Perkov ib62x0 ARM926EJS diff --git a/board/bluegiga/apx4devkit/Makefile b/board/bluegiga/apx4devkit/Makefile new file mode 100644 index 000..68ab8f3 --- /dev/null +++ b/board/bluegiga/apx4devkit/Makefile @@ -0,0 +1,47 @@ +# +# (C) Copyright 2000-2006 +# Wolfgang Denk, DENX Software Engineering, w...@denx.de. +# +# See file CREDITS for list of people who contributed to this +# project. +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation; either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, +# MA 02111-1307 USA +# + +include $(TOPDIR)/config.mk + +LIB= $(obj)lib$(BOARD).o + +ifndef CONFIG_SPL_BUILD +COBJS := apx4devkit.o +else +COBJS := spl_boot.o +endif + +SRCS := $(COBJS:.o=.c) +OBJS := $(addprefix $(obj),$(COBJS)) + +$(LIB):$(obj).depend $(OBJS) + $(call cmd_link_o_target, $(OBJS)) + +# + +# defines $(obj).depend target +include $(SRCTREE)/rules.mk + +sinclude $(obj).depend + +# diff --git a/board/bluegiga/apx4devkit/apx4devkit.c b/board/bluegiga/apx4devkit/apx4devkit.c new file mode 100644 index 000..c89c6aa --- /dev/null +++ b/board/bluegiga/apx4devkit/apx4devkit.c @@ -0,0 +1,150 @@ +/* + * Bluegiga APX4 Development Kit + * + * Copyright (C) 2012 Bluegiga Technologies Oy + * + * Authors: + * Veli-Pekka Peltola + * Lauri Hintsala + * + * Based on m28evk.c: + * Copyright (C) 2011 Marek Vasut + * on behalf of DENX Software Engineering GmbH + * + * See file CREDITS for list of people who contributed to this + * project. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 2 of + * the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +DECLARE_GLOBAL_DATA_PTR; + +/* Functions */ +int board_early_init_f(void) +{ + /* IO0 clock at 480MHz */ + mx28_set_ioclk(MXC_IOCLK0, 48); + /* IO1 cl
[U-Boot] [PATCH v2] Add support for Bluegiga APX4 Development Kit
This adds support for Bluegiga APX4 Development Kit. It is built around Freescale i.MX28. Currently supported features are: ethernet, I2C, MMC, RTC and USB. APX4 has only one ethernet port. Signed-off-by: Veli-Pekka Peltola Signed-off-by: Lauri Hintsala Cc: Stefano Babic --- Changes after v1 from last December: - Updating MAINTAINERS file which I missed last time - Started to use SPL - Increased size of environment on NAND - Better commit message Our strategy to use fuses differs from other i.MX28 based boards. We store serial number to CUST3. We don't have ethernet MAC address on fuses so our customers could use their own address range. If I have some time later this week or next week, I will do some refactorization on that so we could have generic OTP reading function. MAINTAINERS|4 + board/bluegiga/apx4devkit/Makefile | 47 +++ board/bluegiga/apx4devkit/apx4devkit.c | 150 board/bluegiga/apx4devkit/spl_boot.c | 164 ++ board/bluegiga/apx4devkit/u-boot.bd| 14 ++ boards.cfg |1 + include/configs/apx4devkit.h | 238 7 files changed, 618 insertions(+) create mode 100644 board/bluegiga/apx4devkit/Makefile create mode 100644 board/bluegiga/apx4devkit/apx4devkit.c create mode 100644 board/bluegiga/apx4devkit/spl_boot.c create mode 100644 board/bluegiga/apx4devkit/u-boot.bd create mode 100644 include/configs/apx4devkit.h diff --git a/MAINTAINERS b/MAINTAINERS index 54eeab7..5c3fc6e 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -784,6 +784,10 @@ Linus Walleij integratorapvarious integratorcpvarious +Veli-Pekka Peltola + + apx4devkit i.MX28 + Luka Perkov ib62x0 ARM926EJS diff --git a/board/bluegiga/apx4devkit/Makefile b/board/bluegiga/apx4devkit/Makefile new file mode 100644 index 000..68ab8f3 --- /dev/null +++ b/board/bluegiga/apx4devkit/Makefile @@ -0,0 +1,47 @@ +# +# (C) Copyright 2000-2006 +# Wolfgang Denk, DENX Software Engineering, w...@denx.de. +# +# See file CREDITS for list of people who contributed to this +# project. +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License as +# published by the Free Software Foundation; either version 2 of +# the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, +# MA 02111-1307 USA +# + +include $(TOPDIR)/config.mk + +LIB= $(obj)lib$(BOARD).o + +ifndef CONFIG_SPL_BUILD +COBJS := apx4devkit.o +else +COBJS := spl_boot.o +endif + +SRCS := $(COBJS:.o=.c) +OBJS := $(addprefix $(obj),$(COBJS)) + +$(LIB):$(obj).depend $(OBJS) + $(call cmd_link_o_target, $(OBJS)) + +# + +# defines $(obj).depend target +include $(SRCTREE)/rules.mk + +sinclude $(obj).depend + +# diff --git a/board/bluegiga/apx4devkit/apx4devkit.c b/board/bluegiga/apx4devkit/apx4devkit.c new file mode 100644 index 000..c89c6aa --- /dev/null +++ b/board/bluegiga/apx4devkit/apx4devkit.c @@ -0,0 +1,150 @@ +/* + * Bluegiga APX4 Development Kit + * + * Copyright (C) 2012 Bluegiga Technologies Oy + * + * Authors: + * Veli-Pekka Peltola + * Lauri Hintsala + * + * Based on m28evk.c: + * Copyright (C) 2011 Marek Vasut + * on behalf of DENX Software Engineering GmbH + * + * See file CREDITS for list of people who contributed to this + * project. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License as + * published by the Free Software Foundation; either version 2 of + * the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +DECLARE_GLOBAL_DATA_PTR; + +/* Functions */ +int board_early_init_f(void) +{ + /* IO0 clock at 480MHz */ + mx28_set_ioclk(MXC_IOCLK0, 48); + /* IO1 clock at 480MHz */ + mx28_set_ioclk(MXC_IOCLK1, 48); + + /* SSP0 clock at 96MHz */ + mx28_set_sspclk(MXC_SSPCLK0, 96000, 0); + +