Module Name:    src
Committed By:   macallan
Date:           Sat Mar  7 15:35:33 UTC 2015

Modified Files:
        src/sys/arch/mips/ingenic: ingenic_com.c

Log Message:
fix uart parameters, now speed setting actually works


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/mips/ingenic/ingenic_com.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/mips/ingenic/ingenic_com.c
diff -u src/sys/arch/mips/ingenic/ingenic_com.c:1.3 src/sys/arch/mips/ingenic/ingenic_com.c:1.4
--- src/sys/arch/mips/ingenic/ingenic_com.c:1.3	Tue Dec 23 15:12:23 2014
+++ src/sys/arch/mips/ingenic/ingenic_com.c	Sat Mar  7 15:35:33 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: ingenic_com.c,v 1.3 2014/12/23 15:12:23 macallan Exp $ */
+/*	$NetBSD: ingenic_com.c,v 1.4 2015/03/07 15:35:33 macallan Exp $ */
 
 /*-
  * Copyright (c) 2014 Michael Lorenz
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ingenic_com.c,v 1.3 2014/12/23 15:12:23 macallan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ingenic_com.c,v 1.4 2015/03/07 15:35:33 macallan Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -56,7 +56,7 @@ void	ingenic_puts(const char *);
 void	ingenic_putchar(char);
 
 #ifndef CONMODE
-# define CONMODE ((TTYDEF_CFLAG & ~(CSIZE | PARENB)) | CS8)
+# define CONMODE ((TTYDEF_CFLAG & ~(CSIZE | CSTOPB | PARENB)) | CS8)
 #endif
 
 
@@ -163,7 +163,7 @@ ingenic_com_cnattach(void)
 	 * so we just leave alone whatever u-boot set up
 	 * my uplcom is too tolerant to show any difference
 	 */
-	comcnattach1(&regs, -1, 6000000, COM_TYPE_INGENIC, CONMODE);
+	comcnattach1(&regs, 115200, 48000000, COM_TYPE_INGENIC, CONMODE);
 }
 
 static int
@@ -184,7 +184,7 @@ ingenic_com_attach(device_t parent, devi
 	struct com_softc *sc = &isc->sc_com;
 
 	sc->sc_dev = self;
-	sc->sc_frequency = 12000000;
+	sc->sc_frequency = 48000000;
 	sc->sc_type = COM_TYPE_INGENIC;
 	memset(&sc->sc_regs, 0, sizeof(sc->sc_regs));
 	COM_INIT_REGS(sc->sc_regs, &ingenic_com_mbst, regh, 0);

Reply via email to