linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Laight <David.Laight@ACULAB.COM>
To: 'Stefano Garzarella' <sgarzare@redhat.com>,
	Colin King <colin.king@canonical.com>
Cc: "David S . Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"kernel-janitors@vger.kernel.org"
	<kernel-janitors@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: RE: [PATCH] vsock: ratelimit unknown ioctl error message
Date: Fri, 23 Oct 2020 21:30:59 +0000	[thread overview]
Message-ID: <e535c07df407444880d8b678bc215d9f@AcuMS.aculab.com> (raw)
In-Reply-To: <20201023140947.kurglnklaqteovkp@steredhat>


From: Stefano Garzarella
> Sent: 23 October 2020 15:10
> 
> On Fri, Oct 23, 2020 at 01:21:13PM +0100, Colin King wrote:
> >From: Colin Ian King <colin.king@canonical.com>
> >
> >When exercising the kernel with stress-ng with some ioctl tests the
> >"Unknown ioctl" error message is spamming the kernel log at a high
> >rate. Rate limit this message to reduce the noise.
> >
> >Signed-off-by: Colin Ian King <colin.king@canonical.com>
> >---
> > net/vmw_vsock/af_vsock.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> >diff --git a/net/vmw_vsock/af_vsock.c b/net/vmw_vsock/af_vsock.c
> >index 9e93bc201cc0..b8feb9223454 100644
> >--- a/net/vmw_vsock/af_vsock.c
> >+++ b/net/vmw_vsock/af_vsock.c
> >@@ -2072,7 +2072,7 @@ static long vsock_dev_do_ioctl(struct file *filp,
> > 		break;
> >
> > 	default:
> >-		pr_err("Unknown ioctl %d\n", cmd);
> >+		pr_err_ratelimited("Unknown ioctl %d\n", cmd);
> 
> Make sense, or maybe can we remove the error message returning only the
> -EINVAL?

Isn't the canonical error for unknown ioctl codes -ENOTTY?

	David

-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK
Registration No: 1397386 (Wales)


  parent reply	other threads:[~2020-10-23 21:31 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-23 12:21 [PATCH] vsock: ratelimit unknown ioctl error message Colin King
2020-10-23 14:09 ` Stefano Garzarella
2020-10-23 20:25   ` Jakub Kicinski
2020-10-23 21:30   ` David Laight [this message]
2020-10-26  8:43     ` Stefano Garzarella
2020-10-26  9:13       ` David Laight
2020-10-26  9:39         ` Stefano Garzarella
2020-10-26  9:46           ` David Laight
2020-10-26 10:01             ` Stefano Garzarella
2020-10-26 17:55               ` Jakub Kicinski
2020-10-26 18:24                 ` Stefano Garzarella
2020-10-26 18:37                   ` Jakub Kicinski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e535c07df407444880d8b678bc215d9f@AcuMS.aculab.com \
    --to=david.laight@aculab.com \
    --cc=colin.king@canonical.com \
    --cc=davem@davemloft.net \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=sgarzare@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).