From patchwork Wed Jan 2 12:28:30 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jiri Pirko X-Patchwork-Id: 1923261 Return-Path: X-Original-To: patchwork-linux-rdma@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 4EBF63FE37 for ; Wed, 2 Jan 2013 12:30:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752090Ab3ABMa3 (ORCPT ); Wed, 2 Jan 2013 07:30:29 -0500 Received: from mail-ee0-f44.google.com ([74.125.83.44]:55874 "EHLO mail-ee0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752821Ab3ABM3P (ORCPT ); Wed, 2 Jan 2013 07:29:15 -0500 Received: by mail-ee0-f44.google.com with SMTP id b47so7027634eek.3 for ; Wed, 02 Jan 2013 04:29:13 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references:x-gm-message-state; bh=8Co8+RVucEuKlCrOQXINl56L0NBUArKKH8trt+noiQI=; b=kFRaAQDkBphB6s9Z5hXt57b/XqBYIt7oVqh49QQ00UsQ2rp4Fs9lISpwF5gHCsgvy8 LkGsAnyzbie2xITzepItpzZBi1mVnyBsTGTASAkLFWEBzuo7nTzyVs2sp8g6o0fjCDWX p64pfkKgN2bOW3IFbB47+QrEM2BmV40IPA9Pt2QYjm/G+pP1zsgNWSS4lfZb0TgWu4Wp 58bh0G2diCwiCldeict4AarMH8XeHdqYOahe0gE7CbHMuAgVl75hUN8H4LamwFB1z4NE ToWCRz8uJZp6LcQAQHwgKz5vvysHWvfEuFZPP77kEzodmIrDIheu5/LS9AN/mzHq/obN nhtQ== X-Received: by 10.14.204.198 with SMTP id h46mr125662691eeo.1.1357129753616; Wed, 02 Jan 2013 04:29:13 -0800 (PST) Received: from localhost (sun-0.pirko.cz. [84.16.102.25]) by mx.google.com with ESMTPS id w3sm97428803eel.17.2013.01.02.04.29.11 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 02 Jan 2013 04:29:12 -0800 (PST) From: Jiri Pirko To: netdev@vger.kernel.org Cc: davem@davemloft.net, edumazet@google.com, faisal.latif@intel.com, roland@kernel.org, sean.hefty@intel.com, hal.rosenstock@gmail.com, fubar@us.ibm.com, andy@greyhouse.net, divy@chelsio.com, jitendra.kalsaria@qlogic.com, sony.chacko@qlogic.com, linux-driver@qlogic.com, kaber@trash.net, ursula.braun@de.ibm.com, blaschka@linux.vnet.ibm.com, linux390@de.ibm.com, shemminger@vyatta.com, bhutchings@solarflare.com, therbert@google.com, xiyou.wangcong@gmail.com, joe@perches.com, gregory.v.rose@intel.com, john.r.fastabend@intel.com, linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org, linux-s390@vger.kernel.org, bridge@lists.linux-foundation.org, fbl@redhat.com Subject: [patch net-next V5 09/15] qlcnic: guard __vlan_find_dev_deep() by rcu_read_lock Date: Wed, 2 Jan 2013 13:28:30 +0100 Message-Id: <1357129716-2450-10-git-send-email-jiri@resnulli.us> X-Mailer: git-send-email 1.8.0 In-Reply-To: <1357129716-2450-1-git-send-email-jiri@resnulli.us> References: <1357129716-2450-1-git-send-email-jiri@resnulli.us> X-Gm-Message-State: ALoCoQlw/VuvKEPTOdW+Bhvstk2xqPuORwDeBo9VVjnyP6xRHr8ouT3/sj984mwbokHqJIbS4xrK Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org rcu_read_lock was missing here Signed-off-by: Jiri Pirko Acked-by: Sony Chacko --- drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c index e1a3625..d4170a0 100644 --- a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c +++ b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c @@ -3204,12 +3204,14 @@ void qlcnic_restore_indev_addr(struct net_device *netdev, unsigned long event) qlcnic_config_indev_addr(adapter, netdev, event); + rcu_read_lock(); for_each_set_bit(vid, adapter->vlans, VLAN_N_VID) { dev = __vlan_find_dev_deep(netdev, vid); if (!dev) continue; qlcnic_config_indev_addr(adapter, dev, event); } + rcu_read_unlock(); } static int qlcnic_netdev_event(struct notifier_block *this,