Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752758AbdI0Mex (ORCPT ); Wed, 27 Sep 2017 08:34:53 -0400 Received: from Chamillionaire.breakpoint.cc ([146.0.238.67]:36204 "EHLO Chamillionaire.breakpoint.cc" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752160AbdI0Mew (ORCPT ); Wed, 27 Sep 2017 08:34:52 -0400 Date: Wed, 27 Sep 2017 14:31:03 +0200 From: Florian Westphal To: Artem Savkov Cc: Florian Westphal , Steffen Klassert , Herbert Xu , "David S . Miller" , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] xfrm: don't call xfrm_policy_cache_flush under xfrm_state_lock Message-ID: <20170927123103.GB14971@breakpoint.cc> References: <20170927122537.14235-1-asavkov@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170927122537.14235-1-asavkov@redhat.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 499 Lines: 12 Artem Savkov wrote: > I might be wrong but it doesn't look like xfrm_state_lock is required > for xfrm_policy_cache_flush and calling it under this lock triggers both > "sleeping function called from invalid context" and "possible circular > locking dependency detected" warnings on flush. > > Fixes: ec30d78c14a8 xfrm: add xdst pcpu cache > Signed-off-by: Artem Savkov You're right, its not needed (and wrong). Acked-by: Florian Westphal