Re: [RFC PATCH] ARM: zynq: Use memcpy_toio instead of memcpy on smp bring-up

2019-08-05 Thread Luis Araneda
Hi Michal, Thanks for the review. On Mon, Aug 5, 2019 at 5:53 AM Michal Simek wrote: > > On 31. 07. 19 6:12, Luis Araneda wrote: > > Hi Russell, > > > > Thanks for reviewing. > > > > On Tue, Jul 30, 2019 at 6:47 AM Russell King - ARM Linux admin > > wrote: > >> > >> On Tue, Jul 30, 2019 at 12:4

Re: [RFC PATCH] ARM: zynq: Use memcpy_toio instead of memcpy on smp bring-up

2019-08-05 Thread Michal Simek
On 31. 07. 19 6:12, Luis Araneda wrote: > Hi Russell, > > Thanks for reviewing. > > On Tue, Jul 30, 2019 at 6:47 AM Russell King - ARM Linux admin > wrote: >> >> On Tue, Jul 30, 2019 at 12:43:26AM -0400, Luis Araneda wrote: >>> This fixes a kernel panic (read overflow) on memcpy when >>> FORTIFY

Re: [RFC PATCH] ARM: zynq: Use memcpy_toio instead of memcpy on smp bring-up

2019-07-30 Thread Luis Araneda
Hi Russell, Thanks for reviewing. On Tue, Jul 30, 2019 at 6:47 AM Russell King - ARM Linux admin wrote: > > On Tue, Jul 30, 2019 at 12:43:26AM -0400, Luis Araneda wrote: > > This fixes a kernel panic (read overflow) on memcpy when > > FORTIFY_SOURCE is enabled. [...] > > I'm not convinced that t

Re: [RFC PATCH] ARM: zynq: Use memcpy_toio instead of memcpy on smp bring-up

2019-07-30 Thread Russell King - ARM Linux admin
On Tue, Jul 30, 2019 at 12:43:26AM -0400, Luis Araneda wrote: > This fixes a kernel panic (read overflow) on memcpy when > FORTIFY_SOURCE is enabled. > > The computed size of memcpy args are: > - p_size (dst): 4294967295 = (size_t) -1 > - q_size (src): 1 > - size (len): 8 > > Additionally, the me

[RFC PATCH] ARM: zynq: Use memcpy_toio instead of memcpy on smp bring-up

2019-07-29 Thread Luis Araneda
This fixes a kernel panic (read overflow) on memcpy when FORTIFY_SOURCE is enabled. The computed size of memcpy args are: - p_size (dst): 4294967295 = (size_t) -1 - q_size (src): 1 - size (len): 8 Additionally, the memory is marked as __iomem, so one of the memcpy_* functions should be used for r