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 a local static variable to hold "pktq_rps_ha...
details: https://anonhg.NetBSD.org/src/rev/7351ae180858
branches: trunk
changeset: 1024314:7351ae180858
user: hannken <hannken%NetBSD.org@localhost>
date: Mon Oct 18 08:15:00 2021 +0000
description:
Use a local static variable to hold "pktq_rps_hash_default"
like the other devices do.
Kernel ALL/amd64 compiles again.
OK: Kengo NAKAHARA <knakahara%netbsd.org@localhost>
diffstat:
sys/dev/pci/xmm7360.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diffs (44 lines):
diff -r 9c4b65013355 -r 7351ae180858 sys/dev/pci/xmm7360.c
--- a/sys/dev/pci/xmm7360.c Mon Oct 18 07:11:31 2021 +0000
+++ b/sys/dev/pci/xmm7360.c Mon Oct 18 08:15:00 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: xmm7360.c,v 1.12 2021/10/11 05:13:10 knakahara Exp $ */
+/* $NetBSD: xmm7360.c,v 1.13 2021/10/18 08:15:00 hannken Exp $ */
/*
* Device driver for Intel XMM7360 LTE modems, eg. Fibocom L850-GL.
@@ -75,7 +75,7 @@
#include "opt_gateway.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: xmm7360.c,v 1.12 2021/10/11 05:13:10 knakahara Exp $");
+__KERNEL_RCSID(0, "$NetBSD: xmm7360.c,v 1.13 2021/10/18 08:15:00 hannken Exp $");
#endif
#include <sys/param.h>
@@ -294,6 +294,7 @@
tsleep(xmm, 0, "wwancsl", msec * hz / 1000); \
} while (0)
+static pktq_rps_hash_func_t xmm7360_pktq_rps_hash_p;
static void *dma_alloc_coherent(struct device *, size_t, dma_addr_t *, int);
static void dma_free_coherent(struct device *, size_t, volatile void *, dma_addr_t);
@@ -3110,7 +3111,7 @@
/* No errors. Receive the packet. */
m_set_rcvif(m, ifp);
- const uint32_t h = pktq_rps_hash(&pktq_rps_hash_default, m);
+ const uint32_t h = pktq_rps_hash(&xmm7360_pktq_rps_hash_p, m);
if (__predict_false(!pktq_enqueue(pktq, m, h))) {
m_freem(m);
}
@@ -3257,6 +3258,8 @@
printf("\n");
#ifdef __NetBSD__
+ xmm7360_pktq_rps_hash_p = pktq_rps_hash_default;
+
if (pmf_device_register(self, wwan_pmf_suspend, NULL))
pmf_class_network_register(self, ifp);
else
Home |
Main Index |
Thread Index |
Old Index