From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:48612) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V1CLG-0002Xv-4e for qemu-devel@nongnu.org; Mon, 22 Jul 2013 05:23:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V1CLE-0006Im-2D for qemu-devel@nongnu.org; Mon, 22 Jul 2013 05:23:42 -0400 Received: from mail-ie0-f169.google.com ([209.85.223.169]:52340) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V1CLD-0006IG-TA for qemu-devel@nongnu.org; Mon, 22 Jul 2013 05:23:39 -0400 Received: by mail-ie0-f169.google.com with SMTP id at20so3773493iec.28 for ; Mon, 22 Jul 2013 02:23:38 -0700 (PDT) Message-ID: <51ECFA12.20200@ozlabs.ru> Date: Mon, 22 Jul 2013 19:23:30 +1000 From: Alexey Kardashevskiy MIME-Version: 1.0 References: <1374401042-18511-1-git-send-email-aik@ozlabs.ru> <1374442491.3916.2.camel@pasglop> <51EC7AC9.3080306@ozlabs.ru> <1374452612.3916.17.camel@pasglop> <51EC8381.4020801@ozlabs.ru> <1374455044.3916.27.camel@pasglop> <51ECD190.60700@redhat.com> In-Reply-To: <51ECD190.60700@redhat.com> Content-Type: text/plain; charset=KOI8-R Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RFC PATCH] spapr-vscsi: add task management List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: Anthony Liguori , Alexander Graf , qemu-devel@nongnu.org, qemu-ppc@nongnu.org, Paul Mackerras , David Gibson On 07/22/2013 04:30 PM, Paolo Bonzini wrote: > Il 22/07/2013 03:04, Benjamin Herrenschmidt ha scritto: >> The free_request callback >> is not directly "linked" to task management though it happens to only >> be called in that case. It's a pre-requisite to task management, make it >> a separate patch. > > Ben is right, in fact I'm not sure why you need free_request at all > (since vscsi_put_req is called from both vscsi_command_complete and > vscsi_request_cancelled). > > free_request is only needed by hw/usb/dev-uas.c because it does > scsi_req_ref/scsi_req_unref in the HBA code. There is no need for this, > AFAIK, in the current spapr_vscsi code; if it is done in the > reorganization patches, the free_request callback should be added there. Hmmm. It looks like you're right :-/ I am just not very familiar with this stuff yet so some misunderstanding is expected :) For now I cannot find really good testing sequence. I do some delay hacks in various places but I am not sure I am testing what I want to test as "req->enqueued" is always false when I debug task management. -- Alexey