From patchwork Mon Jul 26 14:35:24 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 12399739 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 001C2C4338F for ; Mon, 26 Jul 2021 14:37:54 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id DD37B6069E for ; Mon, 26 Jul 2021 14:37:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234673AbhGZN5Z (ORCPT ); Mon, 26 Jul 2021 09:57:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59362 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233939AbhGZN5Y (ORCPT ); Mon, 26 Jul 2021 09:57:24 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3A0DEC061757; Mon, 26 Jul 2021 07:37:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=Content-Transfer-Encoding:MIME-Version: References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Type:Content-ID:Content-Description; bh=kjP8XL3gAAQmLIUQhlu9GWo9RK6RrkKJjMyFl/c4u5E=; b=oigzRQ4uCRljWEwC0f1Bbt6rtY k+rE676s5UiKLt1KJfMy+YjKS01RfM9Kd4BjiaEeFtz+HYd9WL7VEeLf9t7QErqUG+V5s3TP7OlJF HQQhZDGigigMhVSThuxVel5Rag8s9taG+on9Gzf53LaJIOC1aQi7RFq0e5msbi1uitWwhSOKsg+5p bdFVoeLuPM331GQ3ew/fq16bPd6evK5Abrx8xGwFbLa1Vqq1rXw27iu+KBTQbvmrZ7gaSZnhWWLcI gpb08EQSQiiTcjqtuRSRYm9KxwVCoxEDcLU1mdAQBRtp1QqC29tpIdNRjOGC6MGZVqKcBDnUXqbvi 6FlcVRgA==; Received: from [2001:4bb8:184:87c5:ee29:e765:f641:52d7] (helo=localhost) by casper.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1m81ib-00E2d9-6k; Mon, 26 Jul 2021 14:36:54 +0000 From: Christoph Hellwig To: Kirti Wankhede , Alex Williamson , Jason Gunthorpe Cc: Cornelia Huck , kvm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/2] vfio/mdev: don't warn if ->request is not set Date: Mon, 26 Jul 2021 16:35:24 +0200 Message-Id: <20210726143524.155779-3-hch@lst.de> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210726143524.155779-1-hch@lst.de> References: <20210726143524.155779-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by casper.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org Only a single driver actually sets the ->request method, so don't print a scary warning if it isn't. Signed-off-by: Christoph Hellwig Reviewed-by: Cornelia Huck Reviewed-by: Jason Gunthorpe --- drivers/vfio/mdev/mdev_core.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/drivers/vfio/mdev/mdev_core.c b/drivers/vfio/mdev/mdev_core.c index b16606ebafa1..b314101237fe 100644 --- a/drivers/vfio/mdev/mdev_core.c +++ b/drivers/vfio/mdev/mdev_core.c @@ -138,10 +138,6 @@ int mdev_register_device(struct device *dev, const struct mdev_parent_ops *ops) if (!dev) return -EINVAL; - /* Not mandatory, but its absence could be a problem */ - if (!ops->request) - dev_info(dev, "Driver cannot be asked to release device\n"); - mutex_lock(&parent_list_lock); /* Check for duplicate */