Add a new helper function _set_itt() that can be used to set the itt of
a pdu, instead of having to twiddle the bits and bytes manually.
This commit is contained in:
@@ -280,6 +280,12 @@ iscsi_process_pdu(struct iscsi_context *iscsi, struct iscsi_in_pdu *in)
|
||||
return 0;
|
||||
}
|
||||
|
||||
void
|
||||
iscsi_pdu_set_itt(struct iscsi_pdu *pdu, uint32_t itt)
|
||||
{
|
||||
*(uint32_t *)&pdu->outdata.data[16] = htonl(itt);
|
||||
}
|
||||
|
||||
void
|
||||
iscsi_pdu_set_pduflags(struct iscsi_pdu *pdu, unsigned char flags)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user