Re: [PATCH 1/1] rsa: fix retrieving public exponent on big-endian systems

2020-10-13 Thread Tom Rini
On Tue, Oct 06, 2020 at 12:09:45PM +0200, Rasmus Villemoes wrote: > Commit fdf0819afb (rsa: fix alignment issue when getting public > exponent) changed the logic to avoid doing an 8-byte access to a > possibly-not-8-byte-aligned address. > > However, using rsa_convert_big_endian is wrong: That fu

Re: [PATCH 1/1] rsa: fix retrieving public exponent on big-endian systems

2020-10-12 Thread Simon Glass
Hi Rasmus, On Mon, 12 Oct 2020 at 01:04, Rasmus Villemoes wrote: > > On 09/10/2020 15.08, Tom Rini wrote: > > On Wed, Oct 07, 2020 at 12:17:56AM +0200, Rasmus Villemoes wrote: > >> On 07/10/2020 00.02, Simon Glass wrote: > >>> > >>> Reviewed-by: Simon Glass > >>> > >>> Is there a way to add a te

Re: [PATCH 1/1] rsa: fix retrieving public exponent on big-endian systems

2020-10-12 Thread Tom Rini
On Mon, Oct 12, 2020 at 09:04:28AM +0200, Rasmus Villemoes wrote: > On 09/10/2020 15.08, Tom Rini wrote: > > On Wed, Oct 07, 2020 at 12:17:56AM +0200, Rasmus Villemoes wrote: > >> On 07/10/2020 00.02, Simon Glass wrote: > >>> > >>> Reviewed-by: Simon Glass > >>> > >>> Is there a way to add a test

Re: [PATCH 1/1] rsa: fix retrieving public exponent on big-endian systems

2020-10-12 Thread Rasmus Villemoes
On 09/10/2020 15.08, Tom Rini wrote: > On Wed, Oct 07, 2020 at 12:17:56AM +0200, Rasmus Villemoes wrote: >> On 07/10/2020 00.02, Simon Glass wrote: >>> >>> Reviewed-by: Simon Glass >>> >>> Is there a way to add a test for this? >> >> Not that I can think of, other than finding some BE board and ho

Re: [PATCH 1/1] rsa: fix retrieving public exponent on big-endian systems

2020-10-09 Thread Tom Rini
On Wed, Oct 07, 2020 at 12:17:56AM +0200, Rasmus Villemoes wrote: > On 07/10/2020 00.02, Simon Glass wrote: > > Hi Rasmus, > > > > On Tue, 6 Oct 2020 at 04:10, Rasmus Villemoes > > wrote: > >> > >> Commit fdf0819afb (rsa: fix alignment issue when getting public > >> exponent) changed the logic to

Re: [PATCH 1/1] rsa: fix retrieving public exponent on big-endian systems

2020-10-06 Thread Rasmus Villemoes
On 07/10/2020 00.02, Simon Glass wrote: > Hi Rasmus, > > On Tue, 6 Oct 2020 at 04:10, Rasmus Villemoes > wrote: >> >> Commit fdf0819afb (rsa: fix alignment issue when getting public >> exponent) changed the logic to avoid doing an 8-byte access to a >> possibly-not-8-byte-aligned address. >> >> H

Re: [PATCH 1/1] rsa: fix retrieving public exponent on big-endian systems

2020-10-06 Thread Simon Glass
Hi Rasmus, On Tue, 6 Oct 2020 at 04:10, Rasmus Villemoes wrote: > > Commit fdf0819afb (rsa: fix alignment issue when getting public > exponent) changed the logic to avoid doing an 8-byte access to a > possibly-not-8-byte-aligned address. > > However, using rsa_convert_big_endian is wrong: That fu

[PATCH 1/1] rsa: fix retrieving public exponent on big-endian systems

2020-10-06 Thread Rasmus Villemoes
Commit fdf0819afb (rsa: fix alignment issue when getting public exponent) changed the logic to avoid doing an 8-byte access to a possibly-not-8-byte-aligned address. However, using rsa_convert_big_endian is wrong: That function converts an array of big-endian (32-bit) words with the most significa