From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E7C21C070C3 for ; Mon, 15 Oct 2018 02:45:08 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9F74720876 for ; Mon, 15 Oct 2018 02:45:08 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9F74720876 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=telegraphics.com.au Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726653AbeJOK2S (ORCPT ); Mon, 15 Oct 2018 06:28:18 -0400 Received: from kvm5.telegraphics.com.au ([98.124.60.144]:33396 "EHLO kvm5.telegraphics.com.au" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726262AbeJOK2S (ORCPT ); Mon, 15 Oct 2018 06:28:18 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by kvm5.telegraphics.com.au (Postfix) with ESMTP id E689022C32; Sun, 14 Oct 2018 22:45:02 -0400 (EDT) Date: Mon, 15 Oct 2018 13:45:01 +1100 (AEDT) From: Finn Thain To: Christoph Hellwig cc: "James E.J. Bottomley" , "Martin K. Petersen" , Michael Schmitz , Hannes Reinecke , linux-scsi@vger.kernel.org, linux-m68k@lists.linux-m68k.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 3/6] esp_scsi: Grant disconnect privilege for untagged commands In-Reply-To: Message-ID: References: <91b9ff9fc19ba40e3a2562171c8cd78a2ce7dc79.1539497520.git.fthain@telegraphics.com.au> <20181014154753.GA19252@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 15 Oct 2018, Finn Thain wrote: > On Sun, 14 Oct 2018, Christoph Hellwig wrote: > > > > + *p++ = IDENTIFY(lp && (tp->flags & ESP_TGT_DISCONNECT), lun); > > > > I think lp should always be non-NULL here. > > > > It's not clear from Documentation/scsi/scsi_mid_low_api.txt, but I guess > that's true for scanning of targets. > > Is it true in general that queuecommand for a device will not occur > before its slave_alloc and not after its slave_destroy invocation? > > (I'm thinking of queuecommand via the other command submission paths, > like ioctl.) > Nevermind. From a closer reading of the Documentation, I see that it is true in general. --