RE: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Long Li
> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request > through > kmalloc > > On 4/18/2018 1:16 PM, Long Li wrote: > >> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation > >> request through kmalloc > >> > >> Tw

RE: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Long Li
> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request > through > kmalloc > > On 4/18/2018 1:16 PM, Long Li wrote: > >> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation > >> request through kmalloc > >> > >> Tw

RE: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Long Li
> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request > through > kmalloc > > On 4/18/2018 1:11 PM, Long Li wrote: > >> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation > >> request through kmalloc > >> > >> O

RE: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Long Li
> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request > through > kmalloc > > On 4/18/2018 1:11 PM, Long Li wrote: > >> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation > >> request through kmalloc > >> > >> O

Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Tom Talpey
On 4/18/2018 1:16 PM, Long Li wrote: Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc Two comments. On 4/17/2018 8:33 PM, Long Li wrote: From: Long Li <lon...@microsoft.com> The data buffer allocated on the stack can't be DMA'ed, and hence can'

Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Tom Talpey
On 4/18/2018 1:16 PM, Long Li wrote: Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc Two comments. On 4/17/2018 8:33 PM, Long Li wrote: From: Long Li The data buffer allocated on the stack can't be DMA'ed, and hence can't send through RDMA via SMB

Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Tom Talpey
On 4/18/2018 1:11 PM, Long Li wrote: Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc On 4/18/2018 9:08 AM, David Laight wrote: From: Tom Talpey Sent: 18 April 2018 12:32 ... On 4/17/2018 8:33 PM, Long Li wrote: From: Long Li <lon...@microsoft.

Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Tom Talpey
On 4/18/2018 1:11 PM, Long Li wrote: Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc On 4/18/2018 9:08 AM, David Laight wrote: From: Tom Talpey Sent: 18 April 2018 12:32 ... On 4/17/2018 8:33 PM, Long Li wrote: From: Long Li The data buffer

RE: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Long Li
> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request > through > kmalloc > > Two comments. > > On 4/17/2018 8:33 PM, Long Li wrote: > > From: Long Li <lon...@microsoft.com> > > > > The data buffer allocated on the stack can't be

RE: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Long Li
> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request > through > kmalloc > > Two comments. > > On 4/17/2018 8:33 PM, Long Li wrote: > > From: Long Li > > > > The data buffer allocated on the stack can't be DMA'ed, and hence >

RE: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Long Li
> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request > through > kmalloc > > On 4/18/2018 9:08 AM, David Laight wrote: > > From: Tom Talpey > >> Sent: 18 April 2018 12:32 > > ... > >> On 4/17/2018 8:33 PM, Long Li wro

RE: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Long Li
> Subject: Re: [Patch v3 2/6] cifs: Allocate validate negotiation request > through > kmalloc > > On 4/18/2018 9:08 AM, David Laight wrote: > > From: Tom Talpey > >> Sent: 18 April 2018 12:32 > > ... > >> On 4/17/2018 8:33 PM, Long Li wrote: >

Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Tom Talpey
On 4/18/2018 9:08 AM, David Laight wrote: From: Tom Talpey Sent: 18 April 2018 12:32 ... On 4/17/2018 8:33 PM, Long Li wrote: From: Long Li The data buffer allocated on the stack can't be DMA'ed, and hence can't send through RDMA via SMB Direct. This comment is

Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Tom Talpey
On 4/18/2018 9:08 AM, David Laight wrote: From: Tom Talpey Sent: 18 April 2018 12:32 ... On 4/17/2018 8:33 PM, Long Li wrote: From: Long Li The data buffer allocated on the stack can't be DMA'ed, and hence can't send through RDMA via SMB Direct. This comment is confusing. Any registered

RE: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread David Laight
From: Tom Talpey > Sent: 18 April 2018 12:32 ... > On 4/17/2018 8:33 PM, Long Li wrote: > > From: Long Li > > > > The data buffer allocated on the stack can't be DMA'ed, and hence can't send > > through RDMA via SMB Direct. > > This comment is confusing. Any registered

RE: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread David Laight
From: Tom Talpey > Sent: 18 April 2018 12:32 ... > On 4/17/2018 8:33 PM, Long Li wrote: > > From: Long Li > > > > The data buffer allocated on the stack can't be DMA'ed, and hence can't send > > through RDMA via SMB Direct. > > This comment is confusing. Any registered memory can be DMA'd, need

Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Tom Talpey
Two comments. On 4/17/2018 8:33 PM, Long Li wrote: From: Long Li The data buffer allocated on the stack can't be DMA'ed, and hence can't send through RDMA via SMB Direct. This comment is confusing. Any registered memory can be DMA'd, need to state the reason for the

Re: [Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-18 Thread Tom Talpey
Two comments. On 4/17/2018 8:33 PM, Long Li wrote: From: Long Li The data buffer allocated on the stack can't be DMA'ed, and hence can't send through RDMA via SMB Direct. This comment is confusing. Any registered memory can be DMA'd, need to state the reason for the choice here more

[Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-17 Thread Long Li
From: Long Li The data buffer allocated on the stack can't be DMA'ed, and hence can't send through RDMA via SMB Direct. Fix this by allocating the request on the heap in smb3_validate_negotiate. Changes in v2: Removed duplicated code on freeing buffers on function exit.

[Patch v3 2/6] cifs: Allocate validate negotiation request through kmalloc

2018-04-17 Thread Long Li
From: Long Li The data buffer allocated on the stack can't be DMA'ed, and hence can't send through RDMA via SMB Direct. Fix this by allocating the request on the heap in smb3_validate_negotiate. Changes in v2: Removed duplicated code on freeing buffers on function exit. (Thanks to Parav Pandit