Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp6335857pxb; Mon, 8 Nov 2021 07:01:54 -0800 (PST) X-Google-Smtp-Source: ABdhPJx+cBApRiFWACg7egXFKLcfhIFlwACuMQfOiacjTBycMEatDQDWsA3JJEnT3pqkMWyqAYN1 X-Received: by 2002:a92:3642:: with SMTP id d2mr396103ilf.234.1636383713834; Mon, 08 Nov 2021 07:01:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1636383713; cv=none; d=google.com; s=arc-20160816; b=N9H1SCSAcDMv8n20HjHEAGB3KU8Khg1bx0mg5iERr24+H0TR3fMnjVtAZybNmPm+iW 5yNE1DVNbTNY1VAkezT/m6NkR96Dr3GyZZGaQrlGCkzklbi9cRZIao72H5K1VZ9aWexq 5LOW+baWLx2DXwbMmFvou7ZQxpnWfN4fNGtzsjjHhh5JaU0R8988PBJbzJh3Obiaw8UR D6Dq/VhQxjcSOlvnYrCHgsKLHRMt1ribzHLFcOKAQZHLgoe1qX35AUBV8XlMcZn/KuFN jJckIpX0+hrrw2xIIuA5gKtbaueVXyPzzxZU5qkpockzPkhzTd6DiUnJj6ggLW7TWjgQ ctsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=1iair6BWPYTb3fn2g/N3YxlgrdOuwpEEIcBJ21kHgLU=; b=goHOUmRVh86RzL0vy53TenfOiFclPD62wyJEf+Nolge4SH8X+FKamatjQGft2n+iiV rtlrs4Hirg4hXgmQTP0BFgcmrG2WblDNYNwqZaQchBIvj3SshtnaGnIlrrmZoBcNHHo+ SHGnEqOJBAhrAYG9iB4doFQCBPliwNlJBqhZ3/xHIKQT/TI38eHybpj4tpSJ7iQPcAZt 3MDnMcZjDqhB92Mh0nCBuFlgqcVy0GIGR6nSX1YgzUticRKSXC0ft444cvbowOIybc9y 185Lx2cu++v4mGjKEffvn/u1jYPhuoPbqV9uWNp/8TPXSLSzJRI6rlimMKZkUZkWkZRV XdjA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=YmYK5pWT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d20si34194468jak.99.2021.11.08.07.01.39; Mon, 08 Nov 2021 07:01:53 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=YmYK5pWT; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238597AbhKHKQA (ORCPT + 99 others); Mon, 8 Nov 2021 05:16:00 -0500 Received: from mail.skyhub.de ([5.9.137.197]:38254 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237746AbhKHKO7 (ORCPT ); Mon, 8 Nov 2021 05:14:59 -0500 Received: from zn.tnic (p200300ec2f33110088892b77bd117736.dip0.t-ipconnect.de [IPv6:2003:ec:2f33:1100:8889:2b77:bd11:7736]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 8DF0C1EC04DF; Mon, 8 Nov 2021 11:12:14 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1636366334; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=1iair6BWPYTb3fn2g/N3YxlgrdOuwpEEIcBJ21kHgLU=; b=YmYK5pWTuxMInILmWGuCaPPl5eN7NW8dSeDuDBpplcWi/gm6eS8Yba7OjFJkqwQSkGh3pr uzMQSNbwlKauDhee2yXt551kKgZq6L1lcrWQVUPNShKdhMusvu2up8w4nCrfMk9rFZ03Vk a/H86JSpIpv6ji/a8yN4Qve69hx4AiM= From: Borislav Petkov To: LKML Cc: linux-hyperv@vger.kernel.org Subject: [PATCH v0 08/42] Drivers: hv: vmbus: Check notifier registration return value Date: Mon, 8 Nov 2021 11:11:23 +0100 Message-Id: <20211108101157.15189-9-bp@alien8.de> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20211108101157.15189-1-bp@alien8.de> References: <20211108101157.15189-1-bp@alien8.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Borislav Petkov Avoid homegrown notifier registration checks. No functional changes. Signed-off-by: Borislav Petkov Cc: linux-hyperv@vger.kernel.org --- drivers/hv/vmbus_drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/hv/vmbus_drv.c b/drivers/hv/vmbus_drv.c index 392c1ac4f819..370afd108d2d 100644 --- a/drivers/hv/vmbus_drv.c +++ b/drivers/hv/vmbus_drv.c @@ -1574,8 +1574,8 @@ static int vmbus_bus_init(void) * the VMbus channel connection to prevent any VMbus * activity after the VM panics. */ - atomic_notifier_chain_register(&panic_notifier_list, - &hyperv_panic_block); + if (atomic_notifier_chain_register(&panic_notifier_list, &hyperv_panic_block)) + pr_warn("VMBus panic notifier already registered\n"); vmbus_request_offers(); -- 2.29.2