public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: Nick Bowler <nbowler@draconx.ca>
Cc: linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org,
	Christoph Hellwig <hch@lst.de>
Subject: Re: [PATCH] nvme: Define compat_ioctl again to unbreak 32-bit userspace.
Date: Wed, 20 Jul 2022 06:27:26 +0200	[thread overview]
Message-ID: <20220720042726.GA5574@lst.de> (raw)
In-Reply-To: <20220720015538.15838-1-nbowler@draconx.ca>

On Tue, Jul 19, 2022 at 09:55:38PM -0400, Nick Bowler wrote:
> Commit 89b3d6e60550 ("nvme: simplify the compat ioctl handling") removed
> the initialization of compat_ioctl from the nvme block_device_operations
> structures.
> 
> Presumably the expectation was that 32-bit ioctls would be directed
> through the regular handler but this is not the case: failing to assign
> .compat_ioctl actually means that the compat case is disabled entirely,
> and any attempt to submit nvme ioctls from 32-bit userspace fails
> outright with -ENOTTY.

I don't think wiring up the native version is the right thing to do,
this needs to be blkdev_compat_ptr_ioctl, just like we use
compat_ptr_ioctl for the character device nodes.

  parent reply	other threads:[~2022-07-20  4:27 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-20  1:55 [PATCH] nvme: Define compat_ioctl again to unbreak 32-bit userspace Nick Bowler
2022-07-20  3:51 ` Guixin Liu
2022-07-21  3:56   ` Nick Bowler
2022-07-20  4:27 ` Christoph Hellwig [this message]
2022-07-20 12:49   ` Nick Bowler

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=20220720042726.GA5574@lst.de \
    --to=hch@lst.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nvme@lists.infradead.org \
    --cc=nbowler@draconx.ca \
    /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