Re: CVS commit: src/sys/arch/aarch64/aarch64

2020-09-24 Thread Nick Hudson

On 24/09/2020 10:04, Ryo Shimizu wrote:

Module Name:src
Committed By:   ryo
Date:   Thu Sep 24 09:04:38 UTC 2020

Modified Files:
src/sys/arch/aarch64/aarch64: bus_space_asm_generic.S

Log Message:
fix bugs in *_bs_rm_8_swap(). it was only reading 4 bytes, not 8 bytes.


I think there's another one that needs fixing...

Nick

Index: sys/arch/aarch64/aarch64/bus_space_asm_generic.S
===
RCS file: /cvsroot/src/sys/arch/aarch64/aarch64/bus_space_asm_generic.S,v
retrieving revision 1.3
diff -u -p -r1.3 bus_space_asm_generic.S
--- sys/arch/aarch64/aarch64/bus_space_asm_generic.S	24 Sep 2020 09:04:38 -	1.3
+++ sys/arch/aarch64/aarch64/bus_space_asm_generic.S	24 Sep 2020 10:11:18 -
@@ -225,7 +225,7 @@ ENTRY_NP(\funcname\()_bs_rm_4_swap)
 	ldr	w8, [x0, #BS_STRIDE]
 	lsl	x8, x2, x8	/* offset <<= tag->bs_stride */
 1:
-	ldrh	w9, [x1, x8]
+	ldr	w9, [x1, x8]
 	subs	x4, x4, #1	/* count-- */
 	rev	w9, w9
 	str	w9, [x3], #4



Re: CVS commit: src/sys/dev/acpi

2020-06-07 Thread Nick Hudson

On 10/08/2018 18:11, Taylor R Campbell wrote:

Module Name:src
Committed By:   riastradh
Date:   Fri Aug 10 17:11:56 UTC 2018

Modified Files:
src/sys/dev/acpi: acpi_bat.c

Log Message:
Don't hold up boot: defer acpibat(4) inquiry until threads are running.

ok jmcneill@


This makes an old hp510 laptop reset without warning around about dhcpcd
time.

I don't if it matters but the battery doesn't charge anymore.

Nick


Re: CVS commit: src/sys/dev/usb

2020-03-18 Thread Nick Hudson
On 18/03/2020 11:33, Robert Elz wrote:
> Module Name:  src
> Committed By: kre
> Date: Wed Mar 18 11:33:32 UTC 2020
>
> Modified Files:
>   src/sys/dev/usb: if_aue.c
>
> Log Message:
> This was still not correct,. USB_DEBUG is what mattered, not AUE_DEBUG,
> the two are orthogonal.

They're not orthogonal...

http://src.illumos.org/source/xref/netbsd-src/sys/dev/usb/files.usb#25

25  defflag opt_usb.h   AUE_DEBUG: USB_DEBUG


Just saying.

Nick


Re: CVS commit: src/sys/arch/mips/mips

2020-03-13 Thread Nick Hudson

On 13/03/2020 03:49, Jason R Thorpe wrote:

Module Name:src
Committed By:   thorpej
Date:   Fri Mar 13 03:49:39 UTC 2020

Modified Files:
src/sys/arch/mips/mips: bus_dma.c

Log Message:
Allow len == 0 in bus_dmamap_sync().

XXX pullup-9


The assertion that len is not 0 in arm bus_dma.c has found several bugs
over the years.

Just saying.

Nick


Re: CVS commit: src/sys/arch/arm/arm32

2020-02-22 Thread Nick Hudson

On 21/02/2020 23:27, Maya Rashish wrote:
[...]


Index: src/sys/arch/arm/arm32/bus_dma.c
diff -u src/sys/arch/arm/arm32/bus_dma.c:1.118 
src/sys/arch/arm/arm32/bus_dma.c:1.119
--- src/sys/arch/arm/arm32/bus_dma.c:1.118  Tue Nov  5 10:21:31 2019
+++ src/sys/arch/arm/arm32/bus_dma.cFri Feb 21 23:27:06 2020

[...]


@@ -404,7 +404,7 @@ _bus_dmamap_create(bus_dma_tag_t t, bus_
  #ifdef DEBUG_DMA
printf("dmamap_create:map=%p\n", map);
  #endif/* DEBUG_DMA */
-   return 0;
+   return error;
  }

  /*



This isn't correct for the case where _ARM32_NEED_BUS_DMA_BOUNCE isn't
defined.

I'll fix it.

Nick


Re: CVS commit: src/sys/arch/arm

2020-02-04 Thread Nick Hudson

On 05/02/2020 07:37, Nick Hudson wrote:

Module Name:src
Committed By:   skrll
Date:   Wed Feb  5 07:37:36 UTC 2020

Modified Files:
src/sys/arch/arm/arm: cpufunc.c
src/sys/arch/arm/arm32: armv7_generic_space.c pmap.c
src/sys/arch/arm/conf: Makefile.arm
src/sys/arch/arm/include/arm32: pmap.h

Log Message:
Fix the armv[67] memory attributes for uncached memory.  Previously it was
mapped as strongly-ordered which meant that unaligned accesses would fault.

armv7_generic_bs_map now maps pages with PMAP_DEV which is treated as SO

bus_dma continues to use PMAP_NOCACHE as appropriate, but this now get
mapped to the correct memory attribute bits for armv[67]

DEVMAP_ENTRY usees a new flag PTE_DEV.

The workaround for the unaligned access faults is now removed.

XXX Other armv[67] boards bus_space implementations should be checked.
XXX There is scope to reduce the difference to aarch64


I should have added...

Thanks to Rin Okuyama for doing a lot of testing of this.

Nick


Re: CVS commit: src/sys/arch/aarch64

2020-01-30 Thread Nick Hudson




On 30/01/2020 10:04, Maxime Villard wrote:

Le 28/01/2020 à 19:39, Nick Hudson a écrit :

On 28/01/2020 17:47, Maxime Villard wrote:

@@ -460,8 +460,7 @@ cpu_setup_id(struct cpu_info *ci)

   id->ac_aa64mmfr0 = reg_id_aa64mmfr0_el1_read();
   id->ac_aa64mmfr1 = reg_id_aa64mmfr1_el1_read();
-    /* Only in ARMv8.2. */
-    id->ac_aa64mmfr2 = 0 /* reg_id_aa64mmfr2_el1_read() */;
+    id->ac_aa64mmfr2 = reg_id_aa64mmfr2_el1_read();

   id->ac_mvfr0 = reg_mvfr0_el1_read();
   id->ac_mvfr1 = reg_mvfr1_el1_read();


I didn't ok this bit...


Verily you did; I sent you this patch as-is two weeks ago.


OK, well, I don't remember it :) I'm must be getting old.




This needs to be conditional on the CPU we're running on.


ID_AA64MMFR2_EL1 is res0 on < ARMv8.2, reading it is therefore not a
problem.


OK.

Thanks,

Nick


Re: CVS commit: src/sys/arch/aarch64

2020-01-28 Thread Nick Hudson

On 28/01/2020 17:47, Maxime Villard wrote:

@@ -460,8 +460,7 @@ cpu_setup_id(struct cpu_info *ci)

id->ac_aa64mmfr0 = reg_id_aa64mmfr0_el1_read();
id->ac_aa64mmfr1 = reg_id_aa64mmfr1_el1_read();
-   /* Only in ARMv8.2. */
-   id->ac_aa64mmfr2 = 0 /* reg_id_aa64mmfr2_el1_read() */;
+   id->ac_aa64mmfr2 = reg_id_aa64mmfr2_el1_read();

id->ac_mvfr0 = reg_mvfr0_el1_read();
id->ac_mvfr1 = reg_mvfr1_el1_read();


I didn't ok this bit...

This needs to be conditional on the CPU we're running on.

Thanks,
Nick


Re: CVS commit: src/sys/sys

2020-01-12 Thread Nick Hudson

On 12/01/2020 13:19, Andrew Doran wrote:

Module Name:src
Committed By:   ad
Date:   Sun Jan 12 13:19:32 UTC 2020

Modified Files:
src/sys/sys: param.h

Log Message:
Bump MIN_LWP_ALIGNMENT to 64.


Should aarch64/mips define MIN_LWP_ALIGNMENT as 128 as they have CPUs
that have this cache line size?

Thanks,
Nick


Re: CVS commit: src/sys/arch/zaurus/conf

2020-01-05 Thread Nick Hudson



On 05/01/2020 13:47, Izumi Tsutsui wrote:
[snip]


My patch allows COPTS to be overridden as


http://src.illumos.org/source/xref/netbsd-src/sys/conf/Makefile.kern.inc#69

has

69 DEFCOPTS?=   -O2
70 COPTS?=  ${DEFCOPTS}

which I believe allows COPTS to be overridden by

makeoptions COPTS="..."


If it's users' responsibility to explicitly add "-mapcs-frame" in COPTS
when they want to build a kernel with both COPTS="-Os" and options DDB,
it's okay for me.  (I'm afraid zaurus GENERIC needs -Os in near future)


I changed the use of COPTS to CFLAGS - hopefully this fixes all problems.

Sorry for the breakage.

Nick


Re: CVS commit: src/sys/arch/zaurus/conf

2020-01-05 Thread Nick Hudson

On 05/01/2020 13:31, Martin Husemann wrote:

On Sun, Jan 05, 2020 at 01:21:46PM +, Nick Hudson wrote:

Yes, I understand that. What I don't understand is how my
sys/arch/arm/conf/Makefile.arm change affects the zaurus INSTALL kernel
size because INSTALL specifically disables DDB and my patch is
conditional on DDB


It did only break GENERIC in the releng builds (AFAICT).


Ah, my bad.

Nick




Re: CVS commit: src/sys/arch/zaurus/conf

2020-01-05 Thread Nick Hudson




On 04/01/2020 16:32, Izumi Tsutsui wrote:

The problem is caused by sys/arch/arm/conf/Makefile.arm.
It defines "COPTS+= -mapcs-frame" in recent rev 1.52
   
http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/arch/arm/conf/Makefile.arm#rev1.52
but MI sys/conf/Makefile.kern.inc defines COPTS+=-O2
only if COPTS is empty.


I don't see how as sys/arch/zaurus/conf/INSTALL doesn't define DDB.


On zaurus GENERIC also has a size restriction (due to bootloader).


Yes, I understand that. What I don't understand is how my
sys/arch/arm/conf/Makefile.arm change affects the zaurus INSTALL kernel
size because INSTALL specifically disables DDB and my patch is
conditional on DDB





This affects not only zaurus but all arm ports?


Maybe this patch is better?


I wonder if it will work as expected if COPTS+="-Os" is
already specified with options DDB, if -mapcs-frame
is mandatory for DDB. But if -fno-omit-frame-pointer
in Makefile.amd64 may have the similar problem,
it's also okay for arm, IMO.

Maybe it's less probematic to add a new option (COPTS_MD etc.)
and add it to COPTS after including Makefile.kern.inc,
i.e. in "(11) Appending make options." in Makefile.arm?


My patch allows COPTS to be overridden as


http://src.illumos.org/source/xref/netbsd-src/sys/conf/Makefile.kern.inc#69

has

69 DEFCOPTS?=   -O2
70 COPTS?=  ${DEFCOPTS}

which I believe allows COPTS to be overridden by

makeoptions COPTS="..."

Nick


Re: CVS commit: src/sys/arch/zaurus/conf

2020-01-04 Thread Nick Hudson



On 03/01/2020 18:42, Izumi Tsutsui wrote:

I wrote:

The missing COPTS was an accident or fallout from some other changes?


Isn't it specified in -current?


The problem is caused by sys/arch/arm/conf/Makefile.arm.
It defines "COPTS+= -mapcs-frame" in recent rev 1.52
  http://cvsweb.netbsd.org/bsdweb.cgi/src/sys/arch/arm/conf/Makefile.arm#rev1.52
but MI sys/conf/Makefile.kern.inc defines COPTS+=-O2
only if COPTS is empty.


I don't see how as sys/arch/zaurus/conf/INSTALL doesn't define DDB.


This affects not only zaurus but all arm ports?


Maybe this patch is better?

Nick
Index: sys/arch/arm/conf/Makefile.arm
===
RCS file: /cvsroot/src/sys/arch/arm/conf/Makefile.arm,v
retrieving revision 1.52
diff -u -p -r1.52 Makefile.arm
--- sys/arch/arm/conf/Makefile.arm  2 Jan 2020 14:33:55 -   1.52
+++ sys/arch/arm/conf/Makefile.arm  4 Jan 2020 15:02:40 -
@@ -78,7 +78,7 @@ CFLAGS+=  -mno-unaligned-access
 
 OPT_DDB=   %DDB%
 .if !empty(OPT_DDB) && ${HAVE_GCC:U0} > 0
-COPTS+=-mapcs-frame
+DEFCOPTS=  -O2 -mapcs-frame
 .endif
 
 ##


CVS commit: src/sys/arch

2019-11-24 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Nov 24 11:23:16 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: genassym.cf
src/sys/arch/arm/arm32: genassym.cf

Log Message:
corect #include order


To generate a diff of this commit:
cvs rdiff -u -r1.14 -r1.15 src/sys/arch/aarch64/aarch64/genassym.cf
cvs rdiff -u -r1.81 -r1.82 src/sys/arch/arm/arm32/genassym.cf

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



CVS commit: src/sys/arch

2019-11-24 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Nov 24 11:23:16 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: genassym.cf
src/sys/arch/arm/arm32: genassym.cf

Log Message:
corect #include order


To generate a diff of this commit:
cvs rdiff -u -r1.14 -r1.15 src/sys/arch/aarch64/aarch64/genassym.cf
cvs rdiff -u -r1.81 -r1.82 src/sys/arch/arm/arm32/genassym.cf

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/aarch64/aarch64/genassym.cf
diff -u src/sys/arch/aarch64/aarch64/genassym.cf:1.14 src/sys/arch/aarch64/aarch64/genassym.cf:1.15
--- src/sys/arch/aarch64/aarch64/genassym.cf:1.14	Sat Sep  7 11:15:25 2019
+++ src/sys/arch/aarch64/aarch64/genassym.cf	Sun Nov 24 11:23:16 2019
@@ -1,4 +1,4 @@
-# $NetBSD: genassym.cf,v 1.14 2019/09/07 11:15:25 ryo Exp $
+# $NetBSD: genassym.cf,v 1.15 2019/11/24 11:23:16 skrll Exp $
 #-
 # Copyright (c) 2014 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -28,6 +28,12 @@
 # POSSIBILITY OF SUCH DAMAGE.
 #-
 
+if defined(_KERNEL_OPT)
+include "opt_multiprocessor.h"
+include "opt_compat_netbsd.h"
+include "opt_execfmt.h"
+endif
+
 include 
 include 
 include 
@@ -52,12 +58,6 @@ include 
 include 
 include 
 
-if defined(_KERNEL_OPT)
-include "opt_multiprocessor.h"
-include "opt_compat_netbsd.h"
-include "opt_execfmt.h"
-endif
-
 define	__HAVE_FAST_SOFTINTS	1
 
 #ifdef __HAVE_PIC_FAST_SOFTINTS

Index: src/sys/arch/arm/arm32/genassym.cf
diff -u src/sys/arch/arm/arm32/genassym.cf:1.81 src/sys/arch/arm/arm32/genassym.cf:1.82
--- src/sys/arch/arm/arm32/genassym.cf:1.81	Sat Nov 23 19:40:34 2019
+++ src/sys/arch/arm/arm32/genassym.cf	Sun Nov 24 11:23:16 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: genassym.cf,v 1.81 2019/11/23 19:40:34 ad Exp $
+#	$NetBSD: genassym.cf,v 1.82 2019/11/24 11:23:16 skrll Exp $
 
 # Copyright (c) 1982, 1990 The Regents of the University of California.
 # All rights reserved.
@@ -30,6 +30,12 @@
 # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 # SUCH DAMAGE.
 
+if defined(_KERNEL_OPT)
+include "opt_multiprocessor.h"
+include "opt_compat_netbsd.h"
+include "opt_execfmt.h"
+endif
+
 include 
 include 
 include 
@@ -55,12 +61,6 @@ include 
 include 
 include 
 
-if defined(_KERNEL_OPT)
-include "opt_multiprocessor.h"
-include "opt_compat_netbsd.h"
-include "opt_execfmt.h"
-endif
-
 define	__PROG32		1
 ifdef __ARM_FIQ_INDIRECT
 define	__ARM_FIQ_INDIRECT	1



CVS commit: src/sys/arch/arm/fdt

2019-11-24 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Nov 24 11:10:13 UTC 2019

Modified Files:
src/sys/arch/arm/fdt: gic_fdt.c

Log Message:
Remove unnecessary cast and wrap a long line.


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/sys/arch/arm/fdt/gic_fdt.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/arm/fdt/gic_fdt.c
diff -u src/sys/arch/arm/fdt/gic_fdt.c:1.17 src/sys/arch/arm/fdt/gic_fdt.c:1.18
--- src/sys/arch/arm/fdt/gic_fdt.c:1.17	Fri Jul 19 12:14:15 2019
+++ src/sys/arch/arm/fdt/gic_fdt.c	Sun Nov 24 11:10:12 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: gic_fdt.c,v 1.17 2019/07/19 12:14:15 hkenken Exp $ */
+/* $NetBSD: gic_fdt.c,v 1.18 2019/11/24 11:10:12 skrll Exp $ */
 
 /*-
  * Copyright (c) 2015-2017 Jared McNeill 
@@ -29,7 +29,7 @@
 #include "pci.h"
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: gic_fdt.c,v 1.17 2019/07/19 12:14:15 hkenken Exp $");
+__KERNEL_RCSID(0, "$NetBSD: gic_fdt.c,v 1.18 2019/11/24 11:10:12 skrll Exp $");
 
 #include 
 #include 
@@ -226,9 +226,9 @@ gic_fdt_attach_v2m(struct gic_fdt_softc 
 	if (gic_v2m_init(frame, sc->sc_gicdev, sc->sc_v2m_count++) != 0) {
 		aprint_error_dev(sc->sc_gicdev, "failed to initialize GICv2m\n");
 	} else {
-		aprint_normal_dev(sc->sc_gicdev, "GICv2m @ %#" PRIx64 ", SPIs %u-%u\n",
-		(uint64_t)frame->frame_reg, frame->frame_base,
-		frame->frame_base + frame->frame_count);
+		aprint_normal_dev(sc->sc_gicdev, "GICv2m @ %#" PRIx64
+		", SPIs %u-%u\n", frame->frame_reg,
+		frame->frame_base, frame->frame_base + frame->frame_count);
 	}
 }
 #endif



CVS commit: src/sys/arch/arm/fdt

2019-11-24 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Nov 24 11:10:13 UTC 2019

Modified Files:
src/sys/arch/arm/fdt: gic_fdt.c

Log Message:
Remove unnecessary cast and wrap a long line.


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/sys/arch/arm/fdt/gic_fdt.c

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



CVS commit: src/sys/arch/arm/imx

2019-11-24 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Nov 24 11:07:19 UTC 2019

Modified Files:
src/sys/arch/arm/imx: imx6_usbphy.c
src/sys/arch/arm/imx/fdt: imx6_gpio.c imx6_sdhc.c imx6_usb.c
imx6_usbphy.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/imx/imx6_usbphy.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/imx/fdt/imx6_gpio.c \
src/sys/arch/arm/imx/fdt/imx6_usb.c
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/imx/fdt/imx6_sdhc.c
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/imx/fdt/imx6_usbphy.c

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



CVS commit: src/sys/arch/arm/imx

2019-11-24 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Nov 24 11:07:19 UTC 2019

Modified Files:
src/sys/arch/arm/imx: imx6_usbphy.c
src/sys/arch/arm/imx/fdt: imx6_gpio.c imx6_sdhc.c imx6_usb.c
imx6_usbphy.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/imx/imx6_usbphy.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/imx/fdt/imx6_gpio.c \
src/sys/arch/arm/imx/fdt/imx6_usb.c
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/imx/fdt/imx6_sdhc.c
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/imx/fdt/imx6_usbphy.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/arm/imx/imx6_usbphy.c
diff -u src/sys/arch/arm/imx/imx6_usbphy.c:1.2 src/sys/arch/arm/imx/imx6_usbphy.c:1.3
--- src/sys/arch/arm/imx/imx6_usbphy.c:1.2	Thu Jun 20 08:16:19 2019
+++ src/sys/arch/arm/imx/imx6_usbphy.c	Sun Nov 24 11:07:19 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: imx6_usbphy.c,v 1.2 2019/06/20 08:16:19 hkenken Exp $	*/
+/*	$NetBSD: imx6_usbphy.c,v 1.3 2019/11/24 11:07:19 skrll Exp $	*/
 
 /*
  * Copyright (c) 2017  Genetec Corporation.  All rights reserved.
@@ -32,7 +32,7 @@
 
 #include 
 
-__KERNEL_RCSID(1, "$NetBSD: imx6_usbphy.c,v 1.2 2019/06/20 08:16:19 hkenken Exp $");
+__KERNEL_RCSID(1, "$NetBSD: imx6_usbphy.c,v 1.3 2019/11/24 11:07:19 skrll Exp $");
 
 #include 
 #include 
@@ -144,8 +144,8 @@ imx6_usbphy_attach(device_t parent, devi
 
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d",
-		(uint64_t)addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d",
+		addr, error);
 		return;
 	}
 

Index: src/sys/arch/arm/imx/fdt/imx6_gpio.c
diff -u src/sys/arch/arm/imx/fdt/imx6_gpio.c:1.2 src/sys/arch/arm/imx/fdt/imx6_gpio.c:1.3
--- src/sys/arch/arm/imx/fdt/imx6_gpio.c:1.2	Mon Aug 19 03:45:51 2019
+++ src/sys/arch/arm/imx/fdt/imx6_gpio.c	Sun Nov 24 11:07:19 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: imx6_gpio.c,v 1.2 2019/08/19 03:45:51 hkenken Exp $	*/
+/*	$NetBSD: imx6_gpio.c,v 1.3 2019/11/24 11:07:19 skrll Exp $	*/
 /*-
  * Copyright (c) 2019 Genetec Corporation.  All rights reserved.
  * Written by Hashimoto Kenichi for Genetec Corporation.
@@ -25,7 +25,7 @@
  * SUCH DAMAGE.
  */
 #include 
