Can you please try the attached patch? (Note that gmail may insert carriage returns)
-M On Tue, May 8, 2018 at 3:10 PM, Mark Johnston <ma...@freebsd.org> wrote: > On Tue, May 08, 2018 at 01:39:45AM +0000, Matt Macy wrote: >> Author: mmacy >> Date: Tue May 8 01:39:45 2018 >> New Revision: 333345 >> URL: https://svnweb.freebsd.org/changeset/base/333345 >> >> Log: >> Sleep rather than spin in e1000 when doing long running config operations. >> >> With r333218 it is now possible for drivers to use an sx lock and thus >> sleep while >> waiting on long running operations rather than DELAY(). >> >> Reported by: gallatin >> Reviewed by: sbruno >> Approved by: sbruno >> MFC after: 1 month >> Sponsored by: Limelight Networks >> Differential Revision: https://reviews.freebsd.org/D14984 > > I'm getting a panic during boot with this change: "unknown mac type d". > > It occurs while the driver is attaching to: > > em0@pci0:1:0:0: class=0x020000 card=0x7044103c chip=0x105e8086 rev=0x06 > hdr=0x00 > vendor = 'Intel Corporation' > device = '82571EB Gigabit Ethernet Controller' > class = network > subclass = ethernet
diff --git a/sys/dev/e1000/e1000_mac.c b/sys/dev/e1000/e1000_mac.c index da7934f9fb6..79283cf3296 100644 --- a/sys/dev/e1000/e1000_mac.c +++ b/sys/dev/e1000/e1000_mac.c @@ -2196,7 +2196,6 @@ s32 e1000_get_hw_semaphore(struct e1000_hw *hw) s32 i = 0; DEBUGFUNC("e1000_get_hw_semaphore"); -#ifdef notyet /* _82571 */ /* If we have timedout 3 times on trying to acquire * the inter-port SMBI semaphore, there is old code @@ -2208,7 +2207,6 @@ s32 e1000_get_hw_semaphore(struct e1000_hw *hw) if (hw->dev_spec._82571.smb_counter > 2) sw_timeout = 1; -#endif /* Get the SW semaphore */ while (i < timeout) { swsm = E1000_READ_REG(hw, E1000_SWSM); @@ -2220,7 +2218,7 @@ s32 e1000_get_hw_semaphore(struct e1000_hw *hw) } if (i == timeout) { -#ifdef notyet + /* * XXX This sounds more like a driver bug whereby we either * recursed accidentally or missed clearing it previously @@ -2239,7 +2237,6 @@ s32 e1000_get_hw_semaphore(struct e1000_hw *hw) usec_delay(50); } } -#endif DEBUGOUT("Driver can't access device - SMBI bit is set.\n"); return -E1000_ERR_NVM;
_______________________________________________ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"