[ofa-general] itt member in iscsi_data?
Roland Dreier
rdreier at cisco.com
Fri Mar 14 10:33:07 PDT 2008
iser_initiator.c has this code:
itt = ntohl(hdr->itt);
which triggers sparse warnings like:
drivers/infiniband/ulp/iser/iser_initiator.c:419:8: warning: cast to restricted type
drivers/infiniband/ulp/iser/iser_initiator.c:419:8: warning: cast from restricted type
and indeed the itt field is declared as itt_t, with no particular
endianness, so the sparse warnings seem like they are pointing at
something that really is suspicious.
It seems the only use of itt in the function that does ntohl() is to
print the value our in debugging statements. What is intended here?
Would it just make sense to for the debug statements to print hdr->itt
out directly with no conversion?
- R.
More information about the general
mailing list