From owner-svn-src-head@freebsd.org Tue May 8 23:31:36 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2190FFCD841; Tue, 8 May 2018 23:31:36 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "smtp.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id C4BD570017; Tue, 8 May 2018 23:31:35 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: from mail-io0-f173.google.com (mail-io0-f173.google.com [209.85.223.173]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) (Authenticated sender: mmacy) by smtp.freebsd.org (Postfix) with ESMTPSA id 8C7C5249CD; Tue, 8 May 2018 23:31:35 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: by mail-io0-f173.google.com with SMTP id p124-v6so40585358iod.1; Tue, 08 May 2018 16:31:35 -0700 (PDT) X-Gm-Message-State: ALQs6tAisK9h2pnYxvCnNkcxKhx5N22sPv0fRtnPA4NfvBUb0cQaHFpm HjCAfOMP8nNxI1SAN2cVPms8ge0HWWLq+HWR42s= X-Google-Smtp-Source: AB8JxZrrq9T/m0FJIhfrdVplz/3KxOHq/kzY2pKBAQqjYdqIIu6cAyba9hz6Z1y0LdSQyc4Uj953tl3RYemhPE4/jAk= X-Received: by 2002:a6b:b7c6:: with SMTP id h189-v6mr44650112iof.94.1525822294986; Tue, 08 May 2018 16:31:34 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a02:b0c3:0:0:0:0:0 with HTTP; Tue, 8 May 2018 16:31:34 -0700 (PDT) In-Reply-To: <20180508221025.GA4249@raichu> References: <201805080139.w481djMX062724@repo.freebsd.org> <20180508221025.GA4249@raichu> From: Matthew Macy Date: Tue, 8 May 2018 16:31:34 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: svn commit: r333345 - head/sys/dev/e1000 To: Mark Johnston Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org, Stephen Hurd Content-Type: multipart/mixed; boundary="000000000000e2381a056bba2f42" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 May 2018 23:31:36 -0000 --000000000000e2381a056bba2f42 Content-Type: text/plain; charset="UTF-8" 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 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 --000000000000e2381a056bba2f42 Content-Type: text/x-patch; charset="US-ASCII"; name="e1000_hack.diff" Content-Disposition: attachment; filename="e1000_hack.diff" Content-Transfer-Encoding: base64 X-Attachment-Id: f_jgyb6gb20 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