Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754953AbbHGGxB (ORCPT ); Fri, 7 Aug 2015 02:53:01 -0400 Received: from shards.monkeyblade.net ([149.20.54.216]:46020 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752796AbbHGGxA (ORCPT ); Fri, 7 Aug 2015 02:53:00 -0400 Date: Thu, 06 Aug 2015 23:52:59 -0700 (PDT) Message-Id: <20150806.235259.2089819677267479973.davem@davemloft.net> To: oleg@redhat.com Cc: ying.huang@intel.com, ast@plumgrid.com, jstancek@redhat.com, brouer@redhat.com, mleitner@redhat.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] net: pktgen: don't abuse current->state in pktgen_thread_worker() From: David Miller In-Reply-To: <20150804163334.GA31842@redhat.com> References: <20150804163334.GA31842@redhat.com> X-Mailer: Mew version 6.6 on Emacs 24.5 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Thu, 06 Aug 2015 23:52:59 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 995 Lines: 23 From: Oleg Nesterov Date: Tue, 4 Aug 2015 18:33:34 +0200 > Commit 1fbe4b46caca "net: pktgen: kill the Wait for kthread_stop > code in pktgen_thread_worker()" removed (in particular) the final > __set_current_state(TASK_RUNNING) and I didn't notice the previous > set_current_state(TASK_INTERRUPTIBLE). This triggers the warning > in __might_sleep() after return. > > Afaics, we can simply remove both set_current_state()'s, and we > could do this a long ago right after ef87979c273a2 "pktgen: better > scheduler friendliness" which changed pktgen_thread_worker() to > use wait_event_interruptible_timeout(). > > Reported-by: Huang Ying > Signed-off-by: Oleg Nesterov Applied, thank you. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/