Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 7 Apr 2008 12:59:54 -0700
From:      "Jack Vogel" <jfvogel@gmail.com>
To:        "Takanori Watanabe" <takawata@init-main.com>
Cc:        jfv@freebsd.org, freebsd-acpi@freebsd.org
Subject:   Re: if_em locking issue in resume path.
Message-ID:  <2a41acea0804071259g28f2e2a7tc687a97e3c9d3988@mail.gmail.com>
In-Reply-To: <200804071841.m37IfukE027475@sana.init-main.com>
References:  <200804071841.m37IfukE027475@sana.init-main.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Yes, thanks for noticing this, however rather than fix it as your patch I
think I prefer just doing the CORE work, and then calling em_start(),
it checks for the interface being up and gets the TX LOCK.

I'll make the change as soon as I can.

Jack


On Mon, Apr 7, 2008 at 11:41 AM, Takanori Watanabe
<takawata@init-main.com> wrote:
> This patch resolve a problem which will cause lock assertion
>  in resume path. Comment?
>
>
>  --- if_em.c.~1.190.~    2008-02-29 21:50:10.000000000 +0000
>  +++ if_em.c     2008-04-08 03:04:05.000000000 +0000
>  @@ -915,12 +915,13 @@
>         EM_CORE_LOCK(adapter);
>         em_init_locked(adapter);
>         em_init_manageability(adapter);
>  +       EM_CORE_UNLOCK(adapter);
>
>  +       EM_TX_LOCK(adapter);
>         if ((ifp->if_flags & IFF_UP) &&
>             (ifp->if_drv_flags & IFF_DRV_RUNNING))
>                 em_start_locked(ifp);
>  -
>  -       EM_CORE_UNLOCK(adapter);
>  +       EM_TX_UNLOCK(adapter);
>
>         return bus_generic_resume(dev);
>   }
>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?2a41acea0804071259g28f2e2a7tc687a97e3c9d3988>