Received: by 2002:a25:868d:0:0:0:0:0 with SMTP id z13csp889828ybk; Fri, 15 May 2020 16:53:01 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxIjQlqacJ5P+m9ZbMPnSJPfBDVDhUv3U9XqJ6N26oN+oJSsi8HWDC2JftlCaYvZRUL+EzC X-Received: by 2002:a05:6402:c0e:: with SMTP id co14mr5010262edb.177.1589586780895; Fri, 15 May 2020 16:53:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1589586780; cv=none; d=google.com; s=arc-20160816; b=HLioyZ+6P+JZ7rxec4PyprVL/EAbQy8Q6ZYeEvI2hOKZom1cB4wtnInBJTeCjRSjwG Xowb6YRDZUA0R9hilJzYv03IcgZoIJ7JjS+w+XDE+D5hwjfnyOabu3/A9hotz9Y7hvyn FgSQKWJPPTczmrIe+OyrFAacjfTIVplrMAATbVK3kYldUzSKS97xa0BJa1b0HLmVW7XX uCB/n/UC0cf2UsCXSgte8OF7fC1jmxywsdYSYtVacA1Kg9I/AxD8ANojxk2VxIuGy8Zl m88cpdK3zTdrrtVz4rgvYyKVyFiECoTRFPxNeP3fkL0/qYmH4heRugArUyLmaCf+e5T6 pMxQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=Hw3RkCsgcQacr6zjV1u999K3NhEH21GsqpqwnnfF7j0=; b=MBoXauPxkVjNY7zGTRaLKb15re7dJp8BHwro/xjplgnQnAk3LOtdIob0PhRznD4YAW Egzh973TdQAfI9+dQVW2K7WxmU16d3sa7hXvRUVaxD5/xnYnyc9GZNzl3gm697krv2c7 x4LDCQlYD5I717joHzqZCQDkwQE8NpFw6R1RjUeHKyq/9V2aquC2epqyvIjdti16iKji tVBAZRM/d1h+pox0AhbyhOsOf67GYfk3sdat9MXlZaJSgbH2iLW+85O81skiN3xB9591 SLh1qhJXLP6DY0JkVtDVtRnH/+AzO8IcedDJREE5kvjIJfoVloZrT+D3cg1WTIdHz1Jo wLtA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b="LOE/kShL"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w14si2118316edl.600.2020.05.15.16.52.36; Fri, 15 May 2020 16:53:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b="LOE/kShL"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726624AbgEOXuH (ORCPT + 99 others); Fri, 15 May 2020 19:50:07 -0400 Received: from us-smtp-1.mimecast.com ([207.211.31.81]:47580 "EHLO us-smtp-delivery-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726198AbgEOXuH (ORCPT ); Fri, 15 May 2020 19:50:07 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1589586606; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Hw3RkCsgcQacr6zjV1u999K3NhEH21GsqpqwnnfF7j0=; b=LOE/kShLy3W8yXhbc2TAIxVMuH/Ebl05F/9u/jGl0+afA7bgUjLNPKxYE1Usr8hm9G3Acu v02Cv+QF60/bQrLGCx2EhaWZ0wcztAiMXP/T5js/s7/QmxsWTvcJOt95AxVjN7j+XT6hvj SJpUsn4zt7VhuHaMp+LwnCBM3fmMthE= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-115-ICg31iNCP2q4ZAaE7I9IYw-1; Fri, 15 May 2020 19:50:03 -0400 X-MC-Unique: ICg31iNCP2q4ZAaE7I9IYw-1 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 4B9CA1841958; Fri, 15 May 2020 23:50:02 +0000 (UTC) Received: from [10.10.118.190] (ovpn-118-190.rdu2.redhat.com [10.10.118.190]) by smtp.corp.redhat.com (Postfix) with ESMTP id 828C51943D; Fri, 15 May 2020 23:50:01 +0000 (UTC) Subject: Re: [PATCH target] target: Add initiatorname to NON_EXISTENT_LUN error To: Lance Digby , martin.petersen@oracle.com Cc: linux-scsi@vger.kernel.org, target-devel@vger.kernel.org, linux-kernel@vger.kernel.org References: From: Mike Christie Message-ID: <93c437ce-f881-9f54-5e39-afa8afd96141@redhat.com> Date: Fri, 15 May 2020 18:50:00 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/13/20 11:01 PM, Lance Digby wrote: > The NON_EXISTENT_LUN error can be written without an error condition > on the initiator responsible. Adding the initiatorname to this message > will reduce the effort required to fix this when many initiators are > supported by a target. > > Signed-off-by: Lance Digby > --- > drivers/target/target_core_device.c | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > > diff --git a/drivers/target/target_core_device.c b/drivers/target/target_core_device.c > index 4cee113..604dea0 100644 > --- a/drivers/target/target_core_device.c > +++ b/drivers/target/target_core_device.c > @@ -100,9 +100,10 @@ > */ > if (unpacked_lun != 0) { > pr_err("TARGET_CORE[%s]: Detected NON_EXISTENT_LUN" > - " Access for 0x%08llx\n", > + " Access for 0x%08llx from %s\n", > se_cmd->se_tfo->fabric_name, > - unpacked_lun); > + unpacked_lun, > + se_sess->se_node_acl->initiatorname); You can do nacl->initiatorname. Do you also want add the name to the tmr case? It's probably not common, but the error message would be consistent. > return TCM_NON_EXISTENT_LUN; > } >