From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753601AbcFTJ0P (ORCPT ); Mon, 20 Jun 2016 05:26:15 -0400 Received: from mga02.intel.com ([134.134.136.20]:36419 "EHLO mga02.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753048AbcFTJ0E convert rfc822-to-8bit (ORCPT ); Mon, 20 Jun 2016 05:26:04 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.26,497,1459839600"; d="scan'208";a="979496881" From: "Baranowska, BeataX" To: Wolfram Sang , "Hunter, Adrian" CC: "ulf.hansson@linaro.org" , "aisheng.dong@nxp.com" , "wsa+renesas@sang-engineering.com" , "gwendal@chromium.org" , "chaotian.jing@mediatek.com" , "linux-mmc@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "Jarosz, SebastianX" , "Dong, Chuanxiao" Subject: RE: [PATCH] mmc: Change the enhanced area related sysfs output format Thread-Topic: [PATCH] mmc: Change the enhanced area related sysfs output format Thread-Index: AQHRxhmdYFXz5JkWj0yWbR1Fi+Xz85/orZ2AgAAGjoCAACLgAIAJN0OQ Date: Mon, 20 Jun 2016 09:25:59 +0000 Message-ID: References: <1465893186-6399-1-git-send-email-beatax.baranowska@intel.com> <20160614101242.GA1603@katana> <575FDE1B.2090206@intel.com> <20160614124100.GA1608@katana> In-Reply-To: <20160614124100.GA1608@katana> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [163.33.239.182] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > -----Original Message----- > From: Wolfram Sang [mailto:wsa@the-dreams.de] > Sent: Tuesday, June 14, 2016 2:41 PM > To: Hunter, Adrian > Cc: Baranowska, BeataX ; > ulf.hansson@linaro.org; aisheng.dong@nxp.com; wsa+renesas@sang- > engineering.com; gwendal@chromium.org; chaotian.jing@mediatek.com; > linux-mmc@vger.kernel.org; linux-kernel@vger.kernel.org; Jarosz, > SebastianX ; Dong, Chuanxiao > > Subject: Re: [PATCH] mmc: Change the enhanced area related sysfs output > format > > On Tue, Jun 14, 2016 at 01:36:11PM +0300, Adrian Hunter wrote: > > On 14/06/16 13:12, Wolfram Sang wrote: > > > On Tue, Jun 14, 2016 at 10:33:06AM +0200, Beata Baranowska wrote: > > >> From: Chuanxiao Dong > > >> > > >> When the enhanced area feature was not enabled, the related sysfs > > >> will have -EINVAL(-22) value, so change the sysfs output format to > > >> display the correct value. > > >> > > >> Signed-off-by: Chuanxiao Dong > > > > > > What about introducing attribute_group an use the is_visible > > > callback there, so they won't get displayed at all? > > > > > > > Except that it is an ABI: > > > > Documentation/ABI/testing/sysfs-devices-mmc > > And broken ever since if this patch is needed... that being said, I don't really > have a strong opinion on my suggestion. I see the file is out there for >5 > years. When functionality was implemented for situation when enhanced area is not enabled the value 0 was being used. After someone's suggestion 0 was changed into -ENIVAL. Variables are still unsigned. This patch was to change displaying part from unsigned into signed but you are right it should be investigated. I think we could: - use 0 instead of -ENIVAL and then leave variables unsigned as it is, - change variables and printfs into signed - or leave it unchanged as the file is out there for >5 Please let me know your suggestions if the update of the patch is appreciated. Beata