Re: [PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-09 Thread Sakari Ailus
Hi Mauro, On Wed, Jan 09, 2019 at 10:13:42AM -0200, Mauro Carvalho Chehab wrote: > Em Tue, 08 Jan 2019 18:05:57 +0200 > Laurent Pinchart escreveu: > > > On Tuesday, 8 January 2019 16:30:22 EET Mauro Carvalho Chehab wrote: > > > Em Tue, 8 Jan 2019 15:40:47 +0200 > > > > > > Sakari Ailus escreve

Re: [PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-09 Thread Mauro Carvalho Chehab
Em Tue, 08 Jan 2019 18:05:57 +0200 Laurent Pinchart escreveu: > On Tuesday, 8 January 2019 16:30:22 EET Mauro Carvalho Chehab wrote: > > Em Tue, 8 Jan 2019 15:40:47 +0200 > > > > Sakari Ailus escreveu: > > > On Tue, Jan 08, 2019 at 10:59:55AM -0200, Mauro Carvalho Chehab wrote: > > > > Em T

Re: [PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-09 Thread Sakari Ailus
On Tue, Jan 08, 2019 at 12:23:49PM -0200, Mauro Carvalho Chehab wrote: > Em Tue, 8 Jan 2019 15:38:32 +0200 > Sakari Ailus escreveu: > > > Hi Mauro, > > > > Thanks for the review. > > > > On Tue, Jan 08, 2019 at 10:59:55AM -0200, Mauro Carvalho Chehab wrote: > > > Em Tue, 8 Jan 2019 10:52:12 -02

Re: [PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-08 Thread Laurent Pinchart
On Tuesday, 8 January 2019 16:30:22 EET Mauro Carvalho Chehab wrote: > Em Tue, 8 Jan 2019 15:40:47 +0200 > > Sakari Ailus escreveu: > > On Tue, Jan 08, 2019 at 10:59:55AM -0200, Mauro Carvalho Chehab wrote: > > > Em Tue, 8 Jan 2019 10:52:12 -0200 > > > > > > Mauro Carvalho Chehab escreveu: > >

Re: [PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-08 Thread Mauro Carvalho Chehab
Em Tue, 8 Jan 2019 15:40:47 +0200 Sakari Ailus escreveu: > On Tue, Jan 08, 2019 at 10:59:55AM -0200, Mauro Carvalho Chehab wrote: > > Em Tue, 8 Jan 2019 10:52:12 -0200 > > Mauro Carvalho Chehab escreveu: > > > > > Em Tue, 8 Jan 2019 10:58:34 +0200 > > > Sakari Ailus escreveu: > > > > > >

Re: [PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-08 Thread Mauro Carvalho Chehab
Em Tue, 8 Jan 2019 15:38:32 +0200 Sakari Ailus escreveu: > Hi Mauro, > > Thanks for the review. > > On Tue, Jan 08, 2019 at 10:59:55AM -0200, Mauro Carvalho Chehab wrote: > > Em Tue, 8 Jan 2019 10:52:12 -0200 > > Mauro Carvalho Chehab escreveu: > > > > > Em Tue, 8 Jan 2019 10:58:34 +0200 >

Re: [PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-08 Thread Sakari Ailus
On Tue, Jan 08, 2019 at 10:59:55AM -0200, Mauro Carvalho Chehab wrote: > Em Tue, 8 Jan 2019 10:52:12 -0200 > Mauro Carvalho Chehab escreveu: > > > Em Tue, 8 Jan 2019 10:58:34 +0200 > > Sakari Ailus escreveu: > > > > > PAGE_ALIGN() may wrap the buffer size around to 0. Prevent this by > > > che

Re: [PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-08 Thread Sakari Ailus
Hi Mauro, Thanks for the review. On Tue, Jan 08, 2019 at 10:59:55AM -0200, Mauro Carvalho Chehab wrote: > Em Tue, 8 Jan 2019 10:52:12 -0200 > Mauro Carvalho Chehab escreveu: > > > Em Tue, 8 Jan 2019 10:58:34 +0200 > > Sakari Ailus escreveu: > > > > > PAGE_ALIGN() may wrap the buffer size aro

Re: [PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-08 Thread Mauro Carvalho Chehab
Em Tue, 8 Jan 2019 10:59:55 -0200 Mauro Carvalho Chehab escreveu: > Em Tue, 8 Jan 2019 10:52:12 -0200 > Mauro Carvalho Chehab escreveu: > > > Em Tue, 8 Jan 2019 10:58:34 +0200 > > Sakari Ailus escreveu: > > > > > PAGE_ALIGN() may wrap the buffer size around to 0. Prevent this by > > > checki

Re: [PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-08 Thread Mauro Carvalho Chehab
Em Tue, 8 Jan 2019 10:52:12 -0200 Mauro Carvalho Chehab escreveu: > Em Tue, 8 Jan 2019 10:58:34 +0200 > Sakari Ailus escreveu: > > > PAGE_ALIGN() may wrap the buffer size around to 0. Prevent this by > > checking that the aligned value is not smaller than the unaligned one. > > > > Note on ba

Re: [PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-08 Thread Mauro Carvalho Chehab
Em Tue, 8 Jan 2019 10:58:34 +0200 Sakari Ailus escreveu: > PAGE_ALIGN() may wrap the buffer size around to 0. Prevent this by > checking that the aligned value is not smaller than the unaligned one. > > Note on backporting to stable: the file used to be under > drivers/media/v4l2-core, it was m

[PATCH v2 1/3] videobuf2-core: Prevent size alignment wrapping buffer size to 0

2019-01-08 Thread Sakari Ailus
PAGE_ALIGN() may wrap the buffer size around to 0. Prevent this by checking that the aligned value is not smaller than the unaligned one. Note on backporting to stable: the file used to be under drivers/media/v4l2-core, it was moved to the current location after 4.14. Signed-off-by: Sakari Ailus