From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752127AbaAOBSh (ORCPT ); Tue, 14 Jan 2014 20:18:37 -0500 Received: from mail1.windriver.com ([147.11.146.13]:41788 "EHLO mail1.windriver.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750918AbaAOBSe (ORCPT ); Tue, 14 Jan 2014 20:18:34 -0500 Message-ID: <52D5E1CD.2020405@windriver.com> Date: Wed, 15 Jan 2014 09:18:05 +0800 From: Ying Xue User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: Johannes Berg CC: , , , , , , , , Subject: Re: [PATCH net-next 10/10] net: nl80211: __dev_get_by_index instead of dev_get_by_index to find interface References: <1389685269-18600-1-git-send-email-ying.xue@windriver.com> <1389685269-18600-11-git-send-email-ying.xue@windriver.com> <1389701498.23430.1.camel@jlt4.sipsolutions.net> In-Reply-To: <1389701498.23430.1.camel@jlt4.sipsolutions.net> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [128.224.162.185] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 01/14/2014 08:11 PM, Johannes Berg wrote: > On Tue, 2014-01-14 at 15:41 +0800, Ying Xue wrote: > >> @@ -2218,10 +2194,6 @@ static int nl80211_set_wiphy(struct sk_buff *skb, struct genl_info *info) >> rdev->wiphy.coverage_class = old_coverage_class; >> } >> } >> - >> - bad_res: >> - if (netdev) >> - dev_put(netdev); >> return result; > > I believe that could be "return 0;" now, which would make the code > easier to read. > Yes, I will change it in next version. Thanks, Ying > johannes > > >