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 symbolic PCI_PRODUCTs.
details: https://anonhg.NetBSD.org/src/rev/92fcfe5f6974
branches: trunk
changeset: 770806:92fcfe5f6974
user: jakllsch <jakllsch%NetBSD.org@localhost>
date: Wed Nov 02 15:18:46 2011 +0000
description:
Use symbolic PCI_PRODUCTs.
diffstat:
sys/dev/pci/virtio.c | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
diffs (31 lines):
diff -r ec03e76ed210 -r 92fcfe5f6974 sys/dev/pci/virtio.c
--- a/sys/dev/pci/virtio.c Wed Nov 02 15:14:49 2011 +0000
+++ b/sys/dev/pci/virtio.c Wed Nov 02 15:18:46 2011 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: virtio.c,v 1.1 2011/10/30 12:12:21 hannken Exp $ */
+/* $NetBSD: virtio.c,v 1.2 2011/11/02 15:18:46 jakllsch Exp $ */
/*
* Copyright (c) 2010 Minoura Makoto.
@@ -26,7 +26,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: virtio.c,v 1.1 2011/10/30 12:12:21 hannken Exp $");
+__KERNEL_RCSID(0, "$NetBSD: virtio.c,v 1.2 2011/11/02 15:18:46 jakllsch Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -78,8 +78,10 @@
pa = (struct pci_attach_args *)aux;
switch (PCI_VENDOR(pa->pa_id)) {
case PCI_VENDOR_QUMRANET:
- if ((0x1000 <= PCI_PRODUCT(pa->pa_id)) &&
- (PCI_PRODUCT(pa->pa_id) <= 0x103f))
+ if ((PCI_PRODUCT_QUMRANET_VIRTIO_1000 <=
+ PCI_PRODUCT(pa->pa_id)) &&
+ (PCI_PRODUCT(pa->pa_id) <=
+ PCI_PRODUCT_QUMRANET_VIRTIO_103f))
return 1;
break;
}
Home |
Main Index |
Thread Index |
Old Index