Re: [PATCH v2 0/2] kdump: simplify code

2021-12-14 Thread Matthew Wilcox
On Tue, Dec 14, 2021 at 06:03:11PM +0800, Tiezhu Yang wrote: > On 12/13/2021 10:43 PM, Matthew Wilcox wrote: > > On Mon, Dec 13, 2021 at 08:30:33AM +, David Laight wrote: > > > From: Matthew Wilcox > > > > Sent: 12 December 2021 11:48 > > > > > > > > On Sat, Dec 11, 2021 at 05:53:46PM +, D

Re: [PATCH v2 0/2] kdump: simplify code

2021-12-14 Thread Tiezhu Yang
On 12/13/2021 10:43 PM, Matthew Wilcox wrote: On Mon, Dec 13, 2021 at 08:30:33AM +, David Laight wrote: From: Matthew Wilcox Sent: 12 December 2021 11:48 On Sat, Dec 11, 2021 at 05:53:46PM +, David Laight wrote: From: Tiezhu Yang Sent: 11 December 2021 03:33 v2: -- add copy_to_use

Re: [PATCH v2 0/2] kdump: simplify code

2021-12-13 Thread Matthew Wilcox
On Mon, Dec 13, 2021 at 08:30:33AM +, David Laight wrote: > From: Matthew Wilcox > > Sent: 12 December 2021 11:48 > > > > On Sat, Dec 11, 2021 at 05:53:46PM +, David Laight wrote: > > > From: Tiezhu Yang > > > > Sent: 11 December 2021 03:33 > > > > > > > > v2: > > > > -- add copy_to_user

RE: [PATCH v2 0/2] kdump: simplify code

2021-12-13 Thread David Laight
From: Matthew Wilcox > Sent: 12 December 2021 11:48 > > On Sat, Dec 11, 2021 at 05:53:46PM +, David Laight wrote: > > From: Tiezhu Yang > > > Sent: 11 December 2021 03:33 > > > > > > v2: > > > -- add copy_to_user_or_kernel() in lib/usercopy.c > > > -- define userbuf as bool type > > > > In

Re: [PATCH v2 0/2] kdump: simplify code

2021-12-12 Thread Matthew Wilcox
On Sat, Dec 11, 2021 at 05:53:46PM +, David Laight wrote: > From: Tiezhu Yang > > Sent: 11 December 2021 03:33 > > > > v2: > > -- add copy_to_user_or_kernel() in lib/usercopy.c > > -- define userbuf as bool type > > Instead of having a flag to indicate whether the buffer is user or kernel

Re: [PATCH v2 0/2] kdump: simplify code

2021-12-11 Thread Christophe Leroy
Le 11/12/2021 à 18:53, David Laight a écrit : > From: Tiezhu Yang >> Sent: 11 December 2021 03:33 >> >> v2: >>-- add copy_to_user_or_kernel() in lib/usercopy.c >>-- define userbuf as bool type > > Instead of having a flag to indicate whether the buffer is user or kernel, > would it be be

RE: [PATCH v2 0/2] kdump: simplify code

2021-12-11 Thread David Laight
From: Tiezhu Yang > Sent: 11 December 2021 03:33 > > v2: > -- add copy_to_user_or_kernel() in lib/usercopy.c > -- define userbuf as bool type Instead of having a flag to indicate whether the buffer is user or kernel, would it be better to have two separate buffer pointers. One for a user spac

[PATCH v2 0/2] kdump: simplify code

2021-12-10 Thread Tiezhu Yang
v2: -- add copy_to_user_or_kernel() in lib/usercopy.c -- define userbuf as bool type Tiezhu Yang (2): kdump: vmcore: remove copy_to() and add copy_to_user_or_kernel() kdump: crashdump: use copy_to_user_or_kernel() to simplify code arch/arm/kernel/crash_dump.c | 12 +++- arch/