All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@kernel.dk>
To: "Pali Rohár" <pali@kernel.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
	Christoph Hellwig <hch@infradead.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: Linux 6.2-rc1
Date: Thu, 5 Jan 2023 10:45:47 -0700	[thread overview]
Message-ID: <58d3649f-3c8c-8b12-1930-f06f59837ad5@kernel.dk> (raw)
In-Reply-To: <20230105174210.jbjoqelllcrd57q6@pali>

On 1/5/23 10:42?AM, Pali Roh?r wrote:
> On Wednesday 04 January 2023 14:43:16 Jens Axboe wrote:
>> On 1/4/23 2:32?PM, Linus Torvalds wrote:
>>>> But here it is CD-RW media in read-write mode with kernel udf
>>>> filesystem driver without any userspace involved (after proper
>>>> formatting).
>>>
>>> ... but I'm not sure about direct writeable mount support.
>>>
>>> That may indeed be an area that only pktcdvd ended up doing. I've
>>> never used it myself, even historically.
>>>
>>> Let's bring in more people. Because they may not have thought about
>>> some RW UDF case.
>>
>> We did think about it, since that's the only reason for pktcdvd to
>> exist. Basically what the driver does is ensure that any write is 32K in
>> size, which is the size which can be written to media. It'll gather data
>> as needed to make that happen. Thats it. Outside of that, it's just some
>> setup and closing code.
>>
>> This obviously would be better to handle in userspace, all of it. Back
>> when I wrote this driver, we didn't have a lot of the fancier stuff we
>> have today. It could be done via ublk, for example, or something like
>> that.
>>
>> The surprising bit here is:
>>
>> 1) Someone is still using this driver, and
>> 2) It actually works!
> 
> Yes, there are still users and userspace tools (cdrwtool / pktsetup) are
> still receiving either small patches or issue reports. I think that it
> was two years ago when cdrwtool received big fixups to support
> formatting CD-RW discs on new CD/DVD drives.
> 
>> While I'd love to nudge folks in other directions for this use case, and
>> I strongly think that we should, it also doesn't seem fair to just yank
>> it while folks are using it... But I'd like to VERY strongly encourage
>> folks to come up with a new solution for this use case. It really isn't
>> a solution that belongs in the kernel today.
> 
> Linus in previous email wrote that he did "make SCSI commands generic"
> work in past so direct usage of /dev/cdrom device works for CD-R burning
> and read-only mounting.

Not quite sure what that refers to, as I'm pretty sure I did all of that
work. But maybe Linus can refresh my memory here :-)

> So could not be (for example sr.c) driver extended to directly do
> pktcdvd's work? So when somebody opens /dev/cdrom device in O_RDWR mode
> and CD-RW medium is present then it would behave like pktcdvd device...
> To have /dev/cdrom generic also for CD-RW write access.

As mentioned, I don't think this kind of code belongs in the kernel. sr
or cdrom could easily be modified to support the necessary bits to
handle a writeable open, but the grunt of the pktcdvd code deals with
retrieving and writing out bigger chunks of data. And that part really
does belong in userspace imho.

-- 
Jens Axboe


  reply	other threads:[~2023-01-05 17:46 UTC|newest]

Thread overview: 110+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-25 22:07 Linux 6.2-rc1 Linus Torvalds
2022-12-26 19:52 ` Guenter Roeck
2022-12-26 20:56   ` Linus Torvalds
2022-12-26 21:03     ` Kees Cook
2022-12-26 22:10       ` Guenter Roeck
2022-12-27  0:29       ` Guenter Roeck
2022-12-27  1:32         ` Kees Cook
2022-12-27  5:52           ` Guenter Roeck
2022-12-28  3:40             ` Kees Cook
2022-12-28 14:44               ` Guenter Roeck
2023-01-07  0:06                 ` Jaegeuk Kim
2022-12-26 22:41     ` Vlastimil Babka
2022-12-26 21:10   ` Max Filippov
2022-12-26 22:08     ` Guenter Roeck
2022-12-27  8:29 ` Build regressions/improvements in v6.2-rc1 Geert Uytterhoeven
2022-12-27  8:35   ` Geert Uytterhoeven
2022-12-27  8:35     ` Geert Uytterhoeven
2022-12-27  8:35     ` Geert Uytterhoeven
2023-01-01  1:33     ` Rob Landley
2023-01-01 12:24       ` Geert Uytterhoeven
2023-01-04  6:32         ` Michael Ellerman
2023-01-06 15:10     ` John Paul Adrian Glaubitz
2023-01-06 15:10       ` John Paul Adrian Glaubitz
2023-01-06 15:10       ` John Paul Adrian Glaubitz
2023-01-06 15:10       ` [f2fs-dev] " John Paul Adrian Glaubitz
2023-01-06 15:17       ` Geert Uytterhoeven
2023-01-06 15:17         ` Geert Uytterhoeven
2023-01-06 15:17         ` Geert Uytterhoeven
2023-01-06 15:17         ` [f2fs-dev] " Geert Uytterhoeven
2023-01-06 15:18         ` Geert Uytterhoeven
2023-01-06 15:18           ` Geert Uytterhoeven
2023-01-06 15:18           ` Geert Uytterhoeven
2023-01-06 15:18           ` Geert Uytterhoeven
2023-01-17 16:42         ` Calculating array sizes in C - was: " John Paul Adrian Glaubitz
2023-01-17 16:42           ` John Paul Adrian Glaubitz
2023-01-17 16:42           ` John Paul Adrian Glaubitz
2023-01-17 16:42           ` [f2fs-dev] " John Paul Adrian Glaubitz
2023-01-17 17:01           ` Geert Uytterhoeven
2023-01-17 17:01             ` Geert Uytterhoeven
2023-01-17 17:01             ` Geert Uytterhoeven
2023-01-17 17:01             ` [f2fs-dev] " Geert Uytterhoeven
2023-01-17 17:06             ` John Paul Adrian Glaubitz
2023-01-17 17:06               ` John Paul Adrian Glaubitz
2023-01-17 17:06               ` John Paul Adrian Glaubitz
2023-01-17 17:06               ` [f2fs-dev] " John Paul Adrian Glaubitz
2023-01-17 20:05               ` Geert Uytterhoeven
2023-01-17 20:05                 ` Geert Uytterhoeven
2023-01-17 20:05                 ` Geert Uytterhoeven
2023-01-17 20:05                 ` Geert Uytterhoeven
2023-01-17 20:37                 ` [f2fs-dev] " John Paul Adrian Glaubitz
2023-01-17 20:37                   ` John Paul Adrian Glaubitz
2023-01-17 20:37                   ` John Paul Adrian Glaubitz
2023-01-17 20:37                   ` John Paul Adrian Glaubitz
2023-01-19 22:11                   ` [f2fs-dev] " Michael.Karcher
2023-01-19 22:11                     ` Michael.Karcher
2023-01-19 22:11                     ` Michael.Karcher
2023-01-19 22:11                     ` Michael.Karcher
2023-01-20  3:31                     ` Rob Landley
2023-01-20  3:31                       ` [f2fs-dev] " Rob Landley
2023-01-20  3:31                       ` Rob Landley
2023-01-20  3:31                       ` Rob Landley
2023-01-20 10:53                       ` Segher Boessenkool
2023-01-20 10:53                         ` Segher Boessenkool
2023-01-20 10:53                         ` Segher Boessenkool
2023-01-20 10:53                         ` [f2fs-dev] " Segher Boessenkool
2023-01-20 11:42                         ` David Laight
2023-01-20 11:42                           ` David Laight
2023-01-20 11:42                           ` David Laight
2023-01-20 18:29                         ` Michael.Karcher
2023-01-20 18:29                           ` Michael.Karcher
2023-01-20 18:29                           ` Michael.Karcher
2023-01-20 18:29                           ` [f2fs-dev] " Michael.Karcher
2023-01-20  8:49                     ` John Paul Adrian Glaubitz
2023-01-20  8:49                       ` John Paul Adrian Glaubitz
2023-01-20  8:49                       ` John Paul Adrian Glaubitz
2023-01-20  8:49                       ` [f2fs-dev] " John Paul Adrian Glaubitz
2023-01-20 19:29                       ` Michael Karcher
2023-01-20 19:29                         ` Michael Karcher
2023-01-20 19:29                         ` Michael Karcher
2023-01-21 21:26                         ` John Paul Adrian Glaubitz
2023-01-21 21:26                           ` John Paul Adrian Glaubitz
2023-01-21 21:26                           ` John Paul Adrian Glaubitz
2023-01-21 21:26                           ` [f2fs-dev] " John Paul Adrian Glaubitz
2023-01-06 15:39     ` Alex Deucher
2023-01-06 15:39       ` Alex Deucher
2023-01-06 15:39       ` Alex Deucher
2023-01-06 15:39       ` [f2fs-dev] " Alex Deucher
2023-01-04 19:01 ` Linux 6.2-rc1 Pali Rohár
2023-01-04 19:25   ` Linus Torvalds
2023-01-04 20:56     ` Pali Rohár
2023-01-04 21:27       ` Pali Rohár
2023-01-04 21:32       ` Linus Torvalds
2023-01-04 21:43         ` Jens Axboe
2023-01-05 11:25           ` Greg Kroah-Hartman
2023-01-05 15:26             ` Jens Axboe
2023-01-05 17:42           ` Pali Rohár
2023-01-05 17:45             ` Jens Axboe [this message]
2023-01-05 19:06               ` Linus Torvalds
2023-01-05 19:22                 ` Pali Rohár
2023-01-05 19:40                 ` Jens Axboe
2023-01-05 20:03                   ` Linus Torvalds
2023-01-05 20:33                     ` Jens Axboe
2023-01-06 16:58                       ` Pali Rohár
2023-01-06 17:04                         ` Jens Axboe
2023-01-28 19:34                           ` pktcdvd Pali Rohár
2023-01-28 19:43                             ` pktcdvd Linus Torvalds
2023-01-29 21:53                               ` pktcdvd Jens Axboe
2023-01-29 21:55                             ` pktcdvd Jens Axboe
2023-01-29 22:21                               ` pktcdvd Pali Rohár
2023-01-29 22:34                                 ` pktcdvd Jens Axboe

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=58d3649f-3c8c-8b12-1930-f06f59837ad5@kernel.dk \
    --to=axboe@kernel.dk \
    --cc=gregkh@linuxfoundation.org \
    --cc=hch@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pali@kernel.org \
    --cc=torvalds@linux-foundation.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.