direct-io.hg

changeset 10695:612671bd9a54

[TPM] Discard a future response packet after a timeout has occurred instead of
removing the request right away.
Signed-off-by: Stefan Berger <stefanb@us.ibm.com>
author kaf24@firebug.cl.cam.ac.uk
date Fri Jul 14 11:48:48 2006 +0100 (2006-07-14)
parents 7bf0d46e369a
children 00822a3a57d9 89f7faa0c01a
files linux-2.6-xen-sparse/drivers/xen/tpmback/tpmback.c
line diff
     1.1 --- a/linux-2.6-xen-sparse/drivers/xen/tpmback/tpmback.c	Fri Jul 14 11:46:57 2006 +0100
     1.2 +++ b/linux-2.6-xen-sparse/drivers/xen/tpmback/tpmback.c	Fri Jul 14 11:48:48 2006 +0100
     1.3 @@ -852,11 +852,11 @@ static void processing_timeout(unsigned 
     1.4  	 */
     1.5  	if (pak == packet_find_packet(&dataex.pending_pak, pak) ||
     1.6  	    pak == packet_find_packet(&dataex.current_pak, pak)) {
     1.7 -		list_del(&pak->next);
     1.8  		if ((pak->flags & PACKET_FLAG_DISCARD_RESPONSE) == 0) {
     1.9  			tpm_send_fail_message(pak, pak->req_tag);
    1.10  		}
    1.11 -		packet_free(pak);
    1.12 +		/* discard future responses */
    1.13 +		pak->flags |= PACKET_FLAG_DISCARD_RESPONSE;
    1.14  	}
    1.15  
    1.16  	write_unlock_irqrestore(&dataex.pak_lock, flags);