-__KERNEL_RCSID(0, "$NetBSD: imx6_gpio.c,v 1.2 2019/08/19 03:45:51 hkenken Exp $");
+__KERNEL_RCSID(0, "$NetBSD: imx6_gpio.c,v 1.3 2019/11/24 11:07:19 skrll Exp $");
 
 #include "opt_fdt.h"
 #include "gpio.h"
@@ -107,7 +107,7 @@ imxgpio_attach(device_t parent, device_t
 
 	error = bus_space_map(faa->faa_bst, addr, size, 0, );
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d", (uint64_t)addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d", addr, error);
 		return;
 	}
 
Index: src/sys/arch/arm/imx/fdt/imx6_usb.c
diff -u src/sys/arch/arm/imx/fdt/imx6_usb.c:1.2 src/sys/arch/arm/imx/fdt/imx6_usb.c:1.3
--- src/sys/arch/arm/imx/fdt/imx6_usb.c:1.2	Mon Aug 19 03:45:51 2019
+++ src/sys/arch/arm/imx/fdt/imx6_usb.c	Sun Nov 24 11:07:19 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: imx6_usb.c,v 1.2 2019/08/19 03:45:51 hkenken Exp $	*/
+/*	$NetBSD: imx6_usb.c,v 1.3 2019/11/24 11:07:19 skrll Exp $	*/
 /*-
  * Copyright (c) 2019 Genetec Corporation.  All rights reserved.
  * Written by Hashimoto Kenichi for Genetec Corporation.
@@ -25,7 +25,7 @@
  * SUCH DAMAGE.
  */
 #include 
-__KERNEL_RCSID(0, "$NetBSD: imx6_usb.c,v 1.2 2019/08/19 03:45:51 hkenken Exp $");
+__KERNEL_RCSID(0, "$NetBSD: imx6_usb.c,v 1.3 2019/11/24 11:07:19 skrll Exp $");
 
 #include "opt_fdt.h"
 
@@ -111,7 +111,7 @@ imx6_usb_attach(device_t parent, device_
 
 	error = bus_space_map(bst, addr, size, 0, );
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d", (uint64_t)addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d", addr, error);
 		return;
 	}
 

Index: src/sys/arch/arm/imx/fdt/imx6_sdhc.c
diff -u src/sys/arch/arm/imx/fdt/imx6_sdhc.c:1.4 src/sys/arch/arm/imx/fdt/imx6_sdhc.c:1.5
--- src/sys/arch/arm/imx/fdt/imx6_sdhc.c:1.4	Wed Oct 23 05:20:52 2019
+++ src/sys/arch/arm/imx/fdt/imx6_sdhc.c	Sun Nov 24 11:07:19 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: imx6_sdhc.c,v 1.4 2019/10/23 05:20:52 hkenken Exp $	*/
+/*	$NetBSD: imx6_sdhc.c,v 1.5 2019/11/24 11:07:19 skrll Exp $	*/
 /*-
  * Copyright (c) 2019 Genetec Corporation.  All rights reserved.
  * Written by Hashimoto Kenichi for Genetec Corporation.
@@ -25,7 +25,7 @@
  * SUCH DAMAGE.
  */
 #include 
-__KERNEL_RCSID(0, "$NetBSD: imx6_sdhc.c,v 1.4 2019/10/23 05:20:52 hkenken Exp $");
+__KERNEL_RCSID(0, "$NetBSD: imx6_sdhc.c,v 1.5 2019/11/24 11:07:19 skrll Exp $");
 
 #include "opt_fdt.h"
 
@@ -133,7 +133,7 @@ imx6_sdhc_attach(device_t parent, device
 	sc->sc_bst = faa->faa_bst;
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d", (uint64_t)addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d", 

CVS commit: src/sys/arch/arm/ti

2019-11-24 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Nov 24 09:37:05 UTC 2019

Modified Files:
src/sys/arch/arm/ti: if_cpsw.c

Log Message:
Fix KERNHIST build (and simplify)


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/ti/if_cpsw.c

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



CVS commit: src/sys/arch/arm/ti

2019-11-24 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Nov 24 09:37:05 UTC 2019

Modified Files:
src/sys/arch/arm/ti: if_cpsw.c

Log Message:
Fix KERNHIST build (and simplify)


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/ti/if_cpsw.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/arm/ti/if_cpsw.c
diff -u src/sys/arch/arm/ti/if_cpsw.c:1.8 src/sys/arch/arm/ti/if_cpsw.c:1.9
--- src/sys/arch/arm/ti/if_cpsw.c:1.8	Sun Nov  3 10:09:04 2019
+++ src/sys/arch/arm/ti/if_cpsw.c	Sun Nov 24 09:37:05 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_cpsw.c,v 1.8 2019/11/03 10:09:04 jmcneill Exp $	*/
+/*	$NetBSD: if_cpsw.c,v 1.9 2019/11/24 09:37:05 skrll Exp $	*/
 
 /*
  * Copyright (c) 2013 Jonathan A. Kollasch
@@ -53,7 +53,7 @@
  */
 
 #include 
-__KERNEL_RCSID(1, "$NetBSD: if_cpsw.c,v 1.8 2019/11/03 10:09:04 jmcneill Exp $");
+__KERNEL_RCSID(1, "$NetBSD: if_cpsw.c,v 1.9 2019/11/24 09:37:05 skrll Exp $");
 
 #include 
 #include 
@@ -174,19 +174,14 @@ static int cpsw_ale_update_addresses(str
 CFATTACH_DECL_NEW(cpsw, sizeof(struct cpsw_softc),
 cpsw_match, cpsw_attach, cpsw_detach, NULL);
 
-#undef KERNHIST
 #include 
 KERNHIST_DEFINE(cpswhist);
 
-#ifdef KERNHIST
-#define KERNHIST_CALLED_5(NAME, i, j, k, l) \
-do { \
-	_kernhist_call = atomic_inc_uint_nv(&_kernhist_cnt); \
-	KERNHIST_LOG(NAME, "called! %x %x %x %x", i, j, k, l); \
-} while (/*CONSTCOND*/ 0)
-#else
-#define KERNHIST_CALLED_5(NAME, i, j, k, l)
-#endif
+#define CPSWHIST_CALLARGS(A,B,C,D)	do {	\
+	KERNHIST_CALLARGS(cpswhist, "%jx %jx %jx %jx",			\
+		(uintptr_t)(A), (uintptr_t)(B), (uintptr_t)(C), (uintptr_t)(D));\
+	} while (0)
+
 
 static inline u_int
 cpsw_txdesc_adjust(u_int x, int y)
@@ -219,7 +214,7 @@ cpsw_set_txdesc_next(struct cpsw_softc *
 	const bus_size_t o = sizeof(struct cpsw_cpdma_bd) * i + 0;
 
 	KERNHIST_FUNC(__func__);
-	KERNHIST_CALLED_5(cpswhist, sc, i, n, 0);
+	CPSWHIST_CALLARGS(sc, i, n, 0);
 
 	bus_space_write_4(sc->sc_bst, sc->sc_bsh_txdescs, o, n);
 }
@@ -230,7 +225,7 @@ cpsw_set_rxdesc_next(struct cpsw_softc *
 	const bus_size_t o = sizeof(struct cpsw_cpdma_bd) * i + 0;
 
 	KERNHIST_FUNC(__func__);
-	KERNHIST_CALLED_5(cpswhist, sc, i, n, 0);
+	CPSWHIST_CALLARGS(sc, i, n, 0);
 
 	bus_space_write_4(sc->sc_bst, sc->sc_bsh_rxdescs, o, n);
 }
@@ -244,7 +239,7 @@ cpsw_get_txdesc(struct cpsw_softc * cons
 	const bus_size_t c = __arraycount(bdp->word);
 
 	KERNHIST_FUNC(__func__);
-	KERNHIST_CALLED_5(cpswhist, sc, i, bdp, 0);
+	CPSWHIST_CALLARGS(sc, i, bdp, 0);
 
 	bus_space_read_region_4(sc->sc_bst, sc->sc_bsh_txdescs, o, dp, c);
 	KERNHIST_LOG(cpswhist, "%08x %08x %08x %08x\n",
@@ -260,7 +255,7 @@ cpsw_set_txdesc(struct cpsw_softc * cons
 	const bus_size_t c = __arraycount(bdp->word);
 
 	KERNHIST_FUNC(__func__);
-	KERNHIST_CALLED_5(cpswhist, sc, i, bdp, 0);
+	CPSWHIST_CALLARGS(sc, i, bdp, 0);
 	KERNHIST_LOG(cpswhist, "%08x %08x %08x %08x\n",
 	dp[0], dp[1], dp[2], dp[3]);
 
@@ -276,7 +271,7 @@ cpsw_get_rxdesc(struct cpsw_softc * cons
 	const bus_size_t c = __arraycount(bdp->word);
 
 	KERNHIST_FUNC(__func__);
-	KERNHIST_CALLED_5(cpswhist, sc, i, bdp, 0);
+	CPSWHIST_CALLARGS(sc, i, bdp, 0);
 
 	bus_space_read_region_4(sc->sc_bst, sc->sc_bsh_rxdescs, o, dp, c);
 
@@ -293,7 +288,7 @@ cpsw_set_rxdesc(struct cpsw_softc * cons
 	const bus_size_t c = __arraycount(bdp->word);
 
 	KERNHIST_FUNC(__func__);
-	KERNHIST_CALLED_5(cpswhist, sc, i, bdp, 0);
+	CPSWHIST_CALLARGS(sc, i, bdp, 0);
 	KERNHIST_LOG(cpswhist, "%08x %08x %08x %08x\n",
 	dp[0], dp[1], dp[2], dp[3]);
 
@@ -607,7 +602,7 @@ cpsw_start(struct ifnet *ifp)
 	u_int mlen;
 
 	KERNHIST_FUNC(__func__);
-	KERNHIST_CALLED_5(cpswhist, sc, 0, 0, 0);
+	CPSWHIST_CALLARGS(sc, 0, 0, 0);
 
 	if (__predict_false((ifp->if_flags & (IFF_RUNNING | IFF_OACTIVE)) !=
 	IFF_RUNNING)) {
@@ -1140,7 +1135,7 @@ cpsw_rxintr(void *arg)
 	u_int len, off;
 
 	KERNHIST_FUNC(__func__);
-	KERNHIST_CALLED_5(cpswhist, sc, 0, 0, 0);
+	CPSWHIST_CALLARGS(sc, 0, 0, 0);
 
 	for (;;) {
 		KASSERT(sc->sc_rxhead < CPSW_NRXDESCS);
@@ -1225,7 +1220,7 @@ cpsw_txintr(void *arg)
 	u_int cpi;
 
 	KERNHIST_FUNC(__func__);
-	KERNHIST_CALLED_5(cpswhist, sc, 0, 0, 0);
+	CPSWHIST_CALLARGS(sc, 0, 0, 0);
 
 	KASSERT(sc->sc_txrun);
 



CVS commit: src/sys/dev/fdt

2019-11-24 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Nov 24 09:34:38 UTC 2019

Modified Files:
src/sys/dev/fdt: fdt_port.c

Log Message:
Fix build


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/dev/fdt/fdt_port.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/dev/fdt/fdt_port.c
diff -u src/sys/dev/fdt/fdt_port.c:1.3 src/sys/dev/fdt/fdt_port.c:1.4
--- src/sys/dev/fdt/fdt_port.c:1.3	Sat Nov 23 18:53:05 2019
+++ src/sys/dev/fdt/fdt_port.c	Sun Nov 24 09:34:38 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: fdt_port.c,v 1.3 2019/11/23 18:53:05 jmcneill Exp $	*/
+/*	$NetBSD: fdt_port.c,v 1.4 2019/11/24 09:34:38 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2018 The NetBSD Foundation, Inc.
@@ -38,7 +38,7 @@
 
 #include 
 
-__KERNEL_RCSID(1, "$NetBSD: fdt_port.c,v 1.3 2019/11/23 18:53:05 jmcneill Exp $");
+__KERNEL_RCSID(1, "$NetBSD: fdt_port.c,v 1.4 2019/11/24 09:34:38 skrll Exp $");
 
 #include 
 #include 
@@ -257,7 +257,7 @@ fdt_ports_register(struct fdt_device_por
 	int port_phandle, child;
 	int i;
 	char buf[20];
-	uint64_t id;
+	bus_addr_t id;
 
 	ports->dp_dev = self;
 	SLIST_INSERT_HEAD(_port_devices, ports, dp_list);



CVS commit: src/sys/dev/fdt

2019-11-24 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Nov 24 09:34:38 UTC 2019

Modified Files:
src/sys/dev/fdt: fdt_port.c

Log Message:
Fix build


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/dev/fdt/fdt_port.c

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



CVS commit: src/sys/uvm

2019-11-06 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Thu Nov  7 07:45:14 UTC 2019

Modified Files:
src/sys/uvm: uvm_bio.c

Log Message:
Fix a UVMHIST_LOG format broken in 1.91


To generate a diff of this commit:
cvs rdiff -u -r1.99 -r1.100 src/sys/uvm/uvm_bio.c

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



CVS commit: src/sys/uvm

2019-11-06 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Thu Nov  7 07:45:14 UTC 2019

Modified Files:
src/sys/uvm: uvm_bio.c

Log Message:
Fix a UVMHIST_LOG format broken in 1.91


To generate a diff of this commit:
cvs rdiff -u -r1.99 -r1.100 src/sys/uvm/uvm_bio.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/uvm/uvm_bio.c
diff -u src/sys/uvm/uvm_bio.c:1.99 src/sys/uvm/uvm_bio.c:1.100
--- src/sys/uvm/uvm_bio.c:1.99	Sun Dec  9 20:45:37 2018
+++ src/sys/uvm/uvm_bio.c	Thu Nov  7 07:45:14 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: uvm_bio.c,v 1.99 2018/12/09 20:45:37 jdolecek Exp $	*/
+/*	$NetBSD: uvm_bio.c,v 1.100 2019/11/07 07:45:14 skrll Exp $	*/
 
 /*
  * Copyright (c) 1998 Chuck Silvers.
@@ -34,7 +34,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: uvm_bio.c,v 1.99 2018/12/09 20:45:37 jdolecek Exp $");
+__KERNEL_RCSID(0, "$NetBSD: uvm_bio.c,v 1.100 2019/11/07 07:45:14 skrll Exp $");
 
 #include "opt_uvmhist.h"
 #include "opt_ubc.h"
@@ -713,7 +713,7 @@ ubc_release(void *va, int flags)
 			inactive);
 		}
 	}
-	UVMHIST_LOG(ubchist, "umap %cw#jxp refs %jd", (uintptr_t)umap,
+	UVMHIST_LOG(ubchist, "umap %#jx refs %jd", (uintptr_t)umap,
 	umap->refcount, 0, 0);
 	mutex_exit(ubc_object.uobj.vmobjlock);
 }



CVS commit: src/external/gpl3

2019-10-29 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Tue Oct 29 07:57:29 UTC 2019

Modified Files:
src/external/gpl3/binutils.old/dist/ld/emulparams: hppanbsd.sh
src/external/gpl3/binutils/dist/ld/emulparams: hppanbsd.sh

Log Message:
G/C


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 \
src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh
cvs rdiff -u -r1.1.1.1 -r1.2 \
src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh

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



CVS commit: src/external/gpl3

2019-10-29 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Tue Oct 29 07:57:29 UTC 2019

Modified Files:
src/external/gpl3/binutils.old/dist/ld/emulparams: hppanbsd.sh
src/external/gpl3/binutils/dist/ld/emulparams: hppanbsd.sh

Log Message:
G/C


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 \
src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh
cvs rdiff -u -r1.1.1.1 -r1.2 \
src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh

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

Modified files:

Index: src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh
diff -u src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh:1.5 src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh:1.6
--- src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh:1.5	Sat Apr 14 15:49:45 2018
+++ src/external/gpl3/binutils.old/dist/ld/emulparams/hppanbsd.sh	Tue Oct 29 07:57:29 2019
@@ -1,6 +1,3 @@
-# If you change this file, please also look at files which source this one:
-# hppaobsd.sh
-
 . ${srcdir}/emulparams/hppalinux.sh
 
 OUTPUT_FORMAT="elf32-hppa-netbsd"

Index: src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh
diff -u src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh:1.1.1.1 src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh:1.2
--- src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh:1.1.1.1	Tue Aug 18 10:16:42 2009
+++ src/external/gpl3/binutils/dist/ld/emulparams/hppanbsd.sh	Tue Oct 29 07:57:29 2019
@@ -1,6 +1,3 @@
-# If you change this file, please also look at files which source this one:
-# hppaobsd.sh
-
 . ${srcdir}/emulparams/hppalinux.sh
 
 OUTPUT_FORMAT="elf32-hppa-netbsd"



CVS commit: src/sys/arch/aarch64/aarch64

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 12:25:43 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: locore.S

Log Message:
Avoid overlap between BP and last AP stack. AP stacks are now in order of
increasing address order.

Spotted by and idea from mlelstv.


To generate a diff of this commit:
cvs rdiff -u -r1.42 -r1.43 src/sys/arch/aarch64/aarch64/locore.S

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



CVS commit: src/sys/arch/aarch64/aarch64

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 12:25:43 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: locore.S

Log Message:
Avoid overlap between BP and last AP stack. AP stacks are now in order of
increasing address order.

Spotted by and idea from mlelstv.


To generate a diff of this commit:
cvs rdiff -u -r1.42 -r1.43 src/sys/arch/aarch64/aarch64/locore.S

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/aarch64/aarch64/locore.S
diff -u src/sys/arch/aarch64/aarch64/locore.S:1.42 src/sys/arch/aarch64/aarch64/locore.S:1.43
--- src/sys/arch/aarch64/aarch64/locore.S:1.42	Sat Oct 19 18:04:26 2019
+++ src/sys/arch/aarch64/aarch64/locore.S	Sun Oct 20 12:25:43 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: locore.S,v 1.42 2019/10/19 18:04:26 jmcneill Exp $	*/
+/*	$NetBSD: locore.S,v 1.43 2019/10/20 12:25:43 skrll Exp $	*/
 
 /*
  * Copyright (c) 2017 Ryo Shimizu 
@@ -38,7 +38,7 @@
 #include 
 #include "assym.h"
 
-RCSID("$NetBSD: locore.S,v 1.42 2019/10/19 18:04:26 jmcneill Exp $")
+RCSID("$NetBSD: locore.S,v 1.43 2019/10/20 12:25:43 skrll Exp $")
 
 
 /*#define DEBUG_LOCORE			/* debug print */
@@ -379,9 +379,8 @@ ENTRY_NP(cpu_mpstart)
 	/* set stack pointer for boot */
 	mov	x1, #BOOT_AP_STACKSIZE
 	mul	x1, x1, x27
-	ADDR	x0, bootstk_cpus
-	sub	sp, x0, x1  /* sp = bootstk_cpus-(BOOT_AP_STACKSIZE*cpuindex) */
-
+	ADDR	x0, bootstk
+	add	sp, x0, x1  /* sp = bootstk + (BOOT_AP_STACKSIZE * cpuindex) */
 
 	bl	1f
 1:	CPU_DPRINTREG("PC   = ", lr)
@@ -1038,7 +1037,6 @@ bootstk:
 
 #ifdef MULTIPROCESSOR
 	.space	BOOT_AP_STACKSIZE * (MAXCPUS - 1)
-bootstk_cpus:
 #endif
 
 	.section ".init_pagetable", "aw", %nobits



CVS commit: src/sys

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 08:29:38 UTC 2019

Modified Files:
src/sys/arch/mips/mips: pmap_machdep.c
src/sys/uvm/pmap: pmap.c vmpagemd.h

Log Message:
Define and use VM_PAGEMD_PVLIST_EMPTY_P


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/mips/mips/pmap_machdep.c
cvs rdiff -u -r1.43 -r1.44 src/sys/uvm/pmap/pmap.c
cvs rdiff -u -r1.14 -r1.15 src/sys/uvm/pmap/vmpagemd.h

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



CVS commit: src/sys

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 08:29:38 UTC 2019

Modified Files:
src/sys/arch/mips/mips: pmap_machdep.c
src/sys/uvm/pmap: pmap.c vmpagemd.h

Log Message:
Define and use VM_PAGEMD_PVLIST_EMPTY_P


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/mips/mips/pmap_machdep.c
cvs rdiff -u -r1.43 -r1.44 src/sys/uvm/pmap/pmap.c
cvs rdiff -u -r1.14 -r1.15 src/sys/uvm/pmap/vmpagemd.h

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/mips/pmap_machdep.c
diff -u src/sys/arch/mips/mips/pmap_machdep.c:1.25 src/sys/arch/mips/mips/pmap_machdep.c:1.26
--- src/sys/arch/mips/mips/pmap_machdep.c:1.25	Thu Aug 15 12:24:08 2019
+++ src/sys/arch/mips/mips/pmap_machdep.c	Sun Oct 20 08:29:38 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap_machdep.c,v 1.25 2019/08/15 12:24:08 maxv Exp $	*/
+/*	$NetBSD: pmap_machdep.c,v 1.26 2019/10/20 08:29:38 skrll Exp $	*/
 
 /*-
  * Copyright (c) 1998, 2001 The NetBSD Foundation, Inc.
@@ -67,7 +67,7 @@
 
 #include 
 
-__KERNEL_RCSID(0, "$NetBSD: pmap_machdep.c,v 1.25 2019/08/15 12:24:08 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap_machdep.c,v 1.26 2019/10/20 08:29:38 skrll Exp $");
 
 /*
  *	Manages physical address maps.
@@ -643,7 +643,7 @@ pmap_copy_page(paddr_t src_pa, paddr_t d
 	const register_t src_va = pmap_md_map_ephemeral_page(src_pg, false,
 	VM_PROT_READ, _pte);
 
-	KASSERT(VM_PAGE_TO_MD(dst_pg)->mdpg_first.pv_pmap == NULL);
+	KASSERT(VM_PAGEMD_PVLIST_EMPTY_P(VM_PAGE_TO_MD(dst_pg)));
 	KASSERT(!VM_PAGEMD_EXECPAGE_P(VM_PAGE_TO_MD(dst_pg)));
 	const register_t dst_va = pmap_md_map_ephemeral_page(dst_pg, false,
 	VM_PROT_READ|VM_PROT_WRITE, _pte);

Index: src/sys/uvm/pmap/pmap.c
diff -u src/sys/uvm/pmap/pmap.c:1.43 src/sys/uvm/pmap/pmap.c:1.44
--- src/sys/uvm/pmap/pmap.c:1.43	Sun Oct 20 07:18:22 2019
+++ src/sys/uvm/pmap/pmap.c	Sun Oct 20 08:29:38 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.43 2019/10/20 07:18:22 skrll Exp $	*/
+/*	$NetBSD: pmap.c,v 1.44 2019/10/20 08:29:38 skrll Exp $	*/
 
 /*-
  * Copyright (c) 1998, 2001 The NetBSD Foundation, Inc.
@@ -67,7 +67,7 @@
 
 #include 
 
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.43 2019/10/20 07:18:22 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.44 2019/10/20 08:29:38 skrll Exp $");
 
 /*
  *	Manages physical address maps.
@@ -1045,7 +1045,7 @@ pmap_pte_protect(pmap_t pmap, vaddr_t sv
 		if (pg != NULL && pte_modified_p(pte)) {
 			struct vm_page_md * const mdpg = VM_PAGE_TO_MD(pg);
 			if (VM_PAGEMD_EXECPAGE_P(mdpg)) {
-KASSERT(mdpg->mdpg_first.pv_pmap != NULL);
+KASSERT(!VM_PAGEMD_PVLIST_EMPTY_P(mdpg));
 #ifdef PMAP_VIRTUAL_CACHE_ALIASES
 if (VM_PAGEMD_CACHED_P(mdpg)) {
 #endif

Index: src/sys/uvm/pmap/vmpagemd.h
diff -u src/sys/uvm/pmap/vmpagemd.h:1.14 src/sys/uvm/pmap/vmpagemd.h:1.15
--- src/sys/uvm/pmap/vmpagemd.h:1.14	Sun Oct 20 07:58:21 2019
+++ src/sys/uvm/pmap/vmpagemd.h	Sun Oct 20 08:29:38 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: vmpagemd.h,v 1.14 2019/10/20 07:58:21 skrll Exp $	*/
+/*	$NetBSD: vmpagemd.h,v 1.15 2019/10/20 08:29:38 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -107,6 +107,8 @@ struct vm_page_md {
 #define	VM_PAGEMD_PVLIST_LOCKED_P(mdpg)	pmap_pvlist_locked_p(mdpg)
 #define	VM_PAGEMD_PVLIST_GEN(mdpg)	((mdpg)->mdpg_attrs >> 16)
 
+#define	VM_PAGEMD_PVLIST_EMPTY_P(mdpg)	((mdpg)->mdpg_first.pv_pmap == NULL)
+
 #ifdef _KERNEL
 #if defined(MULTIPROCESSOR) || defined(MODULAR)
 kmutex_t *pmap_pvlist_lock_addr(struct vm_page_md *);



CVS commit: src/sys/uvm/pmap

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 07:58:22 UTC 2019

Modified Files:
src/sys/uvm/pmap: vmpagemd.h

Log Message:
Whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.13 -r1.14 src/sys/uvm/pmap/vmpagemd.h

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

Modified files:

Index: src/sys/uvm/pmap/vmpagemd.h
diff -u src/sys/uvm/pmap/vmpagemd.h:1.13 src/sys/uvm/pmap/vmpagemd.h:1.14
--- src/sys/uvm/pmap/vmpagemd.h:1.13	Sun Oct 20 07:54:29 2019
+++ src/sys/uvm/pmap/vmpagemd.h	Sun Oct 20 07:58:21 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: vmpagemd.h,v 1.13 2019/10/20 07:54:29 skrll Exp $	*/
+/*	$NetBSD: vmpagemd.h,v 1.14 2019/10/20 07:58:21 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -101,11 +101,11 @@ struct vm_page_md {
 #define	VM_PAGEMD_PVLIST_LOCK_INIT(mdpg)	__nothing
 #endif /* MULTIPROCESSOR || MODULAR */
 
-#define	VM_PAGEMD_PVLIST_LOCK(mdpg)		pmap_pvlist_lock(mdpg, 1)
-#define	VM_PAGEMD_PVLIST_READLOCK(mdpg)		pmap_pvlist_lock(mdpg, 0)
-#define	VM_PAGEMD_PVLIST_UNLOCK(mdpg)		pmap_pvlist_unlock(mdpg)
-#define	VM_PAGEMD_PVLIST_LOCKED_P(mdpg)		pmap_pvlist_locked_p(mdpg)
-#define	VM_PAGEMD_PVLIST_GEN(mdpg)		((mdpg)->mdpg_attrs >> 16)
+#define	VM_PAGEMD_PVLIST_LOCK(mdpg)	pmap_pvlist_lock(mdpg, 1)
+#define	VM_PAGEMD_PVLIST_READLOCK(mdpg)	pmap_pvlist_lock(mdpg, 0)
+#define	VM_PAGEMD_PVLIST_UNLOCK(mdpg)	pmap_pvlist_unlock(mdpg)
+#define	VM_PAGEMD_PVLIST_LOCKED_P(mdpg)	pmap_pvlist_locked_p(mdpg)
+#define	VM_PAGEMD_PVLIST_GEN(mdpg)	((mdpg)->mdpg_attrs >> 16)
 
 #ifdef _KERNEL
 #if defined(MULTIPROCESSOR) || defined(MODULAR)



CVS commit: src/sys/uvm/pmap

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 07:58:22 UTC 2019

Modified Files:
src/sys/uvm/pmap: vmpagemd.h

Log Message:
Whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.13 -r1.14 src/sys/uvm/pmap/vmpagemd.h

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



CVS commit: src/sys/uvm/pmap

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 07:54:30 UTC 2019

Modified Files:
src/sys/uvm/pmap: vmpagemd.h

Log Message:
Re-order _P() macros to match bit definitions.  NFCI


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/sys/uvm/pmap/vmpagemd.h

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

Modified files:

Index: src/sys/uvm/pmap/vmpagemd.h
diff -u src/sys/uvm/pmap/vmpagemd.h:1.12 src/sys/uvm/pmap/vmpagemd.h:1.13
--- src/sys/uvm/pmap/vmpagemd.h:1.12	Fri Jul 12 10:39:12 2019
+++ src/sys/uvm/pmap/vmpagemd.h	Sun Oct 20 07:54:29 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: vmpagemd.h,v 1.12 2019/07/12 10:39:12 skrll Exp $	*/
+/*	$NetBSD: vmpagemd.h,v 1.13 2019/10/20 07:54:29 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -75,14 +75,14 @@ typedef struct pv_entry {
 #define	VM_PAGEMD_UNCACHED	__BIT(4)	/* page is mapped uncached */
 #endif
 
+#define	VM_PAGEMD_REFERENCED_P(mdpg)	(((mdpg)->mdpg_attrs & VM_PAGEMD_REFERENCED) != 0)
+#define	VM_PAGEMD_MODIFIED_P(mdpg)	(((mdpg)->mdpg_attrs & VM_PAGEMD_MODIFIED) != 0)
+#define	VM_PAGEMD_POOLPAGE_P(mdpg)	(((mdpg)->mdpg_attrs & VM_PAGEMD_POOLPAGE) != 0)
+#define	VM_PAGEMD_EXECPAGE_P(mdpg)	(((mdpg)->mdpg_attrs & VM_PAGEMD_EXECPAGE) != 0)
 #ifdef PMAP_VIRTUAL_CACHE_ALIASES
 #define	VM_PAGEMD_CACHED_P(mdpg)	(((mdpg)->mdpg_attrs & VM_PAGEMD_UNCACHED) == 0)
 #define	VM_PAGEMD_UNCACHED_P(mdpg)	(((mdpg)->mdpg_attrs & VM_PAGEMD_UNCACHED) != 0)
 #endif
-#define	VM_PAGEMD_MODIFIED_P(mdpg)	(((mdpg)->mdpg_attrs & VM_PAGEMD_MODIFIED) != 0)
-#define	VM_PAGEMD_REFERENCED_P(mdpg)	(((mdpg)->mdpg_attrs & VM_PAGEMD_REFERENCED) != 0)
-#define	VM_PAGEMD_POOLPAGE_P(mdpg)	(((mdpg)->mdpg_attrs & VM_PAGEMD_POOLPAGE) != 0)
-#define	VM_PAGEMD_EXECPAGE_P(mdpg)	(((mdpg)->mdpg_attrs & VM_PAGEMD_EXECPAGE) != 0)
 
 #endif /* !_MODULE */
 



CVS commit: src/sys/uvm/pmap

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 07:54:30 UTC 2019

Modified Files:
src/sys/uvm/pmap: vmpagemd.h

Log Message:
Re-order _P() macros to match bit definitions.  NFCI


To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 src/sys/uvm/pmap/vmpagemd.h

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



CVS commit: src/sys/uvm/pmap

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 07:22:51 UTC 2019

Modified Files:
src/sys/uvm/pmap: pmap_segtab.c

Log Message:
Whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 src/sys/uvm/pmap/pmap_segtab.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/uvm/pmap/pmap_segtab.c
diff -u src/sys/uvm/pmap/pmap_segtab.c:1.10 src/sys/uvm/pmap/pmap_segtab.c:1.11
--- src/sys/uvm/pmap/pmap_segtab.c:1.10	Mon Sep 23 18:20:07 2019
+++ src/sys/uvm/pmap/pmap_segtab.c	Sun Oct 20 07:22:51 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap_segtab.c,v 1.10 2019/09/23 18:20:07 skrll Exp $	*/
+/*	$NetBSD: pmap_segtab.c,v 1.11 2019/10/20 07:22:51 skrll Exp $	*/
 
 /*-
  * Copyright (c) 1998, 2001 The NetBSD Foundation, Inc.
@@ -67,7 +67,7 @@
 
 #include 
 
-__KERNEL_RCSID(0, "$NetBSD: pmap_segtab.c,v 1.10 2019/09/23 18:20:07 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap_segtab.c,v 1.11 2019/10/20 07:22:51 skrll Exp $");
 
 /*
  *	Manages physical address maps.
@@ -139,10 +139,10 @@ pmap_check_stp(pmap_segtab_t *stp, const
 #ifdef DEBUG_NOISY
 			for (size_t j = i; j < PMAP_SEGTABSIZE; j++)
 printf("%s: pm_segtab.seg_tab[%zu] = 0x%p\n",
-   caller, j, stp->seg_tab[j]);
+caller, j, stp->seg_tab[j]);
 #endif
 			panic("%s: pm_segtab.seg_tab[%zu] != 0 (0x%p): %s",
-			  caller, i, stp->seg_tab[i], why);
+			caller, i, stp->seg_tab[i], why);
 		}
 	}
 #endif



CVS commit: src/sys/uvm/pmap

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 07:22:51 UTC 2019

Modified Files:
src/sys/uvm/pmap: pmap_segtab.c

Log Message:
Whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.10 -r1.11 src/sys/uvm/pmap/pmap_segtab.c

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



CVS commit: src/sys/uvm/pmap

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 07:18:22 UTC 2019

Modified Files:
src/sys/uvm/pmap: pmap.c

Log Message:
Remove KASSERT(!VM_PAGEMD_PVLIST_LOCKED_P(mdpg)) - can only assert that it
is owned


To generate a diff of this commit:
cvs rdiff -u -r1.42 -r1.43 src/sys/uvm/pmap/pmap.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/uvm/pmap/pmap.c
diff -u src/sys/uvm/pmap/pmap.c:1.42 src/sys/uvm/pmap/pmap.c:1.43
--- src/sys/uvm/pmap/pmap.c:1.42	Fri Jul 12 10:39:12 2019
+++ src/sys/uvm/pmap/pmap.c	Sun Oct 20 07:18:22 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.42 2019/07/12 10:39:12 skrll Exp $	*/
+/*	$NetBSD: pmap.c,v 1.43 2019/10/20 07:18:22 skrll Exp $	*/
 
 /*-
  * Copyright (c) 1998, 2001 The NetBSD Foundation, Inc.
@@ -67,7 +67,7 @@
 
 #include 
 
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.42 2019/07/12 10:39:12 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.43 2019/10/20 07:18:22 skrll Exp $");
 
 /*
  *	Manages physical address maps.
@@ -1655,7 +1655,6 @@ pmap_clear_modify(struct vm_page *pg)
 	 * flush the VAC first if there is one.
 	 */
 	kpreempt_disable();
-	KASSERT(!VM_PAGEMD_PVLIST_LOCKED_P(mdpg));
 	VM_PAGEMD_PVLIST_READLOCK(mdpg);
 	pmap_pvlist_check(mdpg);
 	for (; pv != NULL; pv = pv_next) {



CVS commit: src/sys/uvm/pmap

2019-10-20 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 20 07:18:22 UTC 2019

Modified Files:
src/sys/uvm/pmap: pmap.c

Log Message:
Remove KASSERT(!VM_PAGEMD_PVLIST_LOCKED_P(mdpg)) - can only assert that it
is owned


To generate a diff of this commit:
cvs rdiff -u -r1.42 -r1.43 src/sys/uvm/pmap/pmap.c

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



CVS commit: src/sys/arch/arm/ti

2019-10-18 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri Oct 18 06:58:06 UTC 2019

Modified Files:
src/sys/arch/arm/ti: ti_com.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/ti/ti_com.c

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



CVS commit: src/sys/arch/arm/ti

2019-10-18 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri Oct 18 06:58:06 UTC 2019

Modified Files:
src/sys/arch/arm/ti: ti_com.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/ti/ti_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/arm/ti/ti_com.c
diff -u src/sys/arch/arm/ti/ti_com.c:1.4 src/sys/arch/arm/ti/ti_com.c:1.5
--- src/sys/arch/arm/ti/ti_com.c:1.4	Sat Dec  8 17:46:10 2018
+++ src/sys/arch/arm/ti/ti_com.c	Fri Oct 18 06:58:06 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: ti_com.c,v 1.4 2018/12/08 17:46:10 thorpej Exp $ */
+/* $NetBSD: ti_com.c,v 1.5 2019/10/18 06:58:06 skrll Exp $ */
 
 /*-
  * Copyright (c) 2017 Jared McNeill 
@@ -28,7 +28,7 @@
 
 #include 
 
-__KERNEL_RCSID(1, "$NetBSD: ti_com.c,v 1.4 2018/12/08 17:46:10 thorpej Exp $");
+__KERNEL_RCSID(1, "$NetBSD: ti_com.c,v 1.5 2019/10/18 06:58:06 skrll Exp $");
 
 #include 
 #include 
@@ -102,7 +102,7 @@ ti_com_attach(device_t parent, device_t 
 
 	error = bus_space_map(bst, addr, size, 0, );
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d", (uint64_t)addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d", addr, error);
 		return;
 	}
 



CVS commit: src/sys/arch/arm/rockchip

2019-10-18 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri Oct 18 06:51:02 UTC 2019

Modified Files:
src/sys/arch/arm/rockchip: rk_pwm.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/rockchip/rk_pwm.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/arm/rockchip/rk_pwm.c
diff -u src/sys/arch/arm/rockchip/rk_pwm.c:1.1 src/sys/arch/arm/rockchip/rk_pwm.c:1.2
--- src/sys/arch/arm/rockchip/rk_pwm.c:1.1	Wed May  1 10:41:33 2019
+++ src/sys/arch/arm/rockchip/rk_pwm.c	Fri Oct 18 06:51:02 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: rk_pwm.c,v 1.1 2019/05/01 10:41:33 jmcneill Exp $ */
+/* $NetBSD: rk_pwm.c,v 1.2 2019/10/18 06:51:02 skrll Exp $ */
 
 /*-
  * Copyright (c) 2019 Jared McNeill 
@@ -28,7 +28,7 @@
 
 #include 
 
-__KERNEL_RCSID(1, "$NetBSD: rk_pwm.c,v 1.1 2019/05/01 10:41:33 jmcneill Exp $");
+__KERNEL_RCSID(1, "$NetBSD: rk_pwm.c,v 1.2 2019/10/18 06:51:02 skrll Exp $");
 
 #include 
 #include 
@@ -221,8 +221,8 @@ rk_pwm_attach(device_t parent, device_t 
 	sc->sc_bst = faa->faa_bst;
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %#" PRIx64 ": %d",
-		(uint64_t)addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d",
+		addr, error);
 		return;
 	}
 



CVS commit: src/sys/arch/arm/rockchip

2019-10-18 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri Oct 18 06:51:02 UTC 2019

Modified Files:
src/sys/arch/arm/rockchip: rk_pwm.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/rockchip/rk_pwm.c

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



CVS commit: src/sys/arch/arm/altera

2019-10-18 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri Oct 18 06:50:08 UTC 2019

Modified Files:
src/sys/arch/arm/altera: cycv_clkmgr.c cycv_dwcmmc.c cycv_rstmgr.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/arm/altera/cycv_clkmgr.c \
src/sys/arch/arm/altera/cycv_dwcmmc.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/altera/cycv_rstmgr.c

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



CVS commit: src/sys/arch/arm/altera

2019-10-18 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri Oct 18 06:50:08 UTC 2019

Modified Files:
src/sys/arch/arm/altera: cycv_clkmgr.c cycv_dwcmmc.c cycv_rstmgr.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/arm/altera/cycv_clkmgr.c \
src/sys/arch/arm/altera/cycv_dwcmmc.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/altera/cycv_rstmgr.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/arm/altera/cycv_clkmgr.c
diff -u src/sys/arch/arm/altera/cycv_clkmgr.c:1.3 src/sys/arch/arm/altera/cycv_clkmgr.c:1.4
--- src/sys/arch/arm/altera/cycv_clkmgr.c:1.3	Tue Oct  1 18:00:07 2019
+++ src/sys/arch/arm/altera/cycv_clkmgr.c	Fri Oct 18 06:50:08 2019
@@ -1,9 +1,9 @@
-/* $NetBSD: cycv_clkmgr.c,v 1.3 2019/10/01 18:00:07 chs Exp $ */
+/* $NetBSD: cycv_clkmgr.c,v 1.4 2019/10/18 06:50:08 skrll Exp $ */
 
 /* This file is in the public domain. */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: cycv_clkmgr.c,v 1.3 2019/10/01 18:00:07 chs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cycv_clkmgr.c,v 1.4 2019/10/18 06:50:08 skrll Exp $");
 
 #include 
 #include 
@@ -138,8 +138,8 @@ cycv_clkmgr_attach(device_t parent, devi
 	sc->sc_bst = faa->faa_bst;
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d",
-			 (uint64_t) addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d",
+			 addr, error);
 		return;
 	}
 
Index: src/sys/arch/arm/altera/cycv_dwcmmc.c
diff -u src/sys/arch/arm/altera/cycv_dwcmmc.c:1.3 src/sys/arch/arm/altera/cycv_dwcmmc.c:1.4
--- src/sys/arch/arm/altera/cycv_dwcmmc.c:1.3	Fri May 24 10:37:39 2019
+++ src/sys/arch/arm/altera/cycv_dwcmmc.c	Fri Oct 18 06:50:08 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: cycv_dwcmmc.c,v 1.3 2019/05/24 10:37:39 jmcneill Exp $ */
+/* $NetBSD: cycv_dwcmmc.c,v 1.4 2019/10/18 06:50:08 skrll Exp $ */
 
 /*-
  * Copyright (c) 2015 Jared D. McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: cycv_dwcmmc.c,v 1.3 2019/05/24 10:37:39 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cycv_dwcmmc.c,v 1.4 2019/10/18 06:50:08 skrll Exp $");
 
 #include 
 #include 
@@ -125,8 +125,8 @@ cycv_dwcmmc_attach(device_t parent, devi
 	sc->sc_dmat = faa->faa_dmat;
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d\n",
-		(uint64_t)addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d\n",
+		addr, error);
 		return;
 	}
 

Index: src/sys/arch/arm/altera/cycv_rstmgr.c
diff -u src/sys/arch/arm/altera/cycv_rstmgr.c:1.2 src/sys/arch/arm/altera/cycv_rstmgr.c:1.3
--- src/sys/arch/arm/altera/cycv_rstmgr.c:1.2	Sun Oct 14 18:53:01 2018
+++ src/sys/arch/arm/altera/cycv_rstmgr.c	Fri Oct 18 06:50:08 2019
@@ -1,9 +1,9 @@
-/* $NetBSD: cycv_rstmgr.c,v 1.2 2018/10/14 18:53:01 aymeric Exp $ */
+/* $NetBSD: cycv_rstmgr.c,v 1.3 2019/10/18 06:50:08 skrll Exp $ */
 
 /* This file is in the public domain. */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: cycv_rstmgr.c,v 1.2 2018/10/14 18:53:01 aymeric Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cycv_rstmgr.c,v 1.3 2019/10/18 06:50:08 skrll Exp $");
 
 #include 
 #include 
@@ -77,8 +77,8 @@ cycv_rstmgr_attach(device_t parent, devi
 	sc->sc_bst = faa->faa_bst;
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d",
-			 (uint64_t) addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d",
+			 addr, error);
 		return;
 	}
 



CVS commit: src/sys/arch/arm/samsung

2019-10-18 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri Oct 18 06:13:38 UTC 2019

Modified Files:
src/sys/arch/arm/samsung: exynos5410_clock.c exynos5422_clock.c
exynos_combiner.c exynos_dwcmmc.c exynos_i2c.c exynos_pinctrl.c
exynos_pwm.c exynos_rtc.c exynos_wdt.c mct.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/samsung/exynos5410_clock.c
cvs rdiff -u -r1.13 -r1.14 src/sys/arch/arm/samsung/exynos5422_clock.c
cvs rdiff -u -r1.10 -r1.11 src/sys/arch/arm/samsung/exynos_combiner.c \
src/sys/arch/arm/samsung/exynos_wdt.c
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/samsung/exynos_dwcmmc.c
cvs rdiff -u -r1.16 -r1.17 src/sys/arch/arm/samsung/exynos_i2c.c
cvs rdiff -u -r1.14 -r1.15 src/sys/arch/arm/samsung/exynos_pinctrl.c
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/samsung/exynos_pwm.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/samsung/exynos_rtc.c
cvs rdiff -u -r1.15 -r1.16 src/sys/arch/arm/samsung/mct.c

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



CVS commit: src/sys/arch/arm/samsung

2019-10-18 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri Oct 18 06:13:38 UTC 2019

Modified Files:
src/sys/arch/arm/samsung: exynos5410_clock.c exynos5422_clock.c
exynos_combiner.c exynos_dwcmmc.c exynos_i2c.c exynos_pinctrl.c
exynos_pwm.c exynos_rtc.c exynos_wdt.c mct.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/samsung/exynos5410_clock.c
cvs rdiff -u -r1.13 -r1.14 src/sys/arch/arm/samsung/exynos5422_clock.c
cvs rdiff -u -r1.10 -r1.11 src/sys/arch/arm/samsung/exynos_combiner.c \
src/sys/arch/arm/samsung/exynos_wdt.c
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/samsung/exynos_dwcmmc.c
cvs rdiff -u -r1.16 -r1.17 src/sys/arch/arm/samsung/exynos_i2c.c
cvs rdiff -u -r1.14 -r1.15 src/sys/arch/arm/samsung/exynos_pinctrl.c
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/samsung/exynos_pwm.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/samsung/exynos_rtc.c
cvs rdiff -u -r1.15 -r1.16 src/sys/arch/arm/samsung/mct.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/arm/samsung/exynos5410_clock.c
diff -u src/sys/arch/arm/samsung/exynos5410_clock.c:1.4 src/sys/arch/arm/samsung/exynos5410_clock.c:1.5
--- src/sys/arch/arm/samsung/exynos5410_clock.c:1.4	Sun Sep  9 07:21:18 2018
+++ src/sys/arch/arm/samsung/exynos5410_clock.c	Fri Oct 18 06:13:38 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: exynos5410_clock.c,v 1.4 2018/09/09 07:21:18 aymeric Exp $ */
+/* $NetBSD: exynos5410_clock.c,v 1.5 2019/10/18 06:13:38 skrll Exp $ */
 
 /*-
  * Copyright (c) 2015-2017 Jared McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: exynos5410_clock.c,v 1.4 2018/09/09 07:21:18 aymeric Exp $");
+__KERNEL_RCSID(0, "$NetBSD: exynos5410_clock.c,v 1.5 2019/10/18 06:13:38 skrll Exp $");
 
 #include 
 #include 
@@ -451,8 +451,8 @@ exynos5410_clock_attach(device_t parent,
 	
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d",
-			 (uint64_t)addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d",
+			 addr, error);
 		return;
 	}
 

Index: src/sys/arch/arm/samsung/exynos5422_clock.c
diff -u src/sys/arch/arm/samsung/exynos5422_clock.c:1.13 src/sys/arch/arm/samsung/exynos5422_clock.c:1.14
--- src/sys/arch/arm/samsung/exynos5422_clock.c:1.13	Sun Sep  9 07:21:18 2018
+++ src/sys/arch/arm/samsung/exynos5422_clock.c	Fri Oct 18 06:13:38 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: exynos5422_clock.c,v 1.13 2018/09/09 07:21:18 aymeric Exp $ */
+/* $NetBSD: exynos5422_clock.c,v 1.14 2019/10/18 06:13:38 skrll Exp $ */
 
 /*-
  * Copyright (c) 2015 Jared D. McNeill 
@@ -29,7 +29,7 @@
 #include "locators.h"
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: exynos5422_clock.c,v 1.13 2018/09/09 07:21:18 aymeric Exp $");
+__KERNEL_RCSID(0, "$NetBSD: exynos5422_clock.c,v 1.14 2019/10/18 06:13:38 skrll Exp $");
 
 #include 
 #include 
@@ -628,8 +628,8 @@ exynos5422_clock_attach(device_t parent,
 	
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d",
-			 (uint64_t)addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d",
+			 addr, error);
 		return;
 	}
 

Index: src/sys/arch/arm/samsung/exynos_combiner.c
diff -u src/sys/arch/arm/samsung/exynos_combiner.c:1.10 src/sys/arch/arm/samsung/exynos_combiner.c:1.11
--- src/sys/arch/arm/samsung/exynos_combiner.c:1.10	Thu Oct 18 09:01:53 2018
+++ src/sys/arch/arm/samsung/exynos_combiner.c	Fri Oct 18 06:13:38 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: exynos_combiner.c,v 1.10 2018/10/18 09:01:53 skrll Exp $ */
+/*	$NetBSD: exynos_combiner.c,v 1.11 2019/10/18 06:13:38 skrll Exp $ */
 
 /*-
 * Copyright (c) 2015 The NetBSD Foundation, Inc.
@@ -35,7 +35,7 @@
 #include "gpio.h"
 
 #include 
-__KERNEL_RCSID(1, "$NetBSD: exynos_combiner.c,v 1.10 2018/10/18 09:01:53 skrll Exp $");
+__KERNEL_RCSID(1, "$NetBSD: exynos_combiner.c,v 1.11 2019/10/18 06:13:38 skrll Exp $");
 
 #include 
 #include 
@@ -134,8 +134,8 @@ exynos_combiner_attach(device_t parent, 
 
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d",
-			 (uint64_t)addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d",
+			 addr, error);
 		return;
 	}
 
Index: src/sys/arch/arm/samsung/exynos_wdt.c
diff -u src/sys/arch/arm/samsung/exynos_wdt.c:1.10 src/sys/arch/arm/samsung/exynos_wdt.c:1.11
--- src/sys/arch/arm/samsung/exynos_wdt.c:1.10	Thu Jan  7 04:41:46 2016
+++ src/sys/arch/arm/samsung/exynos_wdt.c	Fri Oct 18 06:13:38 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: exynos_wdt.c,v 1.10 2016/01/07 04:41:46 marty Exp $	*/
+/*	$NetBSD: exynos_wdt.c,v 1.11 2019/10/18 06:13:38 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -32,7 +32,7 @@
 #include "exynos_wdt.h"
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: exynos_wdt.c,v 1.10 

CVS commit: src/sys/arch/arm/nvidia

2019-10-13 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 13 06:11:31 UTC 2019

Modified Files:
src/sys/arch/arm/nvidia: tegra124_car.c tegra124_xusbpad.c
tegra210_car.c tegra210_xusbpad.c tegra_apbdma.c tegra_cec.c
tegra_com.c tegra_fuse.c tegra_gpio.c tegra_hdaudio.c tegra_mc.c
tegra_pinmux.c tegra_pmc.c tegra_rtc.c tegra_sdhc.c
tegra_soctherm.c tegra_timer.c tegra_usbphy.c tegra_xusb.c

Log Message:
Restore %# for PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/arm/nvidia/tegra124_car.c \
src/sys/arch/arm/nvidia/tegra_xusb.c
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/arm/nvidia/tegra124_xusbpad.c
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/arm/nvidia/tegra210_car.c
cvs rdiff -u -r1.12 -r1.13 src/sys/arch/arm/nvidia/tegra210_xusbpad.c \
src/sys/arch/arm/nvidia/tegra_hdaudio.c
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/nvidia/tegra_apbdma.c \
src/sys/arch/arm/nvidia/tegra_rtc.c
cvs rdiff -u -r1.5 -r1.6 src/sys/arch/arm/nvidia/tegra_cec.c \
src/sys/arch/arm/nvidia/tegra_pinmux.c
cvs rdiff -u -r1.11 -r1.12 src/sys/arch/arm/nvidia/tegra_com.c
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/arm/nvidia/tegra_fuse.c
cvs rdiff -u -r1.10 -r1.11 src/sys/arch/arm/nvidia/tegra_gpio.c \
src/sys/arch/arm/nvidia/tegra_timer.c
cvs rdiff -u -r1.9 -r1.10 src/sys/arch/arm/nvidia/tegra_mc.c \
src/sys/arch/arm/nvidia/tegra_usbphy.c
cvs rdiff -u -r1.14 -r1.15 src/sys/arch/arm/nvidia/tegra_pmc.c
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/nvidia/tegra_sdhc.c
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/nvidia/tegra_soctherm.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/arm/nvidia/tegra124_car.c
diff -u src/sys/arch/arm/nvidia/tegra124_car.c:1.18 src/sys/arch/arm/nvidia/tegra124_car.c:1.19
--- src/sys/arch/arm/nvidia/tegra124_car.c:1.18	Sun Oct 13 05:57:14 2019
+++ src/sys/arch/arm/nvidia/tegra124_car.c	Sun Oct 13 06:11:31 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: tegra124_car.c,v 1.18 2019/10/13 05:57:14 skrll Exp $ */
+/* $NetBSD: tegra124_car.c,v 1.19 2019/10/13 06:11:31 skrll Exp $ */
 
 /*-
  * Copyright (c) 2015 Jared D. McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: tegra124_car.c,v 1.18 2019/10/13 05:57:14 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: tegra124_car.c,v 1.19 2019/10/13 06:11:31 skrll Exp $");
 
 #include 
 #include 
@@ -758,7 +758,7 @@ tegra124_car_attach(device_t parent, dev
 	sc->sc_bst = faa->faa_bst;
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %" PRIxBUSADDR ": %d", addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d", addr, error);
 		return;
 	}
 	if (of_getprop_uint32(phandle, "#clock-cells", >sc_clock_cells))
Index: src/sys/arch/arm/nvidia/tegra_xusb.c
diff -u src/sys/arch/arm/nvidia/tegra_xusb.c:1.18 src/sys/arch/arm/nvidia/tegra_xusb.c:1.19
--- src/sys/arch/arm/nvidia/tegra_xusb.c:1.18	Sun Oct 13 05:57:14 2019
+++ src/sys/arch/arm/nvidia/tegra_xusb.c	Sun Oct 13 06:11:31 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: tegra_xusb.c,v 1.18 2019/10/13 05:57:14 skrll Exp $ */
+/* $NetBSD: tegra_xusb.c,v 1.19 2019/10/13 06:11:31 skrll Exp $ */
 
 /*
  * Copyright (c) 2016 Jonathan A. Kollasch
@@ -30,7 +30,7 @@
 #include "opt_tegra.h"
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: tegra_xusb.c,v 1.18 2019/10/13 05:57:14 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: tegra_xusb.c,v 1.19 2019/10/13 06:11:31 skrll Exp $");
 
 #include 
 #include 
@@ -223,7 +223,7 @@ tegra_xusb_attach(device_t parent, devic
 	}
 	error = bus_space_map(sc->sc_iot, addr, size, 0, >sc_ioh);
 	if (error) {
-		aprint_error(": couldn't map %" PRIxBUSADDR ": %d", addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d", addr, error);
 		return;
 	}
 	DPRINTF(sc->sc_dev, "mapped %#" PRIxBUSADDR "\n", addr);
@@ -234,7 +234,7 @@ tegra_xusb_attach(device_t parent, devic
 	}
 	error = bus_space_map(sc->sc_iot, addr, size, 0, >sc_bsh_fpci);
 	if (error) {
-		aprint_error(": couldn't map %" PRIxBUSADDR ": %d", addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d", addr, error);
 		return;
 	}
 	DPRINTF(sc->sc_dev, "mapped %#" PRIxBUSADDR "\n", addr);
@@ -245,7 +245,7 @@ tegra_xusb_attach(device_t parent, devic
 	}
 	error = bus_space_map(sc->sc_iot, addr, size, 0, >sc_bsh_ipfs);
 	if (error) {
-		aprint_error(": couldn't map %" PRIxBUSADDR ": %d", addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d", addr, error);
 		return;
 	}
 	DPRINTF(sc->sc_dev, "mapped %#" PRIxBUSADDR "\n", addr);

Index: src/sys/arch/arm/nvidia/tegra124_xusbpad.c
diff -u src/sys/arch/arm/nvidia/tegra124_xusbpad.c:1.3 src/sys/arch/arm/nvidia/tegra124_xusbpad.c:1.4
--- src/sys/arch/arm/nvidia/tegra124_xusbpad.c:1.3	Sun Oct 13 05:57:14 2019
+++ src/sys/arch/arm/nvidia/tegra124_xusbpad.c	Sun Oct 13 06:11:31 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: 

CVS commit: src/sys/arch/arm/nvidia

2019-10-13 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 13 06:11:31 UTC 2019

Modified Files:
src/sys/arch/arm/nvidia: tegra124_car.c tegra124_xusbpad.c
tegra210_car.c tegra210_xusbpad.c tegra_apbdma.c tegra_cec.c
tegra_com.c tegra_fuse.c tegra_gpio.c tegra_hdaudio.c tegra_mc.c
tegra_pinmux.c tegra_pmc.c tegra_rtc.c tegra_sdhc.c
tegra_soctherm.c tegra_timer.c tegra_usbphy.c tegra_xusb.c

Log Message:
Restore %# for PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/arm/nvidia/tegra124_car.c \
src/sys/arch/arm/nvidia/tegra_xusb.c
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/arm/nvidia/tegra124_xusbpad.c
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/arm/nvidia/tegra210_car.c
cvs rdiff -u -r1.12 -r1.13 src/sys/arch/arm/nvidia/tegra210_xusbpad.c \
src/sys/arch/arm/nvidia/tegra_hdaudio.c
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/nvidia/tegra_apbdma.c \
src/sys/arch/arm/nvidia/tegra_rtc.c
cvs rdiff -u -r1.5 -r1.6 src/sys/arch/arm/nvidia/tegra_cec.c \
src/sys/arch/arm/nvidia/tegra_pinmux.c
cvs rdiff -u -r1.11 -r1.12 src/sys/arch/arm/nvidia/tegra_com.c
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/arm/nvidia/tegra_fuse.c
cvs rdiff -u -r1.10 -r1.11 src/sys/arch/arm/nvidia/tegra_gpio.c \
src/sys/arch/arm/nvidia/tegra_timer.c
cvs rdiff -u -r1.9 -r1.10 src/sys/arch/arm/nvidia/tegra_mc.c \
src/sys/arch/arm/nvidia/tegra_usbphy.c
cvs rdiff -u -r1.14 -r1.15 src/sys/arch/arm/nvidia/tegra_pmc.c
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/nvidia/tegra_sdhc.c
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/nvidia/tegra_soctherm.c

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



CVS commit: src/sys/arch/arm/sunxi

2019-10-13 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 13 06:03:56 UTC 2019

Modified Files:
src/sys/arch/arm/sunxi: sunxi_pwm.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/sunxi/sunxi_pwm.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/arm/sunxi/sunxi_pwm.c
diff -u src/sys/arch/arm/sunxi/sunxi_pwm.c:1.2 src/sys/arch/arm/sunxi/sunxi_pwm.c:1.3
--- src/sys/arch/arm/sunxi/sunxi_pwm.c:1.2	Mon Jul 16 23:11:47 2018
+++ src/sys/arch/arm/sunxi/sunxi_pwm.c	Sun Oct 13 06:03:56 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: sunxi_pwm.c,v 1.2 2018/07/16 23:11:47 christos Exp $ */
+/* $NetBSD: sunxi_pwm.c,v 1.3 2019/10/13 06:03:56 skrll Exp $ */
 
 /*-
  * Copyright (c) 2018 Jared McNeill 
@@ -28,7 +28,7 @@
 
 #include 
 
-__KERNEL_RCSID(1, "$NetBSD: sunxi_pwm.c,v 1.2 2018/07/16 23:11:47 christos Exp $");
+__KERNEL_RCSID(1, "$NetBSD: sunxi_pwm.c,v 1.3 2019/10/13 06:03:56 skrll Exp $");
 
 #include 
 #include 
@@ -213,8 +213,8 @@ sunxi_pwm_attach(device_t parent, device
 	sc->sc_bst = faa->faa_bst;
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %#" PRIx64 ": %d",
-		(uint64_t)addr, error);
+		aprint_error(": couldn't map %#" PRIxBUSADDR ": %d",
+		addr, error);
 		return;
 	}
 



CVS commit: src/sys/arch/arm/sunxi

2019-10-13 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 13 06:03:56 UTC 2019

Modified Files:
src/sys/arch/arm/sunxi: sunxi_pwm.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/sunxi/sunxi_pwm.c

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



CVS commit: src/sys/arch/arm/nvidia

2019-10-12 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 13 05:57:14 UTC 2019

Modified Files:
src/sys/arch/arm/nvidia: tegra124_car.c tegra124_xusbpad.c
tegra210_car.c tegra210_xusbpad.c tegra_apbdma.c tegra_cec.c
tegra_com.c tegra_fuse.c tegra_gpio.c tegra_hdaudio.c tegra_mc.c
tegra_pinmux.c tegra_pmc.c tegra_rtc.c tegra_sdhc.c
tegra_soctherm.c tegra_timer.c tegra_usbphy.c tegra_xusb.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/sys/arch/arm/nvidia/tegra124_car.c \
src/sys/arch/arm/nvidia/tegra_xusb.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/nvidia/tegra124_xusbpad.c
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/nvidia/tegra210_car.c
cvs rdiff -u -r1.11 -r1.12 src/sys/arch/arm/nvidia/tegra210_xusbpad.c \
src/sys/arch/arm/nvidia/tegra_hdaudio.c
cvs rdiff -u -r1.5 -r1.6 src/sys/arch/arm/nvidia/tegra_apbdma.c \
src/sys/arch/arm/nvidia/tegra_rtc.c
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/nvidia/tegra_cec.c \
src/sys/arch/arm/nvidia/tegra_pinmux.c
cvs rdiff -u -r1.10 -r1.11 src/sys/arch/arm/nvidia/tegra_com.c
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/nvidia/tegra_fuse.c
cvs rdiff -u -r1.9 -r1.10 src/sys/arch/arm/nvidia/tegra_gpio.c \
src/sys/arch/arm/nvidia/tegra_timer.c
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/nvidia/tegra_mc.c \
src/sys/arch/arm/nvidia/tegra_usbphy.c
cvs rdiff -u -r1.13 -r1.14 src/sys/arch/arm/nvidia/tegra_pmc.c
cvs rdiff -u -r1.22 -r1.23 src/sys/arch/arm/nvidia/tegra_sdhc.c
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/arm/nvidia/tegra_soctherm.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/arm/nvidia/tegra124_car.c
diff -u src/sys/arch/arm/nvidia/tegra124_car.c:1.17 src/sys/arch/arm/nvidia/tegra124_car.c:1.18
--- src/sys/arch/arm/nvidia/tegra124_car.c:1.17	Sat Mar  9 19:41:26 2019
+++ src/sys/arch/arm/nvidia/tegra124_car.c	Sun Oct 13 05:57:14 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: tegra124_car.c,v 1.17 2019/03/09 19:41:26 jakllsch Exp $ */
+/* $NetBSD: tegra124_car.c,v 1.18 2019/10/13 05:57:14 skrll Exp $ */
 
 /*-
  * Copyright (c) 2015 Jared D. McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: tegra124_car.c,v 1.17 2019/03/09 19:41:26 jakllsch Exp $");
+__KERNEL_RCSID(0, "$NetBSD: tegra124_car.c,v 1.18 2019/10/13 05:57:14 skrll Exp $");
 
 #include 
 #include 
@@ -758,7 +758,7 @@ tegra124_car_attach(device_t parent, dev
 	sc->sc_bst = faa->faa_bst;
 	error = bus_space_map(sc->sc_bst, addr, size, 0, >sc_bsh);
 	if (error) {
-		aprint_error(": couldn't map %#llx: %d", (uint64_t)addr, error);
+		aprint_error(": couldn't map %" PRIxBUSADDR ": %d", addr, error);
 		return;
 	}
 	if (of_getprop_uint32(phandle, "#clock-cells", >sc_clock_cells))
Index: src/sys/arch/arm/nvidia/tegra_xusb.c
diff -u src/sys/arch/arm/nvidia/tegra_xusb.c:1.17 src/sys/arch/arm/nvidia/tegra_xusb.c:1.18
--- src/sys/arch/arm/nvidia/tegra_xusb.c:1.17	Tue Jan  8 18:04:00 2019
+++ src/sys/arch/arm/nvidia/tegra_xusb.c	Sun Oct 13 05:57:14 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: tegra_xusb.c,v 1.17 2019/01/08 18:04:00 jakllsch Exp $ */
+/* $NetBSD: tegra_xusb.c,v 1.18 2019/10/13 05:57:14 skrll Exp $ */
 
 /*
  * Copyright (c) 2016 Jonathan A. Kollasch
@@ -30,7 +30,7 @@
 #include "opt_tegra.h"
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: tegra_xusb.c,v 1.17 2019/01/08 18:04:00 jakllsch Exp $");
+__KERNEL_RCSID(0, "$NetBSD: tegra_xusb.c,v 1.18 2019/10/13 05:57:14 skrll Exp $");
 
 #include 
 #include 
@@ -223,11 +223,10 @@ tegra_xusb_attach(device_t parent, devic
 	}
 	error = bus_space_map(sc->sc_iot, addr, size, 0, >sc_ioh);
 	if (error) {
-		aprint_error(": couldn't map %#" PRIx64 ": %d",
-		(uint64_t)addr, error);
+		aprint_error(": couldn't map %" PRIxBUSADDR ": %d", addr, error);
 		return;
 	}
-	DPRINTF(sc->sc_dev, "mapped %#" PRIx64 "\n", (uint64_t)addr);
+	DPRINTF(sc->sc_dev, "mapped %#" PRIxBUSADDR "\n", addr);
 
 	if (fdtbus_get_reg_byname(faa->faa_phandle, "fpci", , ) != 0) {
 		aprint_error(": couldn't get registers\n");
@@ -235,11 +234,10 @@ tegra_xusb_attach(device_t parent, devic
 	}
 	error = bus_space_map(sc->sc_iot, addr, size, 0, >sc_bsh_fpci);
 	if (error) {
-		aprint_error(": couldn't map %#" PRIx64 ": %d",
-		(uint64_t)addr, error);
+		aprint_error(": couldn't map %" PRIxBUSADDR ": %d", addr, error);
 		return;
 	}
-	DPRINTF(sc->sc_dev, "mapped %#" PRIx64 "\n", (uint64_t)addr);
+	DPRINTF(sc->sc_dev, "mapped %#" PRIxBUSADDR "\n", addr);
 
 	if (fdtbus_get_reg_byname(faa->faa_phandle, "ipfs", , ) != 0) {
 		aprint_error(": couldn't get registers\n");
@@ -247,11 +245,10 @@ tegra_xusb_attach(device_t parent, devic
 	}
 	error = bus_space_map(sc->sc_iot, addr, size, 0, >sc_bsh_ipfs);
 	if (error) {
-		aprint_error(": couldn't map %#" PRIx64 ": %d",
-		(uint64_t)addr, error);
+		aprint_error(": couldn't map %" PRIxBUSADDR ": %d", addr, error);
 		

CVS commit: src/sys/arch/arm/nvidia

2019-10-12 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 13 05:57:14 UTC 2019

Modified Files:
src/sys/arch/arm/nvidia: tegra124_car.c tegra124_xusbpad.c
tegra210_car.c tegra210_xusbpad.c tegra_apbdma.c tegra_cec.c
tegra_com.c tegra_fuse.c tegra_gpio.c tegra_hdaudio.c tegra_mc.c
tegra_pinmux.c tegra_pmc.c tegra_rtc.c tegra_sdhc.c
tegra_soctherm.c tegra_timer.c tegra_usbphy.c tegra_xusb.c

Log Message:
Use PRIxBUSADDR


To generate a diff of this commit:
cvs rdiff -u -r1.17 -r1.18 src/sys/arch/arm/nvidia/tegra124_car.c \
src/sys/arch/arm/nvidia/tegra_xusb.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/nvidia/tegra124_xusbpad.c
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/nvidia/tegra210_car.c
cvs rdiff -u -r1.11 -r1.12 src/sys/arch/arm/nvidia/tegra210_xusbpad.c \
src/sys/arch/arm/nvidia/tegra_hdaudio.c
cvs rdiff -u -r1.5 -r1.6 src/sys/arch/arm/nvidia/tegra_apbdma.c \
src/sys/arch/arm/nvidia/tegra_rtc.c
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/arm/nvidia/tegra_cec.c \
src/sys/arch/arm/nvidia/tegra_pinmux.c
cvs rdiff -u -r1.10 -r1.11 src/sys/arch/arm/nvidia/tegra_com.c
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/nvidia/tegra_fuse.c
cvs rdiff -u -r1.9 -r1.10 src/sys/arch/arm/nvidia/tegra_gpio.c \
src/sys/arch/arm/nvidia/tegra_timer.c
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/nvidia/tegra_mc.c \
src/sys/arch/arm/nvidia/tegra_usbphy.c
cvs rdiff -u -r1.13 -r1.14 src/sys/arch/arm/nvidia/tegra_pmc.c
cvs rdiff -u -r1.22 -r1.23 src/sys/arch/arm/nvidia/tegra_sdhc.c
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/arm/nvidia/tegra_soctherm.c

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



CVS commit: src/sys/arch/arm/nvidia

2019-10-12 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 13 05:56:52 UTC 2019

Modified Files:
src/sys/arch/arm/nvidia: tegra_drm_mode.c

Log Message:
Trailing whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/arm/nvidia/tegra_drm_mode.c

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



CVS commit: src/sys/arch/arm/nvidia

2019-10-12 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct 13 05:56:52 UTC 2019

Modified Files:
src/sys/arch/arm/nvidia: tegra_drm_mode.c

Log Message:
Trailing whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/arm/nvidia/tegra_drm_mode.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/arm/nvidia/tegra_drm_mode.c
diff -u src/sys/arch/arm/nvidia/tegra_drm_mode.c:1.18 src/sys/arch/arm/nvidia/tegra_drm_mode.c:1.19
--- src/sys/arch/arm/nvidia/tegra_drm_mode.c:1.18	Sun Jul  7 10:27:41 2019
+++ src/sys/arch/arm/nvidia/tegra_drm_mode.c	Sun Oct 13 05:56:52 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: tegra_drm_mode.c,v 1.18 2019/07/07 10:27:41 jmcneill Exp $ */
+/* $NetBSD: tegra_drm_mode.c,v 1.19 2019/10/13 05:56:52 skrll Exp $ */
 
 /*-
  * Copyright (c) 2015 Jared D. McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: tegra_drm_mode.c,v 1.18 2019/07/07 10:27:41 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: tegra_drm_mode.c,v 1.19 2019/10/13 05:56:52 skrll Exp $");
 
 #include 
 #include 
@@ -699,7 +699,7 @@ tegra_crtc_mode_set_base(struct drm_crtc
 struct drm_framebuffer *old_fb)
 {
 	struct tegra_crtc *tegra_crtc = to_tegra_crtc(crtc);
-	
+
 	tegra_crtc_do_set_base(crtc, old_fb, x, y, 0);
 
 	/* Commit settings */



CVS commit: src/sys/dev/pci

2019-10-12 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Oct 12 07:38:28 UTC 2019

Modified Files:
src/sys/dev/pci: pcidevs.h pcidevs_data.h

Log Message:
regen


To generate a diff of this commit:
cvs rdiff -u -r1.1375 -r1.1376 src/sys/dev/pci/pcidevs.h
cvs rdiff -u -r1.1374 -r1.1375 src/sys/dev/pci/pcidevs_data.h

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



CVS commit: src/sys/dev/pci

2019-10-12 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Oct 12 06:46:42 UTC 2019

Modified Files:
src/sys/dev/pci: pcidevs

Log Message:
Spell controller correctly


To generate a diff of this commit:
cvs rdiff -u -r1.1387 -r1.1388 src/sys/dev/pci/pcidevs

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

Modified files:

Index: src/sys/dev/pci/pcidevs
diff -u src/sys/dev/pci/pcidevs:1.1387 src/sys/dev/pci/pcidevs:1.1388
--- src/sys/dev/pci/pcidevs:1.1387	Sat Sep 21 14:25:09 2019
+++ src/sys/dev/pci/pcidevs	Sat Oct 12 06:46:42 2019
@@ -1,4 +1,4 @@
-$NetBSD: pcidevs,v 1.1387 2019/09/21 14:25:09 msaitoh Exp $
+$NetBSD: pcidevs,v 1.1388 2019/10/12 06:46:42 skrll Exp $
 
 /*
  * Copyright (c) 1995, 1996 Christopher G. Demetriou
@@ -6839,7 +6839,7 @@ product PROMISE PDC20271	0x6269	PDC20271
 product PROMISE PDC20617	0x6617	PDC20617 Dual Ultra/133 IDE Controller
 product PROMISE PDC20620	0x6620	PDC20620 Dual Ultra/133 IDE Controller
 product PROMISE PDC20621	0x6621	PDC20621 Dual Ultra/133 IDE Controller
-product PROMISE PDC20618	0x6626	PDC20618 Dual Ultra/133 IDE Controler
+product PROMISE PDC20618	0x6626	PDC20618 Dual Ultra/133 IDE Controller
 product PROMISE PDC20619	0x6629	PDC20619 Dual Ultra/133 IDE Controller
 product PROMISE PDC20277	0x7275	PDC20277 Ultra/133 IDE Controller
 



CVS commit: src/sys/dev/pci

2019-10-12 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Oct 12 06:46:42 UTC 2019

Modified Files:
src/sys/dev/pci: pcidevs

Log Message:
Spell controller correctly


To generate a diff of this commit:
cvs rdiff -u -r1.1387 -r1.1388 src/sys/dev/pci/pcidevs

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



CVS commit: src/sys/arch/arm/imx

2019-10-12 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Oct 12 06:46:13 UTC 2019

Modified Files:
src/sys/arch/arm/imx: files.imx51 files.imx6 files.imx7
src/sys/arch/arm/imx/fdt: files.imx6

Log Message:
Spell controller correctly


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/sys/arch/arm/imx/files.imx51
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/arm/imx/files.imx6
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/imx/files.imx7
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/imx/fdt/files.imx6

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/arm/imx/files.imx51
diff -u src/sys/arch/arm/imx/files.imx51:1.19 src/sys/arch/arm/imx/files.imx51:1.20
--- src/sys/arch/arm/imx/files.imx51:1.19	Wed Jul 24 12:33:18 2019
+++ src/sys/arch/arm/imx/files.imx51	Sat Oct 12 06:46:13 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: files.imx51,v 1.19 2019/07/24 12:33:18 hkenken Exp $
+#	$NetBSD: files.imx51,v 1.20 2019/10/12 06:46:13 skrll Exp $
 #
 # Configuration info for the Freescale i.MX5x
 #
@@ -110,13 +110,13 @@ file   arch/arm/imx/imxusb.c			imxehci
 attach	sdhc at axi with sdhc_axi
 file	arch/arm/imx/imx51_esdhc.c		sdhc_axi
 
-# iic Controler
+# iic controller
 device	imxi2c: motoi2c, i2cbus, i2cexec
 attach	imxi2c at axi
 file	arch/arm/imx/imxi2c.c		imxi2c
 file	arch/arm/imx/imx51_i2c.c	imxi2c
 
-# SPI bus controlloer
+# SPI bus controller
 # attach of this driver need to be specified in paltform configuration
 # use flags to module version
 device  imxspi : spibus
@@ -136,7 +136,7 @@ defparam opt_imxspi.hIMXSPI_DEBUG
 # device	imxi2s {} : bus_dma_generic
 # file	arch/arm/imx/imx51_i2s.c		imxi2s needs-flag
 
-# PWM controlloer
+# PWM controller
 device	imxpwm
 file	arch/arm/imx/imxpwm.c			imxpwm
 file	arch/arm/imx/imx51_pwm.c		imxpwm

Index: src/sys/arch/arm/imx/files.imx6
diff -u src/sys/arch/arm/imx/files.imx6:1.18 src/sys/arch/arm/imx/files.imx6:1.19
--- src/sys/arch/arm/imx/files.imx6:1.18	Sat Jul 27 08:02:04 2019
+++ src/sys/arch/arm/imx/files.imx6	Sat Oct 12 06:46:13 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: files.imx6,v 1.18 2019/07/27 08:02:04 skrll Exp $
+#	$NetBSD: files.imx6,v 1.19 2019/10/12 06:46:13 skrll Exp $
 #
 # Configuration info for the Freescale i.MX6
 #
@@ -71,7 +71,7 @@ device	imxiomux
 attach	imxiomux at axi
 file	arch/arm/imx/imx6_iomux.c		imxiomux
 
-# iMX iic Controler
+# iMX iic controller
 device	imxi2c: motoi2c, i2cbus, i2cexec
 attach	imxi2c at axi
 file	arch/arm/imx/imxi2c.c			imxi2c

Index: src/sys/arch/arm/imx/files.imx7
diff -u src/sys/arch/arm/imx/files.imx7:1.8 src/sys/arch/arm/imx/files.imx7:1.9
--- src/sys/arch/arm/imx/files.imx7:1.8	Sat Jul 27 12:07:24 2019
+++ src/sys/arch/arm/imx/files.imx7	Sat Oct 12 06:46:13 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: files.imx7,v 1.8 2019/07/27 12:07:24 hkenken Exp $
+#	$NetBSD: files.imx7,v 1.9 2019/10/12 06:46:13 skrll Exp $
 #
 # Configuration info for the Freescale i.MX7
 #
@@ -60,7 +60,7 @@ device	imxiomux
 attach	imxiomux at axi
 file	arch/arm/imx/imx7_iomux.c		imxiomux
 
-# iMX iic Controler
+# iMX iic controller
 device	imxi2c: motoi2c, i2cbus, i2cexec
 attach	imxi2c at axi
 file	arch/arm/imx/imxi2c.c			imxi2c

Index: src/sys/arch/arm/imx/fdt/files.imx6
diff -u src/sys/arch/arm/imx/fdt/files.imx6:1.6 src/sys/arch/arm/imx/fdt/files.imx6:1.7
--- src/sys/arch/arm/imx/fdt/files.imx6:1.6	Mon Aug 19 11:41:36 2019
+++ src/sys/arch/arm/imx/fdt/files.imx6	Sat Oct 12 06:46:13 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: files.imx6,v 1.6 2019/08/19 11:41:36 hkenken Exp $
+#	$NetBSD: files.imx6,v 1.7 2019/10/12 06:46:13 skrll Exp $
 #
 # Configuration info for the Freescale i.MX6
 #
@@ -71,13 +71,13 @@ attach	imxpcie at fdt with imxpcie_fdt
 file	arch/arm/imx/imxpcie.c			imxpcie
 file	arch/arm/imx/fdt/imx6_pcie.c		imxpcie_fdt
 
-# iMX iic Controler
+# iMX iic controller
 device	imxi2c: motoi2c, i2cbus, i2cexec
 attach	imxi2c at fdt
 file	arch/arm/imx/imxi2c.c			imxi2c
 file	arch/arm/imx/fdt/imx6_i2c.c		imxi2c
 
-# SPI bus controlloer
+# SPI bus controller
 device  imxspi : spibus
 attach	imxspi at fdt with imxspi_fdt
 filearch/arm/imx/imxspi.c			imxspi



CVS commit: src/sys/arch/arm/imx

2019-10-12 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Oct 12 06:46:13 UTC 2019

Modified Files:
src/sys/arch/arm/imx: files.imx51 files.imx6 files.imx7
src/sys/arch/arm/imx/fdt: files.imx6

Log Message:
Spell controller correctly


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/sys/arch/arm/imx/files.imx51
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/arm/imx/files.imx6
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/arm/imx/files.imx7
cvs rdiff -u -r1.6 -r1.7 src/sys/arch/arm/imx/fdt/files.imx6

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



CVS commit: src/sys/arch/evbarm/conf

2019-10-11 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Oct 12 05:19:49 UTC 2019

Modified Files:
src/sys/arch/evbarm/conf: std.n900

Log Message:
Add __HAVE_GENERIC_START


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/evbarm/conf/std.n900

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



CVS commit: src/sys/arch/evbarm/conf

2019-10-11 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Oct 12 05:19:49 UTC 2019

Modified Files:
src/sys/arch/evbarm/conf: std.n900

Log Message:
Add __HAVE_GENERIC_START


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/sys/arch/evbarm/conf/std.n900

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/evbarm/conf/std.n900
diff -u src/sys/arch/evbarm/conf/std.n900:1.8 src/sys/arch/evbarm/conf/std.n900:1.9
--- src/sys/arch/evbarm/conf/std.n900:1.8	Sat Oct 12 05:19:00 2019
+++ src/sys/arch/evbarm/conf/std.n900	Sat Oct 12 05:19:49 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: std.n900,v 1.8 2019/10/12 05:19:00 skrll Exp $
+#	$NetBSD: std.n900,v 1.9 2019/10/12 05:19:49 skrll Exp $
 #
 # standard NetBSD/evbarm for N900 options
 
@@ -16,6 +16,7 @@ options 	FPU_VFP
 options 	TPIDRPRW_IS_CURCPU
 options 	__HAVE_CPU_COUNTER
 options 	__HAVE_FAST_SOFTINTS		# should be in types.h
+options 	__HAVE_GENERIC_START
 options 	__HAVE_MM_MD_DIRECT_MAPPED_PHYS
 
 makeoptions 	LOADADDRESS="0x8030"



CVS commit: src/sys/arch/evbarm/conf

2019-10-11 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Oct 12 05:19:00 UTC 2019

Modified Files:
src/sys/arch/evbarm/conf: std.n900

Log Message:
Sort. NFCI.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/evbarm/conf/std.n900

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



CVS commit: src/sys/arch/evbarm/conf

2019-10-11 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Oct 12 05:19:00 UTC 2019

Modified Files:
src/sys/arch/evbarm/conf: std.n900

Log Message:
Sort. NFCI.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/evbarm/conf/std.n900

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/evbarm/conf/std.n900
diff -u src/sys/arch/evbarm/conf/std.n900:1.7 src/sys/arch/evbarm/conf/std.n900:1.8
--- src/sys/arch/evbarm/conf/std.n900:1.7	Mon Oct 15 16:54:54 2018
+++ src/sys/arch/evbarm/conf/std.n900	Sat Oct 12 05:19:00 2019
@@ -1,4 +1,4 @@
-#	$NetBSD: std.n900,v 1.7 2018/10/15 16:54:54 skrll Exp $
+#	$NetBSD: std.n900,v 1.8 2019/10/12 05:19:00 skrll Exp $
 #
 # standard NetBSD/evbarm for N900 options
 
@@ -9,17 +9,17 @@ include		"arch/evbarm/conf/std.evbarm"
 include		"arch/evbarm/conf/files.n900"
 
 # To support easy transit to ../arch/arm/arm32
-options 	__HAVE_CPU_COUNTER
+options 	ARM_GENERIC_TODR
+options 	ARM_HAS_VBAR
 options 	CORTEX_PMC
+options 	FPU_VFP
+options 	TPIDRPRW_IS_CURCPU
+options 	__HAVE_CPU_COUNTER
 options 	__HAVE_FAST_SOFTINTS		# should be in types.h
-options 	ARM_HAS_VBAR
 options 	__HAVE_MM_MD_DIRECT_MAPPED_PHYS
-options 	TPIDRPRW_IS_CURCPU
-options 	FPU_VFP
 
 makeoptions 	LOADADDRESS="0x8030"
 makeoptions 	BOARDTYPE="n900"
 makeoptions 	BOARDMKFRAG="${THISARM}/conf/mk.beagle"
 
 options 	ARM_INTR_IMPL=""
-options 	ARM_GENERIC_TODR



CVS commit: src/sys/kern

2019-10-09 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Oct  9 05:59:51 UTC 2019

Modified Files:
src/sys/kern: kern_history.c

Log Message:
Traiing whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/kern/kern_history.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/kern/kern_history.c
diff -u src/sys/kern/kern_history.c:1.18 src/sys/kern/kern_history.c:1.19
--- src/sys/kern/kern_history.c:1.18	Mon Sep  3 16:29:35 2018
+++ src/sys/kern/kern_history.c	Wed Oct  9 05:59:51 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: kern_history.c,v 1.18 2018/09/03 16:29:35 riastradh Exp $	 */
+/*	$NetBSD: kern_history.c,v 1.19 2019/10/09 05:59:51 skrll Exp $	 */
 
 /*
  * Copyright (c) 1997 Charles D. Cranor and Washington University.
@@ -33,7 +33,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: kern_history.c,v 1.18 2018/09/03 16:29:35 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_history.c,v 1.19 2019/10/09 05:59:51 skrll Exp $");
 
 #include "opt_ddb.h"
 #include "opt_kernhist.h"
@@ -483,7 +483,7 @@ sysctl_kernhist_helper(SYSCTLFN_ARGS)
 	}
 
 	/* Total buffer size includes header, events, and string table */
-	bufsize = sizeof(struct sysctl_history) + 
+	bufsize = sizeof(struct sysctl_history) +
 	h->n * sizeof(struct sysctl_history_event) +
 	xlate_t[xlate_c].offset;
 	buf = kmem_alloc(bufsize, KM_SLEEP);
@@ -539,7 +539,7 @@ sysctl_kernhist_helper(SYSCTLFN_ARGS)
 		"entry %d at wrong offset %"PRIu32, i, xlt->offset);
 		memcpy(next, xlt->addr, xlt->len);
 		next += xlt->len;
-		*next++ = '\0';	
+		*next++ = '\0';
 	}
 
 	/* Copy data to userland */



CVS commit: src/sys/kern

2019-10-09 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Oct  9 05:59:51 UTC 2019

Modified Files:
src/sys/kern: kern_history.c

Log Message:
Traiing whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/kern/kern_history.c

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



CVS commit: src/sys/dev/usb

2019-10-07 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Mon Oct  7 09:37:16 UTC 2019

Modified Files:
src/sys/dev/usb: if_udav.c

Log Message:
Avoid a warning


To generate a diff of this commit:
cvs rdiff -u -r1.71 -r1.72 src/sys/dev/usb/if_udav.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/dev/usb/if_udav.c
diff -u src/sys/dev/usb/if_udav.c:1.71 src/sys/dev/usb/if_udav.c:1.72
--- src/sys/dev/usb/if_udav.c:1.71	Fri Aug 23 04:32:57 2019
+++ src/sys/dev/usb/if_udav.c	Mon Oct  7 09:37:16 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_udav.c,v 1.71 2019/08/23 04:32:57 mrg Exp $	*/
+/*	$NetBSD: if_udav.c,v 1.72 2019/10/07 09:37:16 skrll Exp $	*/
 /*	$nabe: if_udav.c,v 1.3 2003/08/21 16:57:19 nabe Exp $	*/
 
 /*
@@ -45,7 +45,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_udav.c,v 1.71 2019/08/23 04:32:57 mrg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_udav.c,v 1.72 2019/10/07 09:37:16 skrll Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_usb.h"
@@ -864,7 +864,7 @@ udav_mii_statchg(struct ifnet *ifp)
 	if (usbnet_isdying(un))
 		return;
 
-	if (mii->mii_media_status & IFM_ACTIVE &&
+	if ((mii->mii_media_status & IFM_ACTIVE) &&
 	IFM_SUBTYPE(mii->mii_media_active) != IFM_NONE) {
 		DPRINTF(("%s: %s: got link\n",
 			 device_xname(un->un_dev), __func__));



CVS commit: src/sys/dev/usb

2019-10-07 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Mon Oct  7 09:37:16 UTC 2019

Modified Files:
src/sys/dev/usb: if_udav.c

Log Message:
Avoid a warning


To generate a diff of this commit:
cvs rdiff -u -r1.71 -r1.72 src/sys/dev/usb/if_udav.c

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



CVS commit: src/sys/arch/evbarm/conf

2019-10-06 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct  6 07:36:47 UTC 2019

Modified Files:
src/sys/arch/evbarm/conf: GENERIC

Log Message:
Disable tegradrm for now as it causes random crashes


To generate a diff of this commit:
cvs rdiff -u -r1.52 -r1.53 src/sys/arch/evbarm/conf/GENERIC

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/evbarm/conf/GENERIC
diff -u src/sys/arch/evbarm/conf/GENERIC:1.52 src/sys/arch/evbarm/conf/GENERIC:1.53
--- src/sys/arch/evbarm/conf/GENERIC:1.52	Thu Sep  5 16:15:57 2019
+++ src/sys/arch/evbarm/conf/GENERIC	Sun Oct  6 07:36:46 2019
@@ -1,5 +1,5 @@
 #
-#	$NetBSD: GENERIC,v 1.52 2019/09/05 16:15:57 bouyer Exp $
+#	$NetBSD: GENERIC,v 1.53 2019/10/06 07:36:46 skrll Exp $
 #
 #	GENERIC ARM (aarch32) kernel
 #
@@ -559,8 +559,8 @@ tegracec0 	at fdt?			# NVIDIA Tegra HDMI
 hdmicec* 	at hdmicecbus?
 
 # Display
-tegradrm* 	at fdt?			# NVIDIA Tegra Display
-tegrafb* 	at tegrafbbus?
+#tegradrm* 	at fdt?			# NVIDIA Tegra Display
+#tegrafb* 	at tegrafbbus?
 genfb* 		at fdt?			# Simple Framebuffer
 mesonfb* 	at fdt?			# Amlogic Meson Framebuffer
 wsdisplay* 	at wsemuldisplaydev?



CVS commit: src/sys/arch/evbarm/conf

2019-10-06 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Oct  6 07:36:47 UTC 2019

Modified Files:
src/sys/arch/evbarm/conf: GENERIC

Log Message:
Disable tegradrm for now as it causes random crashes


To generate a diff of this commit:
cvs rdiff -u -r1.52 -r1.53 src/sys/arch/evbarm/conf/GENERIC

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



CVS commit: src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64

2019-10-02 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Oct  2 10:34:48 UTC 2019

Modified Files:
src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64: defs.mk

Log Message:
Remove garbage. Maybe something is wrong with mknative or mrg's script?


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 \
src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64/defs.mk

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

Modified files:

Index: src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64/defs.mk
diff -u src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64/defs.mk:1.6 src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64/defs.mk:1.7
--- src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64/defs.mk:1.6	Wed Oct  2 07:15:01 2019
+++ src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64/defs.mk	Wed Oct  2 10:34:48 2019
@@ -2,857 +2,6 @@
 # Generated from: NetBSD: mknative-gcc,v 1.101 2019/02/23 06:54:45 mrg Exp 
 # Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp 
 #
-running CONFIG_SHELL=/bin/sh /bin/sh /usr/src/external/gpl3/gcc/dist/gcc/configure --srcdir=/usr/src/tools/gcc/../../external/gpl3/gcc/dist/gcc --cache-file=./config.cache --enable-long-long --enable-threads --with-bugurl=http://www.NetBSD.org/support/send-pr.html --with-pkgversion=NetBSD nb1 20190930 --with-system-zlib --without-isl --enable-__cxa_atexit --enable-libstdcxx-time=rt --enable-libstdcxx-threads --with-diagnostics-color=auto-if-env --enable-fix-cortex-a53-835769 --enable-fix-cortex-a53-843419 --with-default-libstdcxx-abi=new --with-mpc-lib=/var/obj/mknative/evbarm-aarch64/usr/src/external/lgpl3/mpc/lib/libmpc --with-mpfr-lib=/var/obj/mknative/evbarm-aarch64/usr/src/external/lgpl3/mpfr/lib/libmpfr --with-gmp-lib=/var/obj/mknative/evbarm-aarch64/usr/src/external/lgpl3/gmp/lib/libgmp --with-mpc-include=/usr/src/external/lgpl3/mpc/dist/src --with-mpfr-include=/usr/src/external/lgpl3/mpfr/dist/src --with-gmp-include=/usr/src/external/lgpl3/gmp/lib/libgmp/arch/aarch64 --enabl
 e-tls --disable-multilib --disable-libstdcxx-pch --with-sysroot=/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm --enable-languages=c,c++,lto,objc --program-transform-name=s,y,y, --disable-option-checking --build=x86_64-unknown-netbsd9.0 --host=aarch64--netbsd --target=aarch64--netbsd build_alias=x86_64-unknown-netbsd9.0 host_alias=aarch64--netbsd target_alias=aarch64--netbsd CC=/var/obj/mknative/evbarm-aarch64/usr/src/tooldir.NetBSD-9.0_BETA-amd64/bin/aarch64--netbsd-gcc --sysroot=/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm -L/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm/lib -L/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm/usr/lib -B/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm/usr/lib/ -I/var/obj/mknative/evbarm-aarch64/usr/src/tools/gcc/.native/gcc/include CFLAGS= LDFLAGS=-static-libstdc++ -static-libgcc  CPPFLAGS= CXX=/var/obj/mknative/evbarm-aarch64/usr/src/tooldir.NetBSD-9.0_BETA-amd64/bin/aarch64--netbsd-c++ --sysroot=/var/obj/m
 knative/evbarm-aarch64/usr/src/destdir.evbarm -L/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm/lib -L/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm/usr/lib -B/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm/usr/lib/ -I/var/obj/mknative/evbarm-aarch64/usr/src/tools/gcc/.native/gcc/include --sysroot=/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm CXXFLAGS= CPP=/var/obj/mknative/evbarm-aarch64/usr/src/tooldir.NetBSD-9.0_BETA-amd64/bin/aarch64--netbsd-cpp -I/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm/usr/include -I/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm/usr/include/g++/bits GMPLIBS=-L/var/obj/mknative/evbarm-aarch64/usr/src/external/lgpl3/gmp/lib/libgmp -L/var/obj/mknative/evbarm-aarch64/usr/src/external/lgpl3/mpfr/lib/libmpfr -L/var/obj/mknative/evbarm-aarch64/usr/src/external/lgpl3/mpc/lib/libmpc -lmpc -lmpfr -lgmp GMPINC=-I/usr/src/external/lgpl3/gmp/lib/libgmp/arch/aarch64 -I/usr/src/external/lgpl3/mpfr/dist/src -I/usr/src
 /external/lgpl3/mpc/dist/src  ISLLIBS= ISLINC= --no-create --no-recursion
-configure: loading cache ./config.cache
-checking build system type... (cached) x86_64-unknown-netbsd9.0
-checking host system type... (cached) aarch64--netbsd
-checking target system type... (cached) aarch64--netbsd
-checking LIBRARY_PATH variable... ok
-checking GCC_EXEC_PREFIX variable... ok
-checking whether to place generated files in the source directory... no
-checking whether a default linker was specified... no
-checking whether a default assembler was specified... no
-checking for aarch64--netbsd-gcc... (cached) /var/obj/mknative/evbarm-aarch64/usr/src/tooldir.NetBSD-9.0_BETA-amd64/bin/aarch64--netbsd-gcc --sysroot=/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm -L/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm/lib -L/var/obj/mknative/evbarm-aarch64/usr/src/destdir.evbarm/usr/lib 

CVS commit: src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64

2019-10-02 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Oct  2 10:34:48 UTC 2019

Modified Files:
src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64: defs.mk

Log Message:
Remove garbage. Maybe something is wrong with mknative or mrg's script?


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 \
src/external/gpl3/gcc/usr.bin/gcc/arch/aarch64/defs.mk

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



Re: CVS commit: src/sys/kern

2019-09-30 Thread Nick Hudson



Sent from my iPhone

> On 30 Sep 2019, at 18:06, Tobias Nygren  wrote:
> 
> On Mon, 23 Sep 2019 05:39:59 +0000
> Nick Hudson  wrote:
> 
>> Modified Files:
>>src/sys/kern: subr_pool.c
>> 
>> Log Message:
>> Enable POOL_REDZONE with DIAGNOSTIC.
>> 
>> The bug in the arm pmap was fixed long ago.
>> 
>> 
>> To generate a diff of this commit:
>> cvs rdiff -u -r1.258 -r1.259 src/sys/kern/subr_pool.c
> 
> Hi,
> 
> I see 30% packet loss on my BananaPi evbarm system with -current.
> I bisected it to the above change. It may have had unintended
> side effects.

This is maxv’s change really - feel free to revert

Sounds like it corrupts pool allocated memory in some cases

> What is the referenced pmap bug about?

sys/arch/arm/arm32/pmap.c:1.367

Sorry for the breakage

Nick 






CVS commit: src/sys/arch/aarch64/aarch64

2019-09-29 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Sep 29 08:33:20 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: locore.S

Log Message:
Typo in comment


To generate a diff of this commit:
cvs rdiff -u -r1.40 -r1.41 src/sys/arch/aarch64/aarch64/locore.S

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



CVS commit: src/sys/arch/aarch64/aarch64

2019-09-29 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Sep 29 08:33:20 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: locore.S

Log Message:
Typo in comment


To generate a diff of this commit:
cvs rdiff -u -r1.40 -r1.41 src/sys/arch/aarch64/aarch64/locore.S

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/aarch64/aarch64/locore.S
diff -u src/sys/arch/aarch64/aarch64/locore.S:1.40 src/sys/arch/aarch64/aarch64/locore.S:1.41
--- src/sys/arch/aarch64/aarch64/locore.S:1.40	Sun Sep  8 12:17:23 2019
+++ src/sys/arch/aarch64/aarch64/locore.S	Sun Sep 29 08:33:20 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: locore.S,v 1.40 2019/09/08 12:17:23 jmcneill Exp $	*/
+/*	$NetBSD: locore.S,v 1.41 2019/09/29 08:33:20 skrll Exp $	*/
 
 /*
  * Copyright (c) 2017 Ryo Shimizu 
@@ -38,7 +38,7 @@
 #include 
 #include "assym.h"
 
-RCSID("$NetBSD: locore.S,v 1.40 2019/09/08 12:17:23 jmcneill Exp $")
+RCSID("$NetBSD: locore.S,v 1.41 2019/09/29 08:33:20 skrll Exp $")
 
 
 /*#define DEBUG_LOCORE			/* debug print */
@@ -799,7 +799,7 @@ init_mmutable:
 	adr	x0, start			/* va = start */
 	ADDR	x2, _end
 	sub	x2, x2, x0			/* size = _end - start */
-	add	x2, x2, #BOOTPAGE_ALLOC_MAX	/* for boopage_alloc() */
+	add	x2, x2, #BOOTPAGE_ALLOC_MAX	/* for bootpage_alloc() */
 	mov	x1, x0/* pa */
 	bl	pmapboot_enter
 	cbnz	x0, init_mmutable_error



CVS commit: src/sys/arch/arm/arm32

2019-09-29 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Sep 29 06:51:45 UTC 2019

Modified Files:
src/sys/arch/arm/arm32: cpu.c

Log Message:
aprint_debug_dev output alignment


To generate a diff of this commit:
cvs rdiff -u -r1.131 -r1.132 src/sys/arch/arm/arm32/cpu.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/arm/arm32/cpu.c
diff -u src/sys/arch/arm/arm32/cpu.c:1.131 src/sys/arch/arm/arm32/cpu.c:1.132
--- src/sys/arch/arm/arm32/cpu.c:1.131	Sun Sep  8 07:59:43 2019
+++ src/sys/arch/arm/arm32/cpu.c	Sun Sep 29 06:51:45 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: cpu.c,v 1.131 2019/09/08 07:59:43 tnn Exp $	*/
+/*	$NetBSD: cpu.c,v 1.132 2019/09/29 06:51:45 skrll Exp $	*/
 
 /*
  * Copyright (c) 1995 Mark Brinicombe.
@@ -46,7 +46,7 @@
 #include "opt_multiprocessor.h"
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.131 2019/09/08 07:59:43 tnn Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.132 2019/09/29 06:51:45 skrll Exp $");
 
 #include 
 #include 
@@ -689,6 +689,8 @@ identify_arm_cpu(device_t dv, struct cpu
 		aprint_normal(": %s\n", model);
 	}
 
+	aprint_debug_dev(dv, "midr:   %#x\n", arm_cpuid);
+
 	aprint_normal("%s:", xname);
 
 	switch (cpu_class) {
@@ -856,11 +858,11 @@ identify_features(device_t dv)
 	cpu_processor_features[0] = armreg_pfr0_read();
 	cpu_processor_features[1] = armreg_pfr1_read();
 
-	aprint_debug_dev(dv, "sctlr: %#x\n", armreg_sctlr_read());
-	aprint_debug_dev(dv, "actlr: %#x\n", armreg_auxctl_read());
+	aprint_debug_dev(dv, "sctlr:  %#x\n", armreg_sctlr_read());
+	aprint_debug_dev(dv, "actlr:  %#x\n", armreg_auxctl_read());
 	aprint_debug_dev(dv, "revidr: %#x\n", armreg_revidr_read());
 #ifdef MULTIPROCESSOR
-	aprint_debug_dev(dv, "mpidr: %#x\n", armreg_mpidr_read());
+	aprint_debug_dev(dv, "mpidr:  %#x\n", armreg_mpidr_read());
 #endif
 	aprint_debug_dev(dv,
 	"isar: [0]=%#x [1]=%#x [2]=%#x [3]=%#x, [4]=%#x, [5]=%#x\n",



CVS commit: src/sys/arch/arm/arm32

2019-09-29 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sun Sep 29 06:51:45 UTC 2019

Modified Files:
src/sys/arch/arm/arm32: cpu.c

Log Message:
aprint_debug_dev output alignment


To generate a diff of this commit:
cvs rdiff -u -r1.131 -r1.132 src/sys/arch/arm/arm32/cpu.c

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



CVS commit: src/sys/arch/arm/nvidia

2019-09-28 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Sep 28 07:42:47 UTC 2019

Modified Files:
src/sys/arch/arm/nvidia: tegra210_pinmux.c tegra_pinmux.c
tegra_pinmux.h

Log Message:
Update tegra_pinmux to support all bindings (pins and pin groups)

Update tegra210_pinmux.c with all defined pins and groups.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/nvidia/tegra210_pinmux.c \
src/sys/arch/arm/nvidia/tegra_pinmux.h
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/nvidia/tegra_pinmux.c

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



CVS commit: src/sys/arch/arm/nvidia

2019-09-28 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Sep 28 07:42:47 UTC 2019

Modified Files:
src/sys/arch/arm/nvidia: tegra210_pinmux.c tegra_pinmux.c
tegra_pinmux.h

Log Message:
Update tegra_pinmux to support all bindings (pins and pin groups)

Update tegra210_pinmux.c with all defined pins and groups.


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/arch/arm/nvidia/tegra210_pinmux.c \
src/sys/arch/arm/nvidia/tegra_pinmux.h
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/nvidia/tegra_pinmux.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/arm/nvidia/tegra210_pinmux.c
diff -u src/sys/arch/arm/nvidia/tegra210_pinmux.c:1.1 src/sys/arch/arm/nvidia/tegra210_pinmux.c:1.2
--- src/sys/arch/arm/nvidia/tegra210_pinmux.c:1.1	Fri Sep 22 14:36:22 2017
+++ src/sys/arch/arm/nvidia/tegra210_pinmux.c	Sat Sep 28 07:42:47 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: tegra210_pinmux.c,v 1.1 2017/09/22 14:36:22 jmcneill Exp $ */
+/* $NetBSD: tegra210_pinmux.c,v 1.2 2019/09/28 07:42:47 skrll Exp $ */
 
 /*-
  * Copyright (c) 2017 Jared McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: tegra210_pinmux.c,v 1.1 2017/09/22 14:36:22 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: tegra210_pinmux.c,v 1.2 2019/09/28 07:42:47 skrll Exp $");
 
 #include 
 #include 
@@ -36,171 +36,222 @@ __KERNEL_RCSID(0, "$NetBSD: tegra210_pin
 
 #include 
 
+#define TEGRA_PIN(n, r, f1, f2, f3, f4)	\
+	{\
+		.tpp_name = n,		\
+		.tpp_reg = (r),		\
+		.tpp_type = TEGRA_PINMUX,\
+		.tpp_functions = {	\
+			f1, f2, f3, f4	\
+		}			\
+	}
+
+#define TEGRA_PINGROUP(n, r, drvdn_m, drvup_m, slwrr_m, slwrf_m)	\
+	{\
+		.tpp_name = "drive_" n,	\
+		.tpp_reg = (r) - 0x8d4,	\
+		.tpp_type = TEGRA_PADCTRL,\
+		.tpp_dg = {		\
+			.drvdn_mask = drvdn_m,\
+			.drvup_mask = drvup_m,\
+			.slwrr_mask = slwrr_m,\
+			.slwrf_mask = slwrf_m\
+		}			\
+	}
+
+// 9.15 Pinmux registers
 static const struct tegra_pinmux_pins tegra210_pins[] = {
-	{ "sdmmc1_clk_pm0",		0x00, { "sdmmc1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sdmmc1_cmd_pm1",		0x04, { "sdmmc1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sdmmc1_dat3_pm2",		0x08, { "sdmmc1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sdmmc1_dat2_pm3",		0x0c, { "sdmmc1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sdmmc1_dat1_pm4",		0x10, { "sdmmc1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sdmmc1_dat0_pm5",		0x14, { "sdmmc1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sdmmc3_clk_pp0",		0x1c, { "sdmmc3", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sdmmc3_cmd_pp1",		0x20, { "sdmmc3", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sdmmc3_dat0_pp5",		0x24, { "sdmmc3", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sdmmc3_dat1_pp4",		0x28, { "sdmmc3", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sdmmc3_dat2_pp3",		0x2c, { "sdmmc3", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sdmmc3_dat3_pp2",		0x30, { "sdmmc3", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "pex_l0_rst_n_pa0",		0x38, { "pe0", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "pex_l0_clkreq_n_pa1",	0x3c, { "pe0", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "pex_wake_n_pa2",		0x40, { "pe", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "pex_l1_rst_n_pa3",		0x44, { "pe1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "pex_l1_clkreq_n_pa4",	0x48, { "pe1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "sata_led_active_pa5",	0x4c, { "sata", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "spi1_mosi_pc0",		0x50, { "spi1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "spi1_miso_pc1",		0x54, { "spi1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "spi1_sck_pc2",		0x58, { "spi1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "spi1_cs0_pc3",		0x5c, { "spi1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "spi1_cs1_pc4",		0x60, { "spi1", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "spi2_mosi_pb4",		0x64, { "spi2", "dtv", "rsvd2", "rsvd3" } },
-	{ "spi2_miso_pb5",		0x68, { "spi2", "dtv", "rsvd2", "rsvd3" } },
-	{ "spi2_sck_pb6",		0x6c, { "spi2", "dtv", "rsvd2", "rsvd3" } },
-	{ "spi2_cs0_pb7",		0x70, { "spi2", "dtv", "rsvd2", "rsvd3" } },
-	{ "spi2_cs1_pdd0",		0x74, { "spi2", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "spi4_mosi_pc7",		0x78, { "spi4", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "spi4_miso_pd0",		0x7c, { "spi4", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "spi4_sck_pc5",		0x80, { "spi4", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "spi4_cs0_pc6",		0x84, { "spi4", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "qspi_sck_pee0",		0x88, { "qspi", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "qspi_cs_n_pee1",		0x8c, { "qspi", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "qspi_io0_pee2",		0x90, { "qspi", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "qspi_io1_pee3",		0x94, { "qspi", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "qspi_io2_pee4",		0x98, { "qspi", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "qspi_io3_pee5",		0x9c, { "qspi", "rsvd1", "rsvd2", "rsvd3" } },
-	{ "dmic1_clk_pe0",		0xa4, { "dmic1", "i2s3", "rsvd2", "rsvd3" } },
-	{ "dmic1_dat_pe1",		0xa8, { "dmic1", "i2s3", "rsvd2", "rsvd3" } },
-	{ "dmic2_clk_pe2",		0xac, { "dmic2", 

CVS commit: src/sys/arch/arm/broadcom

2019-09-28 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Sep 28 07:39:30 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm283x_platform.c

Log Message:
Fix build on SOC_BCM2835 kernels


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/arm/broadcom/bcm283x_platform.c

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



CVS commit: src/sys/arch/arm/broadcom

2019-09-28 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Sep 28 07:39:30 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm283x_platform.c

Log Message:
Fix build on SOC_BCM2835 kernels


To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/sys/arch/arm/broadcom/bcm283x_platform.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/arm/broadcom/bcm283x_platform.c
diff -u src/sys/arch/arm/broadcom/bcm283x_platform.c:1.25 src/sys/arch/arm/broadcom/bcm283x_platform.c:1.26
--- src/sys/arch/arm/broadcom/bcm283x_platform.c:1.25	Fri Sep 27 12:58:54 2019
+++ src/sys/arch/arm/broadcom/bcm283x_platform.c	Sat Sep 28 07:39:30 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: bcm283x_platform.c,v 1.25 2019/09/27 12:58:54 skrll Exp $	*/
+/*	$NetBSD: bcm283x_platform.c,v 1.26 2019/09/28 07:39:30 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2017 Jared D. McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: bcm283x_platform.c,v 1.25 2019/09/27 12:58:54 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm283x_platform.c,v 1.26 2019/09/28 07:39:30 skrll Exp $");
 
 #include "opt_arm_debug.h"
 #include "opt_bcm283x.h"
@@ -322,7 +322,6 @@ bcm2836_platform_devmap(void)
 
 	return devmap;
 }
-#endif
 
 static const struct pmap_devmap *
 bcm2838_platform_devmap(void)
@@ -342,6 +341,8 @@ bcm2838_platform_devmap(void)
 
 	return devmap;
 }
+#endif
+
 /*
  * Macros to translate between physical and virtual for a subset of the
  * kernel address space.  *Not* for general use.



CVS commit: src/sys/arch/aarch64/aarch64

2019-09-28 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Sep 28 07:06:50 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: trap.c

Log Message:
newline after break


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/aarch64/aarch64/trap.c

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



CVS commit: src/sys/arch/aarch64/aarch64

2019-09-28 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Sep 28 07:06:50 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: trap.c

Log Message:
newline after break


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/arch/aarch64/aarch64/trap.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/aarch64/aarch64/trap.c
diff -u src/sys/arch/aarch64/aarch64/trap.c:1.18 src/sys/arch/aarch64/aarch64/trap.c:1.19
--- src/sys/arch/aarch64/aarch64/trap.c:1.18	Wed Aug  7 09:49:40 2019
+++ src/sys/arch/aarch64/aarch64/trap.c	Sat Sep 28 07:06:50 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: trap.c,v 1.18 2019/08/07 09:49:40 jmcneill Exp $ */
+/* $NetBSD: trap.c,v 1.19 2019/09/28 07:06:50 skrll Exp $ */
 
 /*-
  * Copyright (c) 2014 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
 
 #include 
 
-__KERNEL_RCSID(1, "$NetBSD: trap.c,v 1.18 2019/08/07 09:49:40 jmcneill Exp $");
+__KERNEL_RCSID(1, "$NetBSD: trap.c,v 1.19 2019/09/28 07:06:50 skrll Exp $");
 
 #include "opt_arm_intr_impl.h"
 #include "opt_compat_netbsd32.h"
@@ -348,10 +348,12 @@ trap_el0_32sync(struct trapframe *tf)
 	case ESR_EC_SVC_A32:
 		(*l->l_proc->p_md.md_syscall)(tf);
 		break;
+
 	case ESR_EC_FP_ACCESS:
 		fpu_load(l);
 		userret(l);
 		break;
+
 	case ESR_EC_FP_TRAP_A32:
 		do_trapsignal(l, SIGFPE, FPE_FLTUND, NULL, esr); /* XXX */
 		userret(l);
@@ -361,6 +363,7 @@ trap_el0_32sync(struct trapframe *tf)
 		do_trapsignal(l, SIGBUS, BUS_ADRALN, (void *)tf->tf_pc, esr);
 		userret(l);
 		break;
+
 	case ESR_EC_SP_ALIGNMENT:
 		do_trapsignal(l, SIGBUS, BUS_ADRALN,
 		(void *)tf->tf_reg[13], esr); /* sp is r13 on AArch32 */



CVS commit: src/sys/arch/aarch64/aarch64

2019-09-28 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Sep 28 07:06:32 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: aarch64_machdep.c

Log Message:
Whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/sys/arch/aarch64/aarch64/aarch64_machdep.c

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



CVS commit: src/sys/arch/aarch64/aarch64

2019-09-28 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Sat Sep 28 07:06:32 UTC 2019

Modified Files:
src/sys/arch/aarch64/aarch64: aarch64_machdep.c

Log Message:
Whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.31 -r1.32 src/sys/arch/aarch64/aarch64/aarch64_machdep.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/aarch64/aarch64/aarch64_machdep.c
diff -u src/sys/arch/aarch64/aarch64/aarch64_machdep.c:1.31 src/sys/arch/aarch64/aarch64/aarch64_machdep.c:1.32
--- src/sys/arch/aarch64/aarch64/aarch64_machdep.c:1.31	Wed Sep 11 08:15:48 2019
+++ src/sys/arch/aarch64/aarch64/aarch64_machdep.c	Sat Sep 28 07:06:32 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: aarch64_machdep.c,v 1.31 2019/09/11 08:15:48 ryo Exp $ */
+/* $NetBSD: aarch64_machdep.c,v 1.32 2019/09/28 07:06:32 skrll Exp $ */
 
 /*-
  * Copyright (c) 2014 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__KERNEL_RCSID(1, "$NetBSD: aarch64_machdep.c,v 1.31 2019/09/11 08:15:48 ryo Exp $");
+__KERNEL_RCSID(1, "$NetBSD: aarch64_machdep.c,v 1.32 2019/09/28 07:06:32 skrll Exp $");
 
 #include "opt_arm_debug.h"
 #include "opt_ddb.h"
@@ -225,7 +225,6 @@ cpu_kernel_vm_init(uint64_t memory_start
 
 	aarch64_tlbi_all();
 
-
 	VPRINTF("%s: kernel phys start %lx end %lx+%lx\n", __func__,
 	kernstart_phys, kernend_phys, kernend_extra);
 	fdt_add_reserved_memory_range(kernstart_phys,



CVS commit: src/sys/arch/arm/broadcom

2019-09-27 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri Sep 27 12:58:55 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm283x_platform.c bcm283x_platform.h

Log Message:
BCM2838 (RPI4) support.

Based on a diff from mlelstv


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/arm/broadcom/bcm283x_platform.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/broadcom/bcm283x_platform.h

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/arm/broadcom/bcm283x_platform.c
diff -u src/sys/arch/arm/broadcom/bcm283x_platform.c:1.24 src/sys/arch/arm/broadcom/bcm283x_platform.c:1.25
--- src/sys/arch/arm/broadcom/bcm283x_platform.c:1.24	Wed Sep 25 18:01:03 2019
+++ src/sys/arch/arm/broadcom/bcm283x_platform.c	Fri Sep 27 12:58:54 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: bcm283x_platform.c,v 1.24 2019/09/25 18:01:03 skrll Exp $	*/
+/*	$NetBSD: bcm283x_platform.c,v 1.25 2019/09/27 12:58:54 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2017 Jared D. McNeill 
@@ -27,7 +27,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: bcm283x_platform.c,v 1.24 2019/09/25 18:01:03 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm283x_platform.c,v 1.25 2019/09/27 12:58:54 skrll Exp $");
 
 #include "opt_arm_debug.h"
 #include "opt_bcm283x.h"
@@ -113,6 +113,7 @@ __KERNEL_RCSID(0, "$NetBSD: bcm283x_plat
 void bcm2835_platform_early_putchar(char c);
 void bcm2836_platform_early_putchar(char c);
 void bcm2837_platform_early_putchar(char c);
+void bcm2838_platform_early_putchar(char c);
 
 extern void bcmgenfb_set_console_dev(device_t dev);
 void bcmgenfb_set_ioctl(int(*)(void *, void *, u_long, void *, int, struct lwp *));
@@ -129,14 +130,19 @@ bs_protos(bcm2835);
 bs_protos(bcm2835_a4x);
 bs_protos(bcm2836);
 bs_protos(bcm2836_a4x);
+bs_protos(bcm2838);
+bs_protos(bcm2838_a4x);
 
 struct bus_space bcm2835_bs_tag;
 struct bus_space bcm2835_a4x_bs_tag;
 struct bus_space bcm2836_bs_tag;
 struct bus_space bcm2836_a4x_bs_tag;
+struct bus_space bcm2838_bs_tag;
+struct bus_space bcm2838_a4x_bs_tag;
 
 static paddr_t bcm2835_bus_to_phys(bus_addr_t);
 static paddr_t bcm2836_bus_to_phys(bus_addr_t);
+static paddr_t bcm2838_bus_to_phys(bus_addr_t);
 
 #ifdef VERBOSE_INIT_ARM
 #define VPRINTF(...)	printf(__VA_ARGS__)
@@ -172,6 +178,22 @@ bcm2836_bus_to_phys(bus_addr_t ba)
 	return ba & ~BCM2835_BUSADDR_CACHE_MASK;
 }
 
+static paddr_t
+bcm2838_bus_to_phys(bus_addr_t ba)
+{
+
+	/* Attempt to find the PA device mapping */
+	if (ba >= BCM283X_PERIPHERALS_BASE_BUS &&
+	ba < BCM283X_PERIPHERALS_BASE_BUS + BCM283X_PERIPHERALS_SIZE)
+		return BCM2838_PERIPHERALS_BUS_TO_PHYS(ba);
+
+	if (ba >= BCM2838_ARM_LOCAL_BASE &&
+	ba < BCM2838_ARM_LOCAL_BASE + BCM2838_ARM_LOCAL_SIZE)
+		return ba;
+
+	return ba & ~BCM2835_BUSADDR_CACHE_MASK;
+}
+
 int
 bcm2835_bs_map(void *t, bus_addr_t ba, bus_size_t size, int flag,
 bus_space_handle_t *bshp)
@@ -220,6 +242,30 @@ bcm2836_a4x_bs_mmap(void *t, bus_addr_t 
 	return bcm2836_bs_mmap(t, ba, 4 * offset, prot, flags);
 }
 
+int
+bcm2838_bs_map(void *t, bus_addr_t ba, bus_size_t size, int flag,
+bus_space_handle_t *bshp)
+{
+	const paddr_t pa = bcm2838_bus_to_phys(ba);
+
+	return bus_space_map(_generic_bs_tag, pa, size, flag, bshp);
+}
+
+paddr_t
+bcm2838_bs_mmap(void *t, bus_addr_t ba, off_t offset, int prot, int flags)
+{
+	const paddr_t pa = bcm2838_bus_to_phys(ba);
+
+	return bus_space_mmap(_generic_bs_tag, pa, offset, prot, flags);
+}
+
+paddr_t
+bcm2838_a4x_bs_mmap(void *t, bus_addr_t ba, off_t offset, int prot, int flags)
+{
+
+	return bcm2838_bs_mmap(t, ba, 4 * offset, prot, flags);
+}
+
 struct arm32_dma_range bcm2835_dma_ranges[] = {
 	[0] = {
 		.dr_sysbase = 0,
@@ -234,6 +280,13 @@ struct arm32_dma_range bcm2836_dma_range
 	}
 };
 
+struct arm32_dma_range bcm2838_dma_ranges[] = {
+	[0] = {
+		.dr_sysbase = 0,
+		.dr_busbase = BCM2835_BUSADDR_CACHE_DIRECT,
+	}
+};
+
 
 #if defined(SOC_BCM2835)
 static const struct pmap_devmap *
@@ -257,7 +310,6 @@ bcm2836_platform_devmap(void)
 	static const struct pmap_devmap devmap[] = {
 		DEVMAP_ENTRY(BCM2836_PERIPHERALS_VBASE, BCM2836_PERIPHERALS_BASE,
 		BCM283X_PERIPHERALS_SIZE),	/* 16Mb */
-
 		DEVMAP_ENTRY(BCM2836_ARM_LOCAL_VBASE, BCM2836_ARM_LOCAL_BASE,
 		BCM2836_ARM_LOCAL_SIZE),
 #if defined(MULTIPROCESSOR) && defined(__aarch64__)
@@ -271,6 +323,25 @@ bcm2836_platform_devmap(void)
 	return devmap;
 }
 #endif
+
+static const struct pmap_devmap *
+bcm2838_platform_devmap(void)
+{
+	static const struct pmap_devmap devmap[] = {
+		DEVMAP_ENTRY(BCM2838_PERIPHERALS_VBASE, BCM2838_PERIPHERALS_BASE,
+		BCM283X_PERIPHERALS_SIZE),	/* 16Mb */
+		DEVMAP_ENTRY(BCM2838_ARM_LOCAL_VBASE, BCM2838_ARM_LOCAL_BASE,
+		BCM2838_ARM_LOCAL_SIZE),
+#if defined(MULTIPROCESSOR) && defined(__aarch64__)
+		/* for fdt cpu spin-table */
+		DEVMAP_ENTRY(BCM2836_ARM_SMP_VBASE, BCM2836_ARM_SMP_BASE,
+		BCM2836_ARM_SMP_SIZE),
+#endif
+		

CVS commit: src/sys/arch/arm/broadcom

2019-09-27 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Fri Sep 27 12:58:55 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm283x_platform.c bcm283x_platform.h

Log Message:
BCM2838 (RPI4) support.

Based on a diff from mlelstv


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/arm/broadcom/bcm283x_platform.c
cvs rdiff -u -r1.2 -r1.3 src/sys/arch/arm/broadcom/bcm283x_platform.h

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



CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 18:05:39 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835reg.h

Log Message:
Add BCM2838_{PERIPHERALS,ARM_LOCAL}_BASE and support macros


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/arm/broadcom/bcm2835reg.h

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/arm/broadcom/bcm2835reg.h
diff -u src/sys/arch/arm/broadcom/bcm2835reg.h:1.24 src/sys/arch/arm/broadcom/bcm2835reg.h:1.25
--- src/sys/arch/arm/broadcom/bcm2835reg.h:1.24	Wed Sep 25 18:01:03 2019
+++ src/sys/arch/arm/broadcom/bcm2835reg.h	Wed Sep 25 18:05:39 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: bcm2835reg.h,v 1.24 2019/09/25 18:01:03 skrll Exp $	*/
+/*	$NetBSD: bcm2835reg.h,v 1.25 2019/09/25 18:05:39 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -44,11 +44,17 @@
 #error Must define SOC_BCM2835 or SOC_BCM2836, and not both
 #endif
 
+#define	BCM2838_PERIPHERALS_BASE	0xfe00
 #define	BCM2836_PERIPHERALS_BASE	0x3f00
 #define	BCM2835_PERIPHERALS_BASE	0x2000
 #define	BCM283X_PERIPHERALS_SIZE	0x0100	/* 16MBytes */
 #define	BCM283X_PERIPHERALS_BASE_BUS	0x7e00
 
+#define	BCM2838_PERIPHERALS_PHYS_TO_BUS(a) \
+((a) - BCM2838_PERIPHERALS_BASE + BCM283X_PERIPHERALS_BASE_BUS)
+#define	BCM2838_PERIPHERALS_BUS_TO_PHYS(a) \
+((a) - BCM283X_PERIPHERALS_BASE_BUS + BCM2838_PERIPHERALS_BASE)
+
 #define	BCM2836_PERIPHERALS_PHYS_TO_BUS(a) \
 ((a) - BCM2836_PERIPHERALS_BASE + BCM283X_PERIPHERALS_BASE_BUS)
 #define	BCM2836_PERIPHERALS_BUS_TO_PHYS(a) \
@@ -206,6 +212,9 @@
 
 #define	BCM2835_UART0_CLK		300
 
+#define	BCM2838_ARM_LOCAL_BASE		0xff80
+#define	BCM2838_ARM_LOCAL_SIZE		0x0010	/* 1MByte */
+
 #define	BCM2836_ARM_LOCAL_BASE		0x4000
 #define	BCM2836_ARM_LOCAL_SIZE		0x1000	/* 4KBytes */
 



CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 18:05:39 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835reg.h

Log Message:
Add BCM2838_{PERIPHERALS,ARM_LOCAL}_BASE and support macros


To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/arm/broadcom/bcm2835reg.h

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



CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 18:01:03 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835reg.h bcm283x_platform.c

Log Message:
s/2835/283X/ in BCM2835_PERIPHERALS_BASE_BUS and BCM2835_PERIPHERALS_SIZE
to show they cover all of 283[5678]

NFCI


To generate a diff of this commit:
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/broadcom/bcm2835reg.h \
src/sys/arch/arm/broadcom/bcm283x_platform.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/arm/broadcom/bcm2835reg.h
diff -u src/sys/arch/arm/broadcom/bcm2835reg.h:1.23 src/sys/arch/arm/broadcom/bcm2835reg.h:1.24
--- src/sys/arch/arm/broadcom/bcm2835reg.h:1.23	Mon Sep 10 11:05:12 2018
+++ src/sys/arch/arm/broadcom/bcm2835reg.h	Wed Sep 25 18:01:03 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: bcm2835reg.h,v 1.23 2018/09/10 11:05:12 ryo Exp $	*/
+/*	$NetBSD: bcm2835reg.h,v 1.24 2019/09/25 18:01:03 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -46,40 +46,40 @@
 
 #define	BCM2836_PERIPHERALS_BASE	0x3f00
 #define	BCM2835_PERIPHERALS_BASE	0x2000
-#define	BCM2835_PERIPHERALS_SIZE	0x0100	/* 16MBytes */
-#define	BCM2835_PERIPHERALS_BASE_BUS	0x7e00
+#define	BCM283X_PERIPHERALS_SIZE	0x0100	/* 16MBytes */
+#define	BCM283X_PERIPHERALS_BASE_BUS	0x7e00
 
 #define	BCM2836_PERIPHERALS_PHYS_TO_BUS(a) \
-((a) - BCM2836_PERIPHERALS_BASE + BCM2835_PERIPHERALS_BASE_BUS)
+((a) - BCM2836_PERIPHERALS_BASE + BCM283X_PERIPHERALS_BASE_BUS)
 #define	BCM2836_PERIPHERALS_BUS_TO_PHYS(a) \
-((a) - BCM2835_PERIPHERALS_BASE_BUS + BCM2836_PERIPHERALS_BASE)
+((a) - BCM283X_PERIPHERALS_BASE_BUS + BCM2836_PERIPHERALS_BASE)
 
 #define	BCM2835_PERIPHERALS_PHYS_TO_BUS(a) \
-((a) - BCM2835_PERIPHERALS_BASE + BCM2835_PERIPHERALS_BASE_BUS)
+((a) - BCM2835_PERIPHERALS_BASE + BCM283X_PERIPHERALS_BASE_BUS)
 #define	BCM2835_PERIPHERALS_BUS_TO_PHYS(a) \
-((a) - BCM2835_PERIPHERALS_BASE_BUS + BCM2835_PERIPHERALS_BASE)
+((a) - BCM283X_PERIPHERALS_BASE_BUS + BCM2835_PERIPHERALS_BASE)
 
-#define	BCM2835_STIMER_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x3000)
-#define	BCM2835_DMA0_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x7000)
-#define	BCM2835_ARM_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0xB000)
-#define	BCM2835_PM_BASE		(BCM2835_PERIPHERALS_BASE_BUS + 0x0010)
-#define	BCM2835_CM_BASE  	(BCM2835_PERIPHERALS_BASE_BUS + 0x00101000)
-#define	BCM2835_RNG_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00104000)
-#define	BCM2835_GPIO_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x0020)
-#define	BCM2835_UART0_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00201000)
-#define	BCM2835_SDHOST_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00202000)
-#define	BCM2835_PCM_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00203000)
-#define	BCM2835_SPI0_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00204000)
-#define	BCM2835_BSC0_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00205000)
-#define	BCM2835_PWM_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x0020C000)
-#define	BCM2835_BSCSPISLV_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00214000)
-#define	BCM2835_AUX_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00215000)
-#define	BCM2835_AUX_UART_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00215040)
-#define	BCM2835_EMMC_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x0030)
-#define	BCM2835_BSC1_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00804000)
-#define	BCM2835_BSC2_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00805000)
-#define	BCM2835_USB_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x0098)
-#define	BCM2835_DMA15_BASE	(BCM2835_PERIPHERALS_BASE_BUS + 0x00E05000)
+#define	BCM2835_STIMER_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x3000)
+#define	BCM2835_DMA0_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x7000)
+#define	BCM2835_ARM_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0xB000)
+#define	BCM2835_PM_BASE		(BCM283X_PERIPHERALS_BASE_BUS + 0x0010)
+#define	BCM2835_CM_BASE  	(BCM283X_PERIPHERALS_BASE_BUS + 0x00101000)
+#define	BCM2835_RNG_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x00104000)
+#define	BCM2835_GPIO_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x0020)
+#define	BCM2835_UART0_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x00201000)
+#define	BCM2835_SDHOST_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x00202000)
+#define	BCM2835_PCM_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x00203000)
+#define	BCM2835_SPI0_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x00204000)
+#define	BCM2835_BSC0_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x00205000)
+#define	BCM2835_PWM_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x0020C000)
+#define	BCM2835_BSCSPISLV_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x00214000)
+#define	BCM2835_AUX_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x00215000)
+#define	BCM2835_AUX_UART_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x00215040)
+#define	BCM2835_EMMC_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x0030)
+#define	BCM2835_BSC1_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 0x00804000)
+#define	BCM2835_BSC2_BASE	(BCM283X_PERIPHERALS_BASE_BUS + 

CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 18:01:03 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835reg.h bcm283x_platform.c

Log Message:
s/2835/283X/ in BCM2835_PERIPHERALS_BASE_BUS and BCM2835_PERIPHERALS_SIZE
to show they cover all of 283[5678]

NFCI


To generate a diff of this commit:
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/broadcom/bcm2835reg.h \
src/sys/arch/arm/broadcom/bcm283x_platform.c

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



CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 16:57:11 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835_intr.c

Log Message:
Sprinkle KASSERTs


To generate a diff of this commit:
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/broadcom/bcm2835_intr.c

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



CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 16:57:11 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835_intr.c

Log Message:
Sprinkle KASSERTs


To generate a diff of this commit:
cvs rdiff -u -r1.23 -r1.24 src/sys/arch/arm/broadcom/bcm2835_intr.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/arm/broadcom/bcm2835_intr.c
diff -u src/sys/arch/arm/broadcom/bcm2835_intr.c:1.23 src/sys/arch/arm/broadcom/bcm2835_intr.c:1.24
--- src/sys/arch/arm/broadcom/bcm2835_intr.c:1.23	Wed Sep 25 16:50:28 2019
+++ src/sys/arch/arm/broadcom/bcm2835_intr.c	Wed Sep 25 16:57:10 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: bcm2835_intr.c,v 1.23 2019/09/25 16:50:28 skrll Exp $	*/
+/*	$NetBSD: bcm2835_intr.c,v 1.24 2019/09/25 16:57:10 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2012, 2015 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_intr.c,v 1.23 2019/09/25 16:50:28 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_intr.c,v 1.24 2019/09/25 16:57:10 skrll Exp $");
 
 #define _INTR_PRIVATE
 
@@ -309,6 +309,8 @@ bcm2835_irq_handler(void *frame)
 	const uint32_t oldipl_mask = __BIT(oldipl);
 	int ipl_mask = 0;
 
+	KASSERT(cpuid < BCM2836_NCPUS);
+
 	ci->ci_data.cpu_nintr++;
 
 	bcm2835_barrier();
@@ -479,6 +481,7 @@ bcm2836mp_pic_unblock_irqs(struct pic_so
 	const bus_space_handle_t ioh = bcml1icu_sc->sc_ioh;
 	const cpuid_t cpuid = pic - _pic[0];
 
+	KASSERT(cpuid < BCM2836_NCPUS);
 	KASSERT(irqbase == 0);
 
 	if (irq_mask & BCM2836MP_TIMER_IRQS) {
@@ -525,6 +528,7 @@ bcm2836mp_pic_block_irqs(struct pic_soft
 	const bus_space_handle_t ioh = bcml1icu_sc->sc_ioh;
 	const cpuid_t cpuid = pic - _pic[0];
 
+	KASSERT(cpuid < BCM2836_NCPUS);
 	KASSERT(irqbase == 0);
 
 	if (irq_mask & BCM2836MP_TIMER_IRQS) {
@@ -562,6 +566,7 @@ bcm2836mp_pic_find_pending_irqs(struct p
 	uint32_t lpending;
 	int ipl = 0;
 
+	KASSERT(cpuid < BCM2836_NCPUS);
 	KASSERT(pic == _pic[cpuid]);
 
 	bcm2835_barrier();
@@ -598,10 +603,13 @@ bcm2836mp_pic_source_name(struct pic_sof
 #if defined(MULTIPROCESSOR)
 static void bcm2836mp_cpu_init(struct pic_softc *pic, struct cpu_info *ci)
 {
+	const cpuid_t cpuid = ci->ci_core_id;
+
+	KASSERT(cpuid < BCM2836_NCPUS);
 
 	/* Enable IRQ and not FIQ */
 	bus_space_write_4(bcml1icu_sc->sc_iot, bcml1icu_sc->sc_ioh,
-	BCM2836_LOCAL_MAILBOX_IRQ_CONTROLN(ci->ci_core_id), 1);
+	BCM2836_LOCAL_MAILBOX_IRQ_CONTROLN(cpuid), 1);
 }
 
 static void
@@ -612,6 +620,7 @@ bcm2836mp_send_ipi(struct pic_softc *pic
 	KASSERT(pic->pic_cpus != NULL);
 
 	const cpuid_t cpuid = pic - _pic[0];
+	KASSERT(cpuid < BCM2836_NCPUS);
 
 	bus_space_write_4(bcml1icu_sc->sc_iot, bcml1icu_sc->sc_ioh,
 	BCM2836_LOCAL_MAILBOX0_SETN(cpuid), __BIT(ipi));
@@ -624,6 +633,8 @@ bcm2836mp_ipi_handler(void *priv)
 	const cpuid_t cpuid = ci->ci_core_id;
 	uint32_t ipimask, bit;
 
+	KASSERT(cpuid < BCM2836_NCPUS);
+
 	ipimask = bus_space_read_4(bcml1icu_sc->sc_iot, bcml1icu_sc->sc_ioh,
 	BCM2836_LOCAL_MAILBOX0_CLRN(cpuid));
 	bus_space_write_4(bcml1icu_sc->sc_iot, bcml1icu_sc->sc_ioh,
@@ -671,6 +682,8 @@ bcm2836mp_intr_init(void *priv, struct c
 	const cpuid_t cpuid = ci->ci_core_id;
 	struct pic_softc * const pic = _pic[cpuid];
 
+	KASSERT(cpuid < BCM2836_NCPUS);
+
 #if defined(MULTIPROCESSOR)
 	pic->pic_cpus = ci->ci_kcpuset;
 



CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 16:50:28 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835_intr.c

Log Message:
Sprinkle static


To generate a diff of this commit:
cvs rdiff -u -r1.22 -r1.23 src/sys/arch/arm/broadcom/bcm2835_intr.c

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



CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 16:50:28 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835_intr.c

Log Message:
Sprinkle static


To generate a diff of this commit:
cvs rdiff -u -r1.22 -r1.23 src/sys/arch/arm/broadcom/bcm2835_intr.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/arm/broadcom/bcm2835_intr.c
diff -u src/sys/arch/arm/broadcom/bcm2835_intr.c:1.22 src/sys/arch/arm/broadcom/bcm2835_intr.c:1.23
--- src/sys/arch/arm/broadcom/bcm2835_intr.c:1.22	Wed Sep 25 16:49:37 2019
+++ src/sys/arch/arm/broadcom/bcm2835_intr.c	Wed Sep 25 16:50:28 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: bcm2835_intr.c,v 1.22 2019/09/25 16:49:37 skrll Exp $	*/
+/*	$NetBSD: bcm2835_intr.c,v 1.23 2019/09/25 16:50:28 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2012, 2015 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_intr.c,v 1.22 2019/09/25 16:49:37 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_intr.c,v 1.23 2019/09/25 16:50:28 skrll Exp $");
 
 #define _INTR_PRIVATE
 
@@ -170,8 +170,8 @@ struct bcm2835icu_softc {
 	int sc_phandle;
 };
 
-struct bcm2835icu_softc *bcml1icu_sc;
-struct bcm2835icu_softc *bcmicu_sc;
+static struct bcm2835icu_softc *bcml1icu_sc;
+static struct bcm2835icu_softc *bcmicu_sc;
 
 #define read_bcm2835reg(o)	\
 	bus_space_read_4(bcmicu_sc->sc_iot, bcmicu_sc->sc_ioh, (o))



CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 16:49:37 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835_intr.c

Log Message:
KNF


To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/sys/arch/arm/broadcom/bcm2835_intr.c

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



CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 16:49:37 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835_intr.c

Log Message:
KNF


To generate a diff of this commit:
cvs rdiff -u -r1.21 -r1.22 src/sys/arch/arm/broadcom/bcm2835_intr.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/arm/broadcom/bcm2835_intr.c
diff -u src/sys/arch/arm/broadcom/bcm2835_intr.c:1.21 src/sys/arch/arm/broadcom/bcm2835_intr.c:1.22
--- src/sys/arch/arm/broadcom/bcm2835_intr.c:1.21	Wed Sep 25 16:48:06 2019
+++ src/sys/arch/arm/broadcom/bcm2835_intr.c	Wed Sep 25 16:49:37 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: bcm2835_intr.c,v 1.21 2019/09/25 16:48:06 skrll Exp $	*/
+/*	$NetBSD: bcm2835_intr.c,v 1.22 2019/09/25 16:49:37 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2012, 2015 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_intr.c,v 1.21 2019/09/25 16:48:06 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_intr.c,v 1.22 2019/09/25 16:49:37 skrll Exp $");
 
 #define _INTR_PRIVATE
 
@@ -705,6 +705,7 @@ bcm2836mp_intr_init(void *priv, struct c
 static int
 bcm2836mp_icu_fdt_decode_irq(u_int *specifier)
 {
+
 	if (!specifier)
 		return -1;
 	return be32toh(specifier[0]);



CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 16:48:06 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835_intr.c

Log Message:
Whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/arch/arm/broadcom/bcm2835_intr.c

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



CVS commit: src/sys/arch/arm/broadcom

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 16:48:06 UTC 2019

Modified Files:
src/sys/arch/arm/broadcom: bcm2835_intr.c

Log Message:
Whitespace


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 src/sys/arch/arm/broadcom/bcm2835_intr.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/arm/broadcom/bcm2835_intr.c
diff -u src/sys/arch/arm/broadcom/bcm2835_intr.c:1.20 src/sys/arch/arm/broadcom/bcm2835_intr.c:1.21
--- src/sys/arch/arm/broadcom/bcm2835_intr.c:1.20	Wed Mar 27 05:47:50 2019
+++ src/sys/arch/arm/broadcom/bcm2835_intr.c	Wed Sep 25 16:48:06 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: bcm2835_intr.c,v 1.20 2019/03/27 05:47:50 ryo Exp $	*/
+/*	$NetBSD: bcm2835_intr.c,v 1.21 2019/09/25 16:48:06 skrll Exp $	*/
 
 /*-
  * Copyright (c) 2012, 2015 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_intr.c,v 1.20 2019/03/27 05:47:50 ryo Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_intr.c,v 1.21 2019/09/25 16:48:06 skrll Exp $");
 
 #define _INTR_PRIVATE
 
@@ -547,7 +547,7 @@ bcm2836mp_pic_block_irqs(struct pic_soft
 	}
 	if (irq_mask & BCM2836MP_PMU_IRQ) {
 		bus_space_write_4(iot, ioh, BCM2836_LOCAL_PM_ROUTING_CLR,
-		 __BIT(cpuid));
+		__BIT(cpuid));
 	}
 
 	bcm2835_barrier();



CVS commit: src/sys/arch/arm/arm32

2019-09-25 Thread Nick Hudson
Module Name:src
Committed By:   skrll
Date:   Wed Sep 25 16:37:54 UTC 2019

Modified Files:
src/sys/arch/arm/arm32: pmap.c

Log Message:
Convert a __CTASSERT into a KASSERT as L1_S_CACHE_MASK may not be a
compile time constant if ARM_NMMUS > 1


To generate a diff of this commit:
cvs rdiff -u -r1.373 -r1.374 src/sys/arch/arm/arm32/pmap.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/arm/arm32/pmap.c
diff -u src/sys/arch/arm/arm32/pmap.c:1.373 src/sys/arch/arm/arm32/pmap.c:1.374
--- src/sys/arch/arm/arm32/pmap.c:1.373	Tue Apr 23 11:21:21 2019
+++ src/sys/arch/arm/arm32/pmap.c	Wed Sep 25 16:37:54 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: pmap.c,v 1.373 2019/04/23 11:21:21 bouyer Exp $	*/
+/*	$NetBSD: pmap.c,v 1.374 2019/09/25 16:37:54 skrll Exp $	*/
 
 /*
  * Copyright 2003 Wasabi Systems, Inc.
@@ -221,7 +221,7 @@
 #include 
 #endif
 
-__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.373 2019/04/23 11:21:21 bouyer Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pmap.c,v 1.374 2019/09/25 16:37:54 skrll Exp $");
 
 //#define PMAP_DEBUG
 #ifdef PMAP_DEBUG
@@ -6406,7 +6406,7 @@ pmap_set_pt_cache_mode(pd_entry_t *kl1, 
 		pd_entry_t pde = *pdep;
 
 		if (l1pte_section_p(pde)) {
-			__CTASSERT((L1_S_CACHE_MASK & L1_S_V6_SUPER) == 0);
+			KASSERT((L1_S_CACHE_MASK & L1_S_V6_SUPER) == 0);
 			if ((pde & L1_S_CACHE_MASK) != pte_l1_s_cache_mode_pt) {
 *pdep = (pde & ~L1_S_CACHE_MASK) |
 pte_l1_s_cache_mode_pt;



  1   2   3   4   5   6   >