From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751211AbdFAMjc (ORCPT ); Thu, 1 Jun 2017 08:39:32 -0400 Received: from mga01.intel.com ([192.55.52.88]:15028 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751054AbdFAMjb (ORCPT ); Thu, 1 Jun 2017 08:39:31 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.39,279,1493708400"; d="scan'208";a="107948010" Date: Thu, 1 Jun 2017 08:47:26 -0400 From: Keith Busch To: Johannes Thumshirn Cc: Christoph Hellwig , Sagi Grimberg , Hannes Reinecke , maxg@mellanox.com, Linux NVMe Mailinglist , Linux Kernel Mailinglist Subject: Re: [PATCH v2 6/8] nvme: provide UUID value to userspace Message-ID: <20170601124726.GF2845@localhost.localdomain> References: <20170601111750.20880-1-jthumshirn@suse.de> <20170601111750.20880-7-jthumshirn@suse.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170601111750.20880-7-jthumshirn@suse.de> User-Agent: Mutt/1.7.1 (2016-10-04) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jun 01, 2017 at 01:17:48PM +0200, Johannes Thumshirn wrote: > Now that we have a way for getting the UUID from a target, provide it > to userspace as well. > > Unfortunately there is already a sysfs attribute called UUID which is > a misnomer as it holds the NGUID value. So instead of creating yet > another wrong name, create a new 'nguid' sysfs attribute for the > NGUID. For the UUID attribute add a check wheter the namespace has a > UUID assigned to it and return this or return the NGUID to maintain > backwards compatibility. This should give userspace a chance to catch > up. Sorry for the naming clash. Not sure why I didn't use the obvious name for this file in the first place. FWIW, tools should have been using the 'wwid' attribute, which returns either EUI64 or NGUID so a unique identifier can be gotten from a single file without checking for the existence of either. That should help not break backward compatibility, but I've no idea if anything actually relies on 'uuid' returning the NGUID.