Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/atari Rename device name of Crazy Dots II ET4000 vi...



details:   https://anonhg.NetBSD.org/src/rev/3b0ffa041c66
branches:  trunk
changeset: 759520:3b0ffa041c66
user:      tsutsui <tsutsui%NetBSD.org@localhost>
date:      Sun Dec 12 09:56:15 2010 +0000

description:
Rename device name of Crazy Dots II ET4000 video from et(4) to et4k(4)
to deliver the name to recently committed newer and more common MI device,
et(4) at PCIe (Agere ET1310/ET1301 network driver) in PR kern/39094.
http://mail-index.NetBSD.org/source-changes/2010/11/13/msg014416.html

No particular reaction for a month on source-changes-d@,
no responsible person on atari port, and probably
no active user still using ET4000 on TT030 running NetBSD/atari.

diffstat:

 sys/arch/atari/conf/GENERIC.in  |    4 +-
 sys/arch/atari/conf/files.atari |    8 +-
 sys/arch/atari/vme/et4000.c     |  152 ++++++++++++++++++++--------------------
 3 files changed, 82 insertions(+), 82 deletions(-)

diffs (truncated from 426 to 300 lines):

diff -r dd86c740838e -r 3b0ffa041c66 sys/arch/atari/conf/GENERIC.in
--- a/sys/arch/atari/conf/GENERIC.in    Sun Dec 12 09:03:06 2010 +0000
+++ b/sys/arch/atari/conf/GENERIC.in    Sun Dec 12 09:56:15 2010 +0000
@@ -1,5 +1,5 @@
 #
-#      $NetBSD: GENERIC.in,v 1.91 2010/11/23 11:13:54 hannken Exp $
+#      $NetBSD: GENERIC.in,v 1.92 2010/12/12 09:56:15 tsutsui Exp $
 #
 # Generic atari
 #
@@ -357,7 +357,7 @@
 le0            at vme0 irq 5   # Lance ethernet (Riebl/PAM).
 le0            at vme0 irq 4   # Lance ethernet (BVME410).
 we0            at vme0 irq 4   # SMC Elite Ultra with SMC_TT VME-ISA bridge
-et0            at vme0         # Crazy Dots II
+et4k0          at vme0         # Crazy Dots II
 #endif /* TT030_KERNEL */
 #endif /* SMALL030_KERNEL */
 
diff -r dd86c740838e -r 3b0ffa041c66 sys/arch/atari/conf/files.atari
--- a/sys/arch/atari/conf/files.atari   Sun Dec 12 09:03:06 2010 +0000
+++ b/sys/arch/atari/conf/files.atari   Sun Dec 12 09:56:15 2010 +0000
@@ -1,5 +1,5 @@
 #
-#      $NetBSD: files.atari,v 1.117 2010/04/01 17:07:51 tsutsui Exp $
+#      $NetBSD: files.atari,v 1.118 2010/12/12 09:56:15 tsutsui Exp $
 
 maxpartitions 16
 
@@ -101,9 +101,9 @@
 file   arch/atari/vme/leo.c            leo needs-count
 
 # ET4000 (Crazy Dots II) color video
-device et
-attach et at vme
-file   arch/atari/vme/et4000.c         et needs-count
+device et4k
+attach et4k at vme
+file   arch/atari/vme/et4000.c         et4k needs-count
 
 # graphic devices
 define grfb {}
diff -r dd86c740838e -r 3b0ffa041c66 sys/arch/atari/vme/et4000.c
--- a/sys/arch/atari/vme/et4000.c       Sun Dec 12 09:03:06 2010 +0000
+++ b/sys/arch/atari/vme/et4000.c       Sun Dec 12 09:56:15 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: et4000.c,v 1.22 2010/04/13 11:31:11 tsutsui Exp $      */
+/*     $NetBSD: et4000.c,v 1.23 2010/12/12 09:56:16 tsutsui Exp $      */
 /*-
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
  * All rights reserved.
@@ -45,7 +45,7 @@
 */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: et4000.c,v 1.22 2010/04/13 11:31:11 tsutsui Exp $");
+__KERNEL_RCSID(0, "$NetBSD: et4000.c,v 1.23 2010/12/12 09:56:16 tsutsui Exp $");
 
 #include <sys/param.h>
 #include <sys/ioctl.h>
@@ -78,41 +78,41 @@
 #define VGA_MAPPABLE   (128 * 1024)            /* 0x20000 */
 #define VGA_BASE       0xa0000
 
-static int     et_vme_match(struct device *, struct cfdata *, void *);
-static void    et_vme_attach(struct device *, struct device *, void *);
-static int     et_probe_addresses(struct vme_attach_args *);
-static void    et_start(bus_space_tag_t *, bus_space_handle_t *, int *,
+static int     et4k_vme_match(struct device *, struct cfdata *, void *);
+static void    et4k_vme_attach(struct device *, struct device *, void *);
+static int     et4k_probe_addresses(struct vme_attach_args *);
+static void    et4k_start(bus_space_tag_t *, bus_space_handle_t *, int *,
                    u_char *);
-static void    et_stop(bus_space_tag_t *, bus_space_handle_t *, int *,
+static void    et4k_stop(bus_space_tag_t *, bus_space_handle_t *, int *,
                    u_char *);
-static int     et_detect(bus_space_tag_t *, bus_space_tag_t *,
+static int     et4k_detect(bus_space_tag_t *, bus_space_tag_t *,
                    bus_space_handle_t *, bus_space_handle_t *, u_int);
 
-int            eton(dev_t);
-int            etoff(dev_t);
+int            et4kon(dev_t);
+int            et4koff(dev_t);
 
 /* Register and screen memory addresses for ET4000 based VME cards */
-static struct et_addresses {
+static struct et4k_addresses {
        u_long io_addr;
        u_long io_size;
        u_long mem_addr;
        u_long mem_size;
-} etstd[] = {
+} et4kstd[] = {
        { 0xfebf0000, REG_MAPPABLE, 0xfec00000, FRAME_MAPPABLE }, /* Crazy Dots VME & II */
        { 0xfed00000, REG_MAPPABLE, 0xfec00000, FRAME_MAPPABLE }, /* Spektrum I & HC */
        { 0xfed80000, REG_MAPPABLE, 0xfec00000, FRAME_MAPPABLE }  /* Spektrum TC */
 };
 
-#define NETSTD (sizeof(etstd) / sizeof(etstd[0]))
+#define NET4KSTD (sizeof(et4kstd) / sizeof(et4kstd[0]))
 
-struct grfabs_et_priv {
+struct grfabs_et4k_priv {
        volatile void * regkva;
        volatile void * memkva;
        int                     regsz;
        int                     memsz;
-} et_priv;
+} et4k_priv;
 
-struct et_softc {
+struct et4k_softc {
        struct device sc_dev;
        bus_space_tag_t sc_iot;
        bus_space_tag_t sc_memt;
@@ -127,19 +127,19 @@
 
 #define ET_SC_FLAGS_INUSE 1
 
-CFATTACH_DECL(et, sizeof(struct et_softc),
-    et_vme_match, et_vme_attach, NULL, NULL);
+CFATTACH_DECL(et4k, sizeof(struct et4k_softc),
+    et4k_vme_match, et4k_vme_attach, NULL, NULL);
 
-dev_type_open(etopen);
-dev_type_close(etclose);
-dev_type_read(etread);
-dev_type_write(etwrite);
-dev_type_ioctl(etioctl);
-dev_type_mmap(etmmap);
+dev_type_open(et4kopen);
+dev_type_close(et4kclose);
+dev_type_read(et4kread);
+dev_type_write(et4kwrite);
+dev_type_ioctl(et4kioctl);
+dev_type_mmap(et4kmmap);
 
-const struct cdevsw et_cdevsw = {
-       etopen, etclose, etread, etwrite, etioctl,
-       nostop, notty, nopoll, etmmap, nokqfilter,
+const struct cdevsw et4k_cdevsw = {
+       et4kopen, et4kclose, et4kread, et4kwrite, et4kioctl,
+       nostop, notty, nopoll, et4kmmap, nokqfilter,
 };
 
 /*
@@ -147,15 +147,15 @@
  * match Spektrum cards too (untested).
  */
 int 
-et_vme_match(struct device *pdp, struct cfdata *cfp, void *auxp)
+et4k_vme_match(struct device *pdp, struct cfdata *cfp, void *auxp)
 {
        struct vme_attach_args *va = auxp;
 
-       return et_probe_addresses(va);
+       return et4k_probe_addresses(va);
 }
 
 static int
-et_probe_addresses(struct vme_attach_args *va)
+et4k_probe_addresses(struct vme_attach_args *va)
 {
        int i, found = 0;
        bus_space_tag_t iot;
@@ -167,35 +167,35 @@
        memt = va->va_memt;
 
 /* Loop around our possible addresses looking for a match */
-       for (i = 0; i < NETSTD; i++) {
-               struct et_addresses *et_ap = &etstd[i];
+       for (i = 0; i < NET4KSTD; i++) {
+               struct et4k_addresses *et4k_ap = &et4kstd[i];
                struct vme_attach_args vat = *va;
 
                if (vat.va_irq != VMECF_IRQ_DEFAULT) {
-                       printf("et probe: config error: no irq support\n");
+                       printf("%s: config error: no irq support\n", __func__);
                        return 0;
                }
                if (vat.va_iobase == VMECF_IOPORT_DEFAULT)
-                       vat.va_iobase = et_ap->io_addr;
+                       vat.va_iobase = et4k_ap->io_addr;
                if (vat.va_maddr == VMECF_MEM_DEFAULT)
-                       vat.va_maddr = et_ap->mem_addr;
+                       vat.va_maddr = et4k_ap->mem_addr;
                if (vat.va_iosize == VMECF_IOSIZE_DEFAULT)
-                       vat.va_iosize = et_ap->io_size;
+                       vat.va_iosize = et4k_ap->io_size;
                if (vat.va_msize == VMECF_MEMSIZ_DEFAULT)
-                       vat.va_msize = et_ap->mem_size;
+                       vat.va_msize = et4k_ap->mem_size;
                if (bus_space_map(iot, vat.va_iobase, vat.va_iosize, 0,
                                  &ioh)) {
-                       printf("et probe: cannot map io area\n");
+                       printf("%s: cannot map io area\n", __func__);
                        return 0;
                }
                if (bus_space_map(memt, vat.va_maddr, vat.va_msize,
                                  BUS_SPACE_MAP_LINEAR|BUS_SPACE_MAP_CACHEABLE,
                                  &memh)) {
                        bus_space_unmap(iot, ioh, vat.va_iosize);
-                       printf("et probe: cannot map memory area\n");
+                       printf("%s: cannot map memory area\n", __func__);
                        return 0;
                }
-               found = et_detect(&iot, &memt, &ioh, &memh, vat.va_msize);
+               found = et4k_detect(&iot, &memt, &ioh, &memh, vat.va_msize);
                bus_space_unmap(iot, ioh, vat.va_iosize);
                bus_space_unmap(memt, memh, vat.va_msize);
                if (found) {
@@ -207,7 +207,7 @@
 }
 
 static void
-et_start(bus_space_tag_t *iot, bus_space_handle_t *ioh, int *vgabase, u_char *saved)
+et4k_start(bus_space_tag_t *iot, bus_space_handle_t *ioh, int *vgabase, u_char *saved)
 {
        /* Enable VGA */
        bus_space_write_1(*iot, *ioh, GREG_VIDEOSYSENABLE, 0x01);
@@ -230,7 +230,7 @@
 }
 
 static void
-et_stop(bus_space_tag_t *iot, bus_space_handle_t *ioh, int *vgabase, u_char *saved)
+et4k_stop(bus_space_tag_t *iot, bus_space_handle_t *ioh, int *vgabase, u_char *saved)
 {
        /* Restore writes to CRTC[0..7] */
        bus_space_write_1(*iot, *ioh, *vgabase + 0x04, 0x11);
@@ -243,7 +243,7 @@
 }
 
 static int
-et_detect(bus_space_tag_t *iot, bus_space_tag_t *memt, bus_space_handle_t *ioh, bus_space_handle_t *memh, u_int memsize)
+et4k_detect(bus_space_tag_t *iot, bus_space_tag_t *memt, bus_space_handle_t *ioh, bus_space_handle_t *memh, u_int memsize)
 {
        u_char orig, new, saved;
        int vgabase;
@@ -254,7 +254,7 @@
        if (!bus_space_peek_1(*memt, *memh, 0))
                return 0;
 
-       et_start(iot, ioh, &vgabase, &saved);
+       et4k_start(iot, ioh, &vgabase, &saved);
 
        /* Is the card a Tseng card?  Check read/write of ATC[16] */
        (void)bus_space_read_1(*iot, *ioh, vgabase + 0x0a);
@@ -269,7 +269,7 @@
                printf("et4000: ATC[16] failed (%x != %x)\n",
                    new, (orig ^ 0x10));
 #else
-               et_stop(iot, ioh, &vgabase, &saved);
+               et4k_stop(iot, ioh, &vgabase, &saved);
                return 0;
 #endif
        }
@@ -284,7 +284,7 @@
                printf("et4000: CRTC[33] failed (%x != %x)\n",
                    new, (orig ^ 0x0f));
 #else
-               et_stop(iot, ioh, &vgabase, &saved);
+               et4k_stop(iot, ioh, &vgabase, &saved);
                return 0;
 #endif
        }
@@ -309,7 +309,7 @@
 #ifdef DEBUG_ET4000
                printf("et4000: Video base write/read failed\n");
 #else
-               et_stop(iot, ioh, &vgabase, &saved);
+               et4k_stop(iot, ioh, &vgabase, &saved);
                return 0;
 #endif
        }
@@ -319,19 +319,19 @@
 #ifdef DEBUG_ET4000
                printf("et4000: Video top write/read failed\n");
 #else
-               et_stop(iot, ioh, &vgabase, &saved);
+               et4k_stop(iot, ioh, &vgabase, &saved);
                return 0;
 #endif
        }
 
-       et_stop(iot, ioh, &vgabase, &saved);
+       et4k_stop(iot, ioh, &vgabase, &saved);
        return 1;
 }
 
 static void
-et_vme_attach(struct device *parent, struct device *self, void *aux)
+et4k_vme_attach(struct device *parent, struct device *self, void *aux)
 {
-       struct et_softc *sc = (struct et_softc *)self;
+       struct et4k_softc *sc = (struct et4k_softc *)self;
        struct vme_attach_args *va = aux;
        bus_space_handle_t ioh;
        bus_space_handle_t memh;
@@ -339,9 +339,9 @@



Home | Main Index | Thread Index | Old Index