Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/pci use device_private() instead of casting self as ...



details:   https://anonhg.NetBSD.org/src/rev/205656374d1a
branches:  trunk
changeset: 1010270:205656374d1a
user:      sevan <sevan%NetBSD.org@localhost>
date:      Wed May 20 20:18:37 2020 +0000

description:
use device_private() instead of casting self as it doesn't work here.
Bump rcs tag which was missed in r1.9

diffstat:

 sys/dev/pci/if_rge.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (29 lines):

diff -r 9165a5db8074 -r 205656374d1a sys/dev/pci/if_rge.c
--- a/sys/dev/pci/if_rge.c      Wed May 20 18:52:48 2020 +0000
+++ b/sys/dev/pci/if_rge.c      Wed May 20 20:18:37 2020 +0000
@@ -1,5 +1,5 @@
-/*     $NetBSD: if_rge.c,v 1.10 2020/04/30 00:32:16 sevan Exp $        */
-/*     $OpenBSD: if_rge.c,v 1.2 2020/01/02 09:00:45 kevlo Exp $        */
+/*     $NetBSD: if_rge.c,v 1.11 2020/05/20 20:18:37 sevan Exp $        */
+/*     $OpenBSD: if_rge.c,v 1.3 2020/03/27 15:15:24 krw Exp $  */
 
 /*
  * Copyright (c) 2019 Kevin Lo <kevlo%openbsd.org@localhost>
@@ -18,7 +18,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_rge.c,v 1.10 2020/04/30 00:32:16 sevan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_rge.c,v 1.11 2020/05/20 20:18:37 sevan Exp $");
 
 /* #include "vlan.h" Sevan */
 
@@ -189,7 +189,7 @@
 void
 rge_attach(device_t parent, device_t self, void *aux)
 {
-       struct rge_softc *sc = (struct rge_softc *)self;
+       struct rge_softc *sc = device_private(self);
        struct pci_attach_args *pa = aux;
        pci_chipset_tag_t pc = pa->pa_pc;
        pci_intr_handle_t ih;



Home | Main Index | Thread Index | Old Index