2023-08-18 04:38:53

by David Laight

[permalink] [raw]
Subject: RE: [PATCH v3 2/2] iov_iter: Don't deal with iter->copy_mc in memcpy_from_iter_mc()

From: David Howells
> Sent: Wednesday, August 16, 2023 2:01 PM
>
> David Laight <[email protected]> wrote:
>
> >
> > Couldn't the relevant code directly call __copy_from_iter_mc() ?
> > Or a version then checked iov_is_copy_mc() and then fell
> > back to the standard function.
>
> No, because the marked iterator is handed by the coredump code to
> __kernel_write_iter() and thence on to who-knows-what driver - which will call
> copy_from_iter() or some such. $DRIVER shouldn't need to know about
> ->copy_mc.

What about ITER_BVEC_MC ??

David

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



2023-08-19 17:41:13

by Linus Torvalds

[permalink] [raw]
Subject: Re: [PATCH v3 2/2] iov_iter: Don't deal with iter->copy_mc in memcpy_from_iter_mc()

On Wed, 16 Aug 2023 at 14:19, David Laight <[email protected]> wrote:
>
> What about ITER_BVEC_MC ??

That probably would be the best option. Just make it a proper
ITER_xyz, instead of an odd sub-case for one ITER (but set up in such
a way that it looks like it might happen for other ITER_xyz cases).

Linus