Re: [PATCH 2/7] stm class: Replace uuid_t with plain u8 uuid[16]

2021-04-15 Thread Alexander Shishkin
Greg Kroah-Hartman writes: > On Wed, Apr 14, 2021 at 10:14:34PM +0300, Alexander Shishkin wrote: >> Greg Kroah-Hartman writes: >> >> >> Using raw buffer APIs against uuid_t / guid_t. >> > >> > So you want to do that, or you do not want to do that? Totally >> > confused, >> >> My understanding

Re: [PATCH 2/7] stm class: Replace uuid_t with plain u8 uuid[16]

2021-04-15 Thread Greg Kroah-Hartman
On Thu, Apr 15, 2021 at 11:48:48AM +0300, Andy Shevchenko wrote: > On Thu, Apr 15, 2021 at 11:35 AM Greg Kroah-Hartman > wrote: > > > > On Wed, Apr 14, 2021 at 10:14:34PM +0300, Alexander Shishkin wrote: > > > Greg Kroah-Hartman writes: > > > > > > >> Using raw buffer APIs against uuid_t / guid_t

Re: [PATCH 2/7] stm class: Replace uuid_t with plain u8 uuid[16]

2021-04-15 Thread Andy Shevchenko
On Thu, Apr 15, 2021 at 11:35 AM Greg Kroah-Hartman wrote: > > On Wed, Apr 14, 2021 at 10:14:34PM +0300, Alexander Shishkin wrote: > > Greg Kroah-Hartman writes: > > > > >> Using raw buffer APIs against uuid_t / guid_t. > > > > > > So you want to do that, or you do not want to do that? Totally >

Re: [PATCH 2/7] stm class: Replace uuid_t with plain u8 uuid[16]

2021-04-15 Thread Greg Kroah-Hartman
On Wed, Apr 14, 2021 at 10:14:34PM +0300, Alexander Shishkin wrote: > Greg Kroah-Hartman writes: > > >> Using raw buffer APIs against uuid_t / guid_t. > > > > So you want to do that, or you do not want to do that? Totally > > confused, > > My understanding is that: > 1) generate_random_uuid() u

Re: [PATCH 2/7] stm class: Replace uuid_t with plain u8 uuid[16]

2021-04-14 Thread Andy Shevchenko
On Wed, Apr 14, 2021 at 10:14:34PM +0300, Alexander Shishkin wrote: > Greg Kroah-Hartman writes: > > >> Using raw buffer APIs against uuid_t / guid_t. > > > > So you want to do that, or you do not want to do that? Totally > > confused, > > My understanding is that: > 1) generate_random_uuid() u

Re: [PATCH 2/7] stm class: Replace uuid_t with plain u8 uuid[16]

2021-04-14 Thread Alexander Shishkin
Greg Kroah-Hartman writes: >> Using raw buffer APIs against uuid_t / guid_t. > > So you want to do that, or you do not want to do that? Totally > confused, My understanding is that: 1) generate_random_uuid() use is allegedly bad even though it's in their header, 2) poking directly at the byte a

Re: [PATCH 2/7] stm class: Replace uuid_t with plain u8 uuid[16]

2021-04-14 Thread Andy Shevchenko
On Wed, Apr 14, 2021 at 08:56:50PM +0200, Greg Kroah-Hartman wrote: > On Wed, Apr 14, 2021 at 08:47:48PM +0300, Andy Shevchenko wrote: > > On Wed, Apr 14, 2021 at 07:33:38PM +0200, Greg Kroah-Hartman wrote: > > > On Wed, Apr 14, 2021 at 08:12:46PM +0300, Alexander Shishkin wrote: ... > > Nothing,

Re: [PATCH 2/7] stm class: Replace uuid_t with plain u8 uuid[16]

2021-04-14 Thread Greg Kroah-Hartman
On Wed, Apr 14, 2021 at 08:47:48PM +0300, Andy Shevchenko wrote: > On Wed, Apr 14, 2021 at 07:33:38PM +0200, Greg Kroah-Hartman wrote: > > On Wed, Apr 14, 2021 at 08:12:46PM +0300, Alexander Shishkin wrote: > > > From: Andy Shevchenko > > > > > > It appears that uuid_t use in STM code abuses UUID

Re: [PATCH 2/7] stm class: Replace uuid_t with plain u8 uuid[16]

2021-04-14 Thread Andy Shevchenko
On Wed, Apr 14, 2021 at 07:33:38PM +0200, Greg Kroah-Hartman wrote: > On Wed, Apr 14, 2021 at 08:12:46PM +0300, Alexander Shishkin wrote: > > From: Andy Shevchenko > > > > It appears that uuid_t use in STM code abuses UUID API. > > How is it being abused? We are using it against the buffer that

Re: [PATCH 2/7] stm class: Replace uuid_t with plain u8 uuid[16]

2021-04-14 Thread Greg Kroah-Hartman
On Wed, Apr 14, 2021 at 08:12:46PM +0300, Alexander Shishkin wrote: > From: Andy Shevchenko > > It appears that uuid_t use in STM code abuses UUID API. How is it being abused? Moreover, > this type is only useful when we parse user input. Due to above > replace uuid_t with u8 uuid[16] and use u

[PATCH 2/7] stm class: Replace uuid_t with plain u8 uuid[16]

2021-04-14 Thread Alexander Shishkin
From: Andy Shevchenko It appears that uuid_t use in STM code abuses UUID API. Moreover, this type is only useful when we parse user input. Due to above replace uuid_t with u8 uuid[16] and use uuid_t only when parse user input. Signed-off-by: Andy Shevchenko Signed-off-by: Alexander Shishkin --