Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp2167062imm; Tue, 2 Oct 2018 22:44:11 -0700 (PDT) X-Google-Smtp-Source: ACcGV61/Ys9HsDQjl1/FnYRgSemxJnAy4SMca2dW3VSm6a5XIsFGCVlhonWKBpg3qwlvl6RSP1DA X-Received: by 2002:a17:902:6b03:: with SMTP id o3-v6mr20093191plk.333.1538545451522; Tue, 02 Oct 2018 22:44:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538545451; cv=none; d=google.com; s=arc-20160816; b=pTDYyyg1fVEg2hWD3oXBv+7GjtAMrMBahK7urmzAY8InkNbHYpuaCQlGxBKtFc+Gty CJojU4i1f3+Y8qV3PTbIksIVdmewEeXgCd3CjzeHy3gsXzIRHLKt5l6L4fEXXCDQwYB8 FBzc6Yalju8HgspwY47DAi86+uEk4Tyc+SEzZPG/LmlsHE/o+2/x9KuGXM8kIMdVbNIJ H1t+mA/PaLzadbv9PWQHtetf8xCzKx+ZZbZTx46hRAiix6Sr49+gW6dwfOEM3TWDIE5v 3Ivuymtg8PAo0G0dwjRCa12jeRjK5OFu44OLK01/Hoa2l6lT703NcN7hLxUcKDw0JRj7 Zt7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :reply-to:references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=zSFnQe3osAhSI/yCScn4VpMhcXnR9g7aaMBXVQdp4bM=; b=AhwNQT9M1/QdbVJIe+Vjnz01m8JZrEo1G6kRW3AtegpnZ88rI8p1QRm+fu1sgZTufd kz+hL6R2KnlpP3ltZaYCAHaJ5EPJU2Z3i1jeBoS7RsV3YFEzRi9P3b44fUHZoWotFF7O 8hgj41SfpL1UF41X9Q1/3eXuCUhpGKKsEURx8yEW7++oFHOjKc1sz1VDAgFYfWWYgr2k wB70HI7nUoe6lCBG7AHHKVfSi01PYNQN1rT7s6A7YXCL2arpE8uAh07lz5qXijsT+hF/ v7RQOrg1AxJg7PX3lhKyARKAvm1kULcIf9hXaCwurR3ZPDItuo7JqK+LKib7VQ0J1pkc tDWw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=l1b0JEs6; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c6-v6si390692plr.91.2018.10.02.22.43.56; Tue, 02 Oct 2018 22:44:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=l1b0JEs6; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726801AbeJCM0d (ORCPT + 99 others); Wed, 3 Oct 2018 08:26:33 -0400 Received: from mail-pl1-f193.google.com ([209.85.214.193]:39421 "EHLO mail-pl1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726547AbeJCM0d (ORCPT ); Wed, 3 Oct 2018 08:26:33 -0400 Received: by mail-pl1-f193.google.com with SMTP id w14-v6so2872861plp.6; Tue, 02 Oct 2018 22:39:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references:reply-to :mime-version:content-transfer-encoding; bh=zSFnQe3osAhSI/yCScn4VpMhcXnR9g7aaMBXVQdp4bM=; b=l1b0JEs6srj1RsDS4bSQIh1ayBpuE69qoqcMVgviT9a4CBdFGILy3EORYCtDV1ZXpA ddYC5odsDxiIOhOOLB+oMkGKHr0+SVihpETc7BiNVNUYjbUBiWpvkaJ3lZdpCSj9Crzz qDXOWViaMcNE/i9s8a+VZXYqFFy5T9dXw7MYEh5ap3c+/sDLRAVQ0nM1EZFRFmn7L5EU xVKfmpyCA3uWR+uBURbM2K7iUjt906h8c25rWY/Muw0auUCyTh/Oo26ECsa53qvRs08D eFuITRp4S6G6o4MYjQ2f76R+ZYsbqZLx0TOFcK+58JAPynQKtDPSNdbk3epO3WDUa40M Ezjg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:reply-to:mime-version:content-transfer-encoding; bh=zSFnQe3osAhSI/yCScn4VpMhcXnR9g7aaMBXVQdp4bM=; b=BcTgZdce5hQ6p/Lol2ZuQEq5LGqS36JwjhOFveFurdy+th0SHSjTglZ5lnygcTDDNA QP9HqX/uUQsrWvXkZ2VdRZMyA/yK/YlBOOIzVn6ykMgY3RVtzaJFdR3rkOc4p9IKWjMB TPgu760ETMXOYs+gfWko2fzON9WlRU0Udg1/usHinZPJZNr3/MZvTQwWVA1OSx8KZfST M5LH8sR1GGnvIW0/WW57YOU235sWSZ8zLBYVaE67AV5aLqSEcg2lDnvfksZ6ABe9NqMG UZet8VyinU0TlspyXphFAmXAgNaBL/94BkZJYFS6hP8Gw2oBDrx990K/d7kN8ppcytS2 0BZw== X-Gm-Message-State: ABuFfoj5OfAA6FYw5SgWu5kXOpbeV6N9Vb/I3ktyeY7F1s7s+QlPlflp bLzQW2JxQwQQfFdkjRuFR7+flQDEYac= X-Received: by 2002:a17:902:6689:: with SMTP id e9-v6mr19898972plk.115.1538545183362; Tue, 02 Oct 2018 22:39:43 -0700 (PDT) Received: from E570.localdomain (c-24-21-68-121.hsd1.or.comcast.net. [24.21.68.121]) by smtp.gmail.com with ESMTPSA id h4-v6sm570978pfe.49.2018.10.02.22.39.42 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 02 Oct 2018 22:39:42 -0700 (PDT) Received: by E570.localdomain (Postfix, from userid 1000) id C82EA1643D0; Tue, 2 Oct 2018 22:39:41 -0700 (PDT) From: Lance Roy To: linux-kernel@vger.kernel.org Cc: "Paul E. McKenney" , Lance Roy , Bjorn Helgaas , Thomas Gleixner , Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , x86@kernel.org, linux-pci@vger.kernel.org Subject: [PATCH 01/16] x86/PCI: Replace spin_is_locked() with lockdep Date: Tue, 2 Oct 2018 22:38:47 -0700 Message-Id: <20181003053902.6910-2-ldr709@gmail.com> X-Mailer: git-send-email 2.19.0 In-Reply-To: <20181003053902.6910-1-ldr709@gmail.com> References: <20181003053902.6910-1-ldr709@gmail.com> Reply-To: Lance Roy MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org lockdep_assert_held() is better suited to checking locking requirements, since it won't get confused when someone else holds the lock. This is also a step towards possibly removing spin_is_locked(). Signed-off-by: Lance Roy Cc: Bjorn Helgaas Cc: Thomas Gleixner Cc: Ingo Molnar Cc: Borislav Petkov Cc: "H. Peter Anvin" Cc: Cc: --- arch/x86/pci/i386.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/pci/i386.c b/arch/x86/pci/i386.c index ed4ac215305d..24bb58a007de 100644 --- a/arch/x86/pci/i386.c +++ b/arch/x86/pci/i386.c @@ -59,7 +59,7 @@ static struct pcibios_fwaddrmap *pcibios_fwaddrmap_lookup(struct pci_dev *dev) { struct pcibios_fwaddrmap *map; - WARN_ON_SMP(!spin_is_locked(&pcibios_fwaddrmap_lock)); + lockdep_assert_held(&pcibios_fwaddrmap_lock); list_for_each_entry(map, &pcibios_fwaddrmappings, list) if (map->dev == dev) -- 2.19.0