While novena has it's own board id it's u-boot does not set it.
"setenv machid 10ad" in u-boot will set the novena board id (0x10ad/4269).
-/* $OpenBSD: armv7.c,v 1.6 2015/05/07 01:55:43 jsg Exp $ */
+/* $OpenBSD: armv7.c,v 1.7 2015/05/08 03:38:26 jsg Exp $ */
/*
* Copyright (c) 2005,2008 Dale Rahn <drahn@openbsd.com>
* Copyright (c) 2012-2013 Patrick Wildt <patrick@blueri.se>
{ NULL, 0 }
};
+struct board_dev novena_devs[] = {
+ { "imxccm", 0 },
+ { "imxiomuxc", 0 },
+ { "imxdog", 0 },
+ { "imxocotp", 0 },
+ { "imxuart", 1 },
+ { "imxgpio", 0 },
+ { "imxgpio", 1 },
+ { "imxgpio", 2 },
+ { "imxgpio", 3 },
+ { "imxgpio", 4 },
+ { "imxgpio", 5 },
+ { "imxgpio", 6 },
+ { "imxesdhc", 2 },
+ { "imxesdhc", 3 },
+ { "ehci", 0 },
+ { "imxenet", 0 },
+ { "ahci", 0 },
+ { NULL, 0 }
+};
+
struct board_dev wandboard_devs[] = {
{ "imxccm", 0 },
{ "imxiomuxc", 0 },
imx6_init();
sc->sc_board_devs = utilite_devs;
break;
+ case BOARD_ID_IMX6_NOVENA:
+ printf(": i.MX6 Novena\n");
+ imx6_init();
+ sc->sc_board_devs = novena_devs;
+ break;
case BOARD_ID_IMX6_WANDBOARD:
printf(": i.MX6 Wandboard\n");
imx6_init();
-/* $OpenBSD: armv7var.h,v 1.3 2015/03/29 03:24:17 jsg Exp $ */
+/* $OpenBSD: armv7var.h,v 1.4 2015/05/08 03:38:26 jsg Exp $ */
/*
* Copyright (c) 2005,2008 Dale Rahn <drahn@openbsd.com>
* Copyright (c) 2012-2013 Patrick Wildt <patrick@blueri.se>
#define BOARD_ID_IMX6_SABRELITE 3769
#define BOARD_ID_IMX6_SABRESD 3980
#define BOARD_ID_SUN4I_A10 4104
+#define BOARD_ID_IMX6_NOVENA 4269
#define BOARD_ID_IMX6_UTILITE 4273
#define BOARD_ID_SUN7I_A20 4283
#define BOARD_ID_IMX6_WANDBOARD 4412
-/* $OpenBSD: imx_machdep.c,v 1.11 2015/03/29 03:24:17 jsg Exp $ */
+/* $OpenBSD: imx_machdep.c,v 1.12 2015/05/08 03:38:26 jsg Exp $ */
/*
* Copyright (c) 2013 Sylvestre Gallon <ccna.syl@gmail.com>
*
/* UART2 */
case BOARD_ID_IMX6_SABRELITE:
case BOARD_ID_IMX6_UDOO:
+ case BOARD_ID_IMX6_NOVENA:
paddr = 0x021e8000;
break;
/* UART4 */
amptimer_frequency = 396 * 1000 * 1000;
printf("board type: Utilite\n");
break;
+ case BOARD_ID_IMX6_NOVENA:
+ amptimer_frequency = 396 * 1000 * 1000;
+ printf("board type: Novena\n");
+ break;
case BOARD_ID_IMX6_WANDBOARD:
amptimer_frequency = 396 * 1000 * 1000;
printf("board type: Wandboard\n");
-/* $OpenBSD: imxenet.c,v 1.12 2015/03/29 03:24:17 jsg Exp $ */
+/* $OpenBSD: imxenet.c,v 1.13 2015/05/08 03:38:26 jsg Exp $ */
/*
* Copyright (c) 2012-2013 Patrick Wildt <patrick@blueri.se>
*
#define ENET_WANDBOARD_PHY 1
#define ENET_PHYFLEX_PHY 3
#define ENET_PHYFLEX_PHY_RST (2*32+23)
+#define ENET_NOVENA_PHY 7
+#define ENET_NOVENA_PHY_RST (2*32+23)
#define HREAD4(sc, reg) \
(bus_space_read_4((sc)->sc_iot, (sc)->sc_ioh, (reg)))
imxgpio_set_bit(ENET_UDOO_PHY_RST);
delay(1000 * 100);
break;
+ case BOARD_ID_IMX6_NOVENA:
+ imxgpio_clear_bit(ENET_NOVENA_PHY_RST);
+ imxgpio_set_dir(ENET_NOVENA_PHY_RST, IMXGPIO_DIR_OUT);
+ delay(1000 * 10);
+ imxgpio_set_bit(ENET_NOVENA_PHY_RST);
+ delay(100);
+ break;
}
/* reset the controller */
case BOARD_ID_IMX6_UTILITE:
phy = ENET_UTILITE_PHY;
break;
+ case BOARD_ID_IMX6_NOVENA:
+ phy = ENET_NOVENA_PHY;
+ break;
case BOARD_ID_IMX6_WANDBOARD:
phy = ENET_WANDBOARD_PHY;
break;
break;
case BOARD_ID_IMX6_PHYFLEX:
case BOARD_ID_IMX6_SABRELITE: /* Micrel KSZ9021 */
+ case BOARD_ID_IMX6_NOVENA: /* Micrel KSZ9021 */
/* prefer master mode */
imxenet_miibus_writereg(dev, phy, 0x9, 0x1f00);
-/* $OpenBSD: imxesdhc.c,v 1.6 2015/03/29 03:24:17 jsg Exp $ */
+/* $OpenBSD: imxesdhc.c,v 1.7 2015/05/08 03:38:26 jsg Exp $ */
/*
* Copyright (c) 2009 Dale Rahn <drahn@openbsd.org>
* Copyright (c) 2006 Uwe Stuehler <uwe@openbsd.org>
}
imxgpio_set_dir(gpio, IMXGPIO_DIR_IN);
return imxgpio_get_bit(gpio) ? 0 : 1;
+ case BOARD_ID_IMX6_NOVENA:
+ switch (sc->unit) {
+ case 2:
+ gpio = 0*32 + 4;
+ break;
+ /* no card detect for uSD */
+ case 3:
+ return 1;
+ default:
+ return 0;
+ }
+ imxgpio_set_dir(gpio, IMXGPIO_DIR_IN);
+ return imxgpio_get_bit(gpio) ? 0 : 1;
case BOARD_ID_IMX6_WANDBOARD:
switch (sc->unit) {
case 0:
-/* $OpenBSD: imxgpio.c,v 1.4 2015/01/02 01:57:33 jsg Exp $ */
+/* $OpenBSD: imxgpio.c,v 1.5 2015/05/08 03:38:26 jsg Exp $ */
/*
* Copyright (c) 2007,2009 Dale Rahn <drahn@openbsd.org>
* Copyright (c) 2012-2013 Patrick Wildt <patrick@blueri.se>
switch (board_id) {
case BOARD_ID_IMX6_CUBOXI:
case BOARD_ID_IMX6_HUMMINGBOARD:
+ case BOARD_ID_IMX6_NOVENA:
case BOARD_ID_IMX6_PHYFLEX:
case BOARD_ID_IMX6_SABRELITE:
case BOARD_ID_IMX6_UDOO:
switch (board_id) {
case BOARD_ID_IMX6_CUBOXI:
case BOARD_ID_IMX6_HUMMINGBOARD:
+ case BOARD_ID_IMX6_NOVENA:
case BOARD_ID_IMX6_PHYFLEX:
case BOARD_ID_IMX6_SABRELITE:
case BOARD_ID_IMX6_UDOO: