Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/pci Re-enable radio at bktr, only if NRADIO > 0 and ...



details:   https://anonhg.NetBSD.org/src/rev/b179069fe55b
branches:  trunk
changeset: 520329:b179069fe55b
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Mon Jan 07 18:05:33 2002 +0000

description:
Re-enable radio at bktr, only if NRADIO > 0 and an FM tuner is present.

diffstat:

 sys/dev/pci/bktr/bktr_os.c |  11 ++++-------
 sys/dev/pci/files.pci      |   4 ++--
 2 files changed, 6 insertions(+), 9 deletions(-)

diffs (58 lines):

diff -r 625331aaf3c4 -r b179069fe55b sys/dev/pci/bktr/bktr_os.c
--- a/sys/dev/pci/bktr/bktr_os.c        Mon Jan 07 17:44:42 2002 +0000
+++ b/sys/dev/pci/bktr/bktr_os.c        Mon Jan 07 18:05:33 2002 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: bktr_os.c,v 1.27 2002/01/07 12:12:55 tron Exp $        */
+/*     $NetBSD: bktr_os.c,v 1.28 2002/01/07 18:05:34 jmcneill Exp $    */
 
 /* FreeBSD: src/sys/dev/bktr/bktr_os.c,v 1.20 2000/10/20 08:16:53 roger Exp */
 
@@ -50,7 +50,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bktr_os.c,v 1.27 2002/01/07 12:12:55 tron Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bktr_os.c,v 1.28 2002/01/07 18:05:34 jmcneill Exp $");
 
 #ifdef __FreeBSD__
 #include "bktr.h"
@@ -195,11 +195,7 @@
 
 /* Support for radio(4) under NetBSD */
 #ifdef __NetBSD__
-#ifdef RADIO_ON_BKTR_WORKS
 #include "radio.h"
-#else
-#define        NRADIO  0
-#endif
 #if NRADIO > 0
 #include <sys/radioio.h>
 #include <dev/radio_if.h>
@@ -1532,7 +1528,8 @@
 
 #if NRADIO > 0
        /* attach to radio(4) */
-       radio_attach_mi(&bktr_hw_if, bktr, &bktr->bktr_dev);
+       if (bktr->card.tuner->pllControl[3] != 0x00)
+               radio_attach_mi(&bktr_hw_if, bktr, &bktr->bktr_dev);
 #endif
 }
 
diff -r 625331aaf3c4 -r b179069fe55b sys/dev/pci/files.pci
--- a/sys/dev/pci/files.pci     Mon Jan 07 17:44:42 2002 +0000
+++ b/sys/dev/pci/files.pci     Mon Jan 07 18:05:33 2002 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: files.pci,v 1.158 2002/01/07 17:44:45 drochner Exp $
+#      $NetBSD: files.pci,v 1.159 2002/01/07 18:05:33 jmcneill Exp $
 #
 # Config file and device description for machine-independent PCI code.
 # Included by ports that need it.  Requires that the SCSI files be
@@ -234,7 +234,7 @@
 file   dev/ic/ibm561.c                 tga
 
 # Brooktree Bt848 video capture
-device bktr: pcibus
+device bktr: pcibus, radiodev
 attach bktr at pci
 file   dev/pci/bktr/bktr_audio.c       bktr
 file   dev/pci/bktr/bktr_card.c        bktr



Home | Main Index | Thread Index | Old Index