git: 1c8493924bf9 - main - net/intel-em-kmod: Remove unused DRIVER_MODULE devclass on recent main.

From: John Baldwin <jhb_at_FreeBSD.org>
Date: Thu, 23 Jun 2022 21:33:55 UTC
The branch main has been updated by jhb (doc, src committer):

URL: https://cgit.FreeBSD.org/ports/commit/?id=1c8493924bf9039963e987ffbeaebc7a3686f71d

commit 1c8493924bf9039963e987ffbeaebc7a3686f71d
Author:     John Baldwin <jhb@FreeBSD.org>
AuthorDate: 2022-06-23 21:32:38 +0000
Commit:     John Baldwin <jhb@FreeBSD.org>
CommitDate: 2022-06-23 21:32:38 +0000

    net/intel-em-kmod: Remove unused DRIVER_MODULE devclass on recent main.
    
    Reviewed by:    imp
    Differential Revision:  https://reviews.freebsd.org/D35205
---
 net/intel-em-kmod/files/patch-devclass | 30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)

diff --git a/net/intel-em-kmod/files/patch-devclass b/net/intel-em-kmod/files/patch-devclass
new file mode 100644
index 000000000000..27533cd7825a
--- /dev/null
+++ b/net/intel-em-kmod/files/patch-devclass
@@ -0,0 +1,30 @@
+--- if_em.c.orig	2022-05-13 15:26:41.055245000 -0700
++++ if_em.c	2022-05-13 15:27:11.443359000 -0700
+@@ -379,8 +379,12 @@ static driver_t em_driver = {
+ 	"em", em_methods, sizeof(struct adapter),
+ };
+ 
++#if __FreeBSD_version >= 1400058
++DRIVER_MODULE(em, pci, em_driver, 0, 0);
++#else
+ devclass_t em_devclass;
+ DRIVER_MODULE(em, pci, em_driver, em_devclass, 0, 0);
++#endif
+ MODULE_DEPEND(em, pci, 1, 1, 1);
+ MODULE_DEPEND(em, ether, 1, 1, 1);
+ 
+--- if_lem.c.orig	2022-05-13 15:26:44.154782000 -0700
++++ if_lem.c	2022-05-13 15:27:38.402591000 -0700
+@@ -289,8 +289,12 @@ static driver_t lem_driver = {
+ 	"em", lem_methods, sizeof(struct adapter),
+ };
+ 
++#if __FreeBSD_version >= 1400058
++DRIVER_MODULE(lem, pci, lem_driver, 0, 0);
++#else
+ extern devclass_t em_devclass;
+ DRIVER_MODULE(lem, pci, lem_driver, em_devclass, 0, 0);
++#endif
+ MODULE_DEPEND(lem, pci, 1, 1, 1);
+ MODULE_DEPEND(lem, ether, 1, 1, 1);
+