From patchwork Thu Nov 29 01:01:50 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Disseldorp X-Patchwork-Id: 10703743 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 77A92679F for ; Thu, 29 Nov 2018 01:02:08 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 694CE2E172 for ; Thu, 29 Nov 2018 01:02:08 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5D11C2E1A0; Thu, 29 Nov 2018 01:02:08 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 47F462E172 for ; Thu, 29 Nov 2018 01:02:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726724AbeK2MFi (ORCPT ); Thu, 29 Nov 2018 07:05:38 -0500 Received: from mx2.suse.de ([195.135.220.15]:39790 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726297AbeK2MFh (ORCPT ); Thu, 29 Nov 2018 07:05:37 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 823B1ADE4; Thu, 29 Nov 2018 01:02:04 +0000 (UTC) From: David Disseldorp To: target-devel@vger.kernel.org Cc: hare@suse.com, lduncan@suse.com, cvubrugier@fastmail.fm, Mike Christie , martin.petersen@oracle.com, linux-scsi@vger.kernel.org Subject: [PATCH v4 0/7] target: user configurable T10 Vendor ID Date: Thu, 29 Nov 2018 02:01:50 +0100 Message-Id: <20181129010157.12687-1-ddiss@suse.de> X-Mailer: git-send-email 2.13.7 Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This patchset allows for the modification of the T10 Vendor Identification string returned in the SCSI INQUIRY response, via the target/core/$backstore/$name/wwn/vendor_id ConfigFS path. Changes since v3: - perform explicit null termination of t10_wwn vendor, model and revision fields. - replace field dump for-loops Changes since v2: - https://www.spinics.net/lists/target-devel/msg10720.html - Support eight byte vendor ID strings - Split out consistent INQUIRY data padding as a separate patch - Drop t10_wwn.model buffer print fix, already upstream Changes since v1: - https://www.spinics.net/lists/target-devel/msg10545.html - Rebase against nab's for-next branch, which includes Christoph's configfs API changes. Bart Van Assche (1): target: use printf width specifier for t10_wwn field dumps David Disseldorp (6): target: use consistent left-aligned ASCII INQUIRY data target: consistently null-terminate t10_wwn.vendor target: consistently null-terminate t10_wwn.model target: consistently null-terminate t10_wwn.revision target: add device vendor_id configfs attribute target: remove hardcoded T10 Vendor ID in INQUIRY response drivers/target/target_core_configfs.c | 56 +++++++++++++++++++++++++-- drivers/target/target_core_device.c | 47 ++++++++-------------- drivers/target/target_core_pscsi.c | 16 +++++--- drivers/target/target_core_spc.c | 20 +++++++--- drivers/target/target_core_stat.c | 32 ++++----------- include/target/target_core_base.h | 14 +++++-- 6 files changed, 114 insertions(+), 71 deletions(-)