From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752152AbcC0NdB (ORCPT ); Sun, 27 Mar 2016 09:33:01 -0400 Received: from mail-io0-f175.google.com ([209.85.223.175]:33046 "EHLO mail-io0-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751408AbcC0Nc6 (ORCPT ); Sun, 27 Mar 2016 09:32:58 -0400 Date: Sun, 27 Mar 2016 21:32:08 +0800 From: Boqun Feng To: Linus Torvalds Cc: Sedat Dilek , Ingo Molnar , Peter Zijlstra , "Theodore Ts'o" , linux-fsdevel , LKML , Alfredo Alvarez Fernandez Subject: Re: [Linux-v4.6-rc1] ext4: WARNING: CPU: 2 PID: 2692 at kernel/locking/lockdep.c:2017 __lock_acquire+0x180e/0x2260 Message-ID: <20160327133208.GA14802@fixme-laptop.cn.ibm.com> References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="+QahgC5+KEYLbs62" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --+QahgC5+KEYLbs62 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Mar 27, 2016 at 05:03:44AM -0700, Linus Torvalds wrote: > On Sun, Mar 27, 2016 at 1:57 AM, Sedat Dilek wrot= e: > > > > I pulled ext4.git#dev on top of Linux v4.6-rc1... > > > > ... and did not see the call-trace. >=20 > Unless you're using overlayfs or per-file encryption, I'm not seeing > that any of that should make any difference (but it's entirely > possible I'm missing something). >=20 > Was it entirely repeatable before? Maybe it just happened to happen > without that update, and then happened to _not_ happen after you > rebooted with that 'dev' branch pulled in? >=20 > Anyway, I don't think that DEBUG_LOCKS_WARN_ON() in >=20 > kernel/locking/lockdep.c:2017 __lock_acquire >=20 The code here is in check_no_collision(), so IIUC, there was a warning because a real chain_key collision happened. And chain_key is a hashsum of the ->class_idx of held_lock, calculated via iterate_chain_key(), and the ->class_idx of a held_lock may change =66rom run to run IIUC, depending on the time register_lock_class() is called for the corresponding lock class. So this might be why Sedat didn't see the call-trace again. Of course, I may miss something subtle here, so add the author of check_no_collision() in CCs ;-) If I'm right, maybe we can provide more informative dmesg here rather than calling DEBUG_LOCKS_WARN_ON() directly? Regards, Boqun > would be an ext4 issue, it looks more like an internal lockdep issue. >=20 > Adding in the lockdep people, who will set me right. >=20 > Linus --+QahgC5+KEYLbs62 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAABCAAGBQJW9+DMAAoJEEl56MO1B/q4KtgIAIBDIqR9llUpLdWf30RbB7D+ 4zM4uMH9Sf2oeQ7oEJXoCG5bocVQVajxK6kf9rdYExrzYYXh20195+7RwyGdMDWd HalgedVSTCXavOrQB5KGSwFvNeBqSFsDgaIiWtGzCdIHriuL94MfqPrryaohtTAv US0UegdBUr++495WJuMGjJ2nLcOlCCGwctwBCh08nVXmzsxgZRFxrBW9fhAoSfGD q4T8yVTHbe5XsU55cR/LMVaTYRi4ln9DwNTX+AqfcSAP7mCcOfPQd4CjOZk5YZFo 3CwKxXQuFToOe8Yi4JGtfL1bmrbRsAfUOpxMkWZpWdFa3hpj2uEzdWeYSBUed3A= =JVJp -----END PGP SIGNATURE----- --+QahgC5+KEYLbs62--