lkml.org 
[lkml]   [2005]   [Feb]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [BK PATCHES] 2.6.x libata fixes (mostly)
Roland Dreier schrieb:
> Prakash> If I am not totally mistaken this is not gcc4 friendly
> Prakash> code. (lvalue thing...)
>
> Actually you misread the code slightly. It's a little subtle, but
> code like
>
> *(__le32 *)prd = cpu_to_le32(len);
>
> is not using a cast as an lvalue. It's dereferencing a cast and as
> such is totally correct, idiomatic and clean C.

OK, thanks for clearing that up. Obviously my C knowledge needs to be improved...

--
Prakash Punnoor

formerly known as Prakash K. Cheemplavam
[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2005-03-22 14:10    [W:0.051 / U:0.404 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site