Received: by 2002:a05:6358:5282:b0:b5:90e7:25cb with SMTP id g2csp2144184rwa; Mon, 22 Aug 2022 02:59:39 -0700 (PDT) X-Google-Smtp-Source: AA6agR520GNvvZKaDCMXw5/AnKRrZXXVtos0Mj+7j1247+VdDduiK5jNmjZCOS2K8UIYJBliBLB0 X-Received: by 2002:a05:6402:b90:b0:446:6871:7bfa with SMTP id cf16-20020a0564020b9000b0044668717bfamr8929629edb.143.1661162376513; Mon, 22 Aug 2022 02:59:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661162376; cv=none; d=google.com; s=arc-20160816; b=iK9E+vNW8MHn3aecLSZHgULAMFNXd5Hu+QkaoD1zRxnym88VLFmSJKYoi4Uab5RVeE NqDYxadT4nxXKvGRWRtConl3XCq8fqp9Wtv1iOGdvL9lQQyN1TMV88SYUO4Qc3ZjeeZg +OuGChPxNJZOCqEpNDxwWej5W8/VSDUbiYcmsgETpxtG1BQfCihKqCg0FT/79Ii2iDf0 h1HFP7iB0q0uIiT1Hfd6rHEPzN1GOlElEO/R4K7PRtyYItJwXHkE2IakXo9rYauc34Qs 3BrSZ2FDVn7u6SDZ9jv/+zdj3KFCyYiid8fxH4JQoCaKWJNKBHTpSSQgusehHYOf+fny K4rw== 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 :message-id:date:user-agent:references:organization:in-reply-to :subject:cc:to:from:dkim-signature; bh=D8PX8VGV+zxa485SufkBq+IWwGWuDtC3c/GfFCmctrA=; b=rcQWLqUagarOlHSqWGnlNBKl0ltXgezHidQfyw13QR1KdU2wQl1vVyJ+beSyaQmplB Rt/pM86eXT3r2Zd3NtDwdizJP4YPMxjY073mJtmUrVxJxZhb+VShcmdzU+Gw9X/qrCt7 XNpyznlFzSBBIXhCYpAGJfvHeNd7hCk7ZCDhtPHeKvwIPLeVEcUQ7B3gBS/gWbdBrmu9 FRZgIl45mamImtJwCVxWUf8WGLJ4qu6aF8qufl5GTbhnMTFh1TasiiKUgbN9iKrU8FBO v28kQU4R13gp6hTKmQcGetOWXnSMFz5KEw7HBRNdQZ+MdSEYitzD59ROCt01j9tdTYQH W6qA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=TwEiBYTC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g9-20020a1709065d0900b0070f153ebd89si11019208ejt.7.2022.08.22.02.59.11; Mon, 22 Aug 2022 02:59:36 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=TwEiBYTC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230190AbiHVJQL (ORCPT + 99 others); Mon, 22 Aug 2022 05:16:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59002 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234452AbiHVJPf (ORCPT ); Mon, 22 Aug 2022 05:15:35 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9BEE727B0A for ; Mon, 22 Aug 2022 02:14:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1661159691; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=D8PX8VGV+zxa485SufkBq+IWwGWuDtC3c/GfFCmctrA=; b=TwEiBYTC/Q+1fGB7kM6sj1SNC1l90ZpCPZq0dr6uxVwZ/PcDqCXNiZm66XV5WXf2Ovss5w ekUDMTaHEh3ku+NuABnlkn/8lmZsfJ49hFE68kOTBsiBlFvuYI1Rv9gCyllSNcw3jztfls zPpb4hbJQAbvJsvQ7AphzMIJg4T/TP8= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-361-IKkzy2GiPiOmwXPFZyABEQ-1; Mon, 22 Aug 2022 05:14:40 -0400 X-MC-Unique: IKkzy2GiPiOmwXPFZyABEQ-1 Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 56D341C13941; Mon, 22 Aug 2022 09:14:40 +0000 (UTC) Received: from localhost (unknown [10.39.193.142]) by smtp.corp.redhat.com (Postfix) with ESMTPS id DCF19492C3B; Mon, 22 Aug 2022 09:14:39 +0000 (UTC) From: Cornelia Huck To: Jason Gunthorpe , Christophe JAILLET Cc: Diana Craciun , Alex Williamson , linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org, kvm@vger.kernel.org Subject: Re: [PATCH] vfio/fsl-mc: Fix a typo in a comment In-Reply-To: Organization: Red Hat GmbH References: <2b65bf8d2b4d940cafbafcede07c23c35f042f5a.1659815764.git.christophe.jaillet@wanadoo.fr> User-Agent: Notmuch/0.36 (https://notmuchmail.org) Date: Mon, 22 Aug 2022 11:14:38 +0200 Message-ID: <871qt8prlt.fsf@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Scanned-By: MIMEDefang 2.85 on 10.11.54.9 X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Aug 16 2022, Jason Gunthorpe wrote: > On Tue, Aug 16, 2022 at 05:00:50PM +0200, Christophe JAILLET wrote: >> Le 09/08/2022 =C3=A0 18:20, Jason Gunthorpe a =C3=A9crit=C2=A0: >> > On Sat, Aug 06, 2022 at 09:56:13PM +0200, Christophe JAILLET wrote: >> > > L and S are swapped/ >> > > s/VFIO_FLS_MC/VFIO_FSL_MC/ >> > >=20 >> > > Signed-off-by: Christophe JAILLET >> > > --- >> > > All the dev_ logging functions in the file have the "VFIO_FSL_MC: " >> > > prefix. >> > > As they are dev_ function, the driver should already be displayed. >> > >=20 >> > > So, does it make sense or could they be all removed? >> > > --- >> > > drivers/vfio/fsl-mc/vfio_fsl_mc.c | 2 +- >> > > 1 file changed, 1 insertion(+), 1 deletion(-) >> > >=20 >> > > diff --git a/drivers/vfio/fsl-mc/vfio_fsl_mc.c b/drivers/vfio/fsl-mc= /vfio_fsl_mc.c >> > > index 3feff729f3ce..66d01db1d240 100644 >> > > --- a/drivers/vfio/fsl-mc/vfio_fsl_mc.c >> > > +++ b/drivers/vfio/fsl-mc/vfio_fsl_mc.c >> > > @@ -110,7 +110,7 @@ static void vfio_fsl_mc_close_device(struct vfio= _device *core_vdev) >> > > if (WARN_ON(ret)) >> > > dev_warn(&mc_cont->dev, >> > > - "VFIO_FLS_MC: reset device has failed (%d)\n", ret); >> > > + "VFIO_FSL_MC: reset device has failed (%d)\n", ret); >> >=20 >> > WARN_ON already prints, this is better written as >> >=20 >> > WARN(ret, "VFIO_FSL_MC: reset device has failed (%d)\n", ret); >>=20 >> Or maybe, just: >> if (ret) >> dev_warn(&mc_cont->dev, >> "VFIO_FSL_MC: reset device has failed (%d)\n", ret); >>=20 >> This keep information about the device, avoid the duplicate printing rel= ated >> to WARN_ON+dev_warn and is more in line with error handling in other fil= es. >>=20 >> Do you agree or do you prefer a v2 as you proposed with WARN()? > > If the original author wrote WARN I would not degrade it to just a > dev_warn. Having to decide between losing the WARN and losing the device info, I'd just... fix the typo :)