lkml.org 
[lkml]   [2012]   [Apr]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 2/2] ixgbe: add missing rtnl_lock in PM resume path
    Date
    Upon resume from standby, ixgbe may trigger the ASSERT_RTNL() in
    netif_set_real_num_tx_queues(). The call stack is:
    netif_set_real_num_tx_queues
    ixgbe_set_num_queues
    ixgbe_init_interrupt_scheme
    ixgbe_resume

    Signed-off-by: Benjamin Poirier <bpoirier@suse.de>

    ---
    Unlike patch 1 for igb, we cannot lock rtnl closer to the point where
    netif_set_real_num_tx_queues() is called because ixgbe_init_interrupt_scheme()
    is also called by the dcb code, already under rtnl.
    ---
    drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 ++
    1 files changed, 2 insertions(+), 0 deletions(-)

    diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
    index 3e26b1f..ff6edab 100644
    --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
    +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
    @@ -4836,7 +4836,9 @@ static int ixgbe_resume(struct pci_dev *pdev)

    pci_wake_from_d3(pdev, false);

    + rtnl_lock();
    err = ixgbe_init_interrupt_scheme(adapter);
    + rtnl_unlock();
    if (err) {
    e_dev_err("Cannot initialize interrupts for device\n");
    return err;
    --
    1.7.7


    \
     
     \ /
      Last update: 2012-04-05 17:13    [W:0.020 / U:0.924 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site