On 19/07/13 01:39, John Foley wrote:
> With respect to the master branch, you should be able to avoid the patch
> and compile with -DFORCE_64BIT_ALIGN.  The patch provides no value in
> the master branch. 

The version I am testing is the Debian git master, it is the same as
master on github but with some local patches:

http://anonscm.debian.org/gitweb/?p=collab-maint/srtp.git;a=tree;f=debian/patches;hb=HEAD

Without FORCE_64BIT_ALIGN  and without the patch mentioned below (patch
ID 2002 in Debian): I get the bus error in the test

crypto/tests/cipher_driver



With FORCE_64BIT_ALIGN  and without the patch mentioned below (patch ID
2002 in Debian): no more bus error, it fails in the test

test/stat_driver  (although running the test a second time it passes)


With FORCE_64BIT_ALIGN  and patch ID 2002 (remove pad, add algorithm to 
cipher_t) the tests all pass on the first run

If it helps, we can provide a guest account on the Debian sparc test machine if 
you would be able to try this directly.


> I'll need to address this problem in the openssl-feature branch.  There
> should be no need to force the 64-bit alignment when the cipher_t struct
> contains the 'algorithm' field. 
>
> Regarding x86_64, I have tested this platform and have never seen an
> issue in this code.  The compiler is likely doing the alignment
> automatically, knowing that it's compiling for a 64 bit target. 
>
>
>
> On 07/18/2013 06:02 PM, Daniel Pocock wrote:
>> On 18/07/13 23:46, Michael Jerris wrote:
>>> If you don't remove that block from the code after that other var was 
>>> added… it will cause this error to come back on that branch now that you've 
>>> forced the 64bit align
>>>
>> Ok, patching it like this:
>>
>> --- a/crypto/include/cipher.h
>> +++ b/crypto/include/cipher.h
>> @@ -161,8 +161,9 @@ typedef struct cipher_t {
>>    void          *state;
>>    int            key_len;
>>  #ifdef FORCE_64BIT_ALIGN
>> -  int            pad;
>> +  //int            pad;
>>  #endif
>> +  int algorithm;
>>  } cipher_t;
>>
>>
>> and using
>>
>> CFLAGS += -DFORCE_64BIT_ALIGN
>>
>> gives me an successful runtest on sparc first time around.  The build
>> still fails later during the doc phase on sparc, but that is unrelated
>> to all this.
>>
>> I also tested on amd64 / x86_64 without FORCE_64BIT_ALIGN and it builds
>> successfully.
>>
>> .
>>


-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to