Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp1809364ybh; Fri, 17 Jul 2020 01:31:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwnlrcmqJ3mT9d+WKwiUmQOCEbJ+RuVVWdXkI5Pe09zQV1x6rUMr4iNAFSn2NMm6QGoODF4 X-Received: by 2002:a17:906:c78f:: with SMTP id cw15mr7350105ejb.58.1594974699391; Fri, 17 Jul 2020 01:31:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594974699; cv=none; d=google.com; s=arc-20160816; b=ybVw5SmN6PL6Ngkmj/DhzspcXYe8mEhvKr/2ttrqhnjrNsEY3zsXxnIbx5Cx2m7WTN +LMS5fAk8d2VS0W7NHiOgRE7oMtwzOudW0QFdJKjche1MSrfftbcQ6ISduKXqU+yaqcm 1HSEoD3P+iWdqn9JiDZRpbzLKPnlVD6o39s63nLg99mwWVgzNTz5oIc3FUt8XoIwUyVj +RUl+nA+O1rz/tTMolQjfBnaetEg53hWbPOX6A+xy/WmCMT1IknfwfKrluhP4PtqL5MY l7u1ducjcroYw9MDNljmUdt/ngQ0hdQkqBAK2rXwRwTzQg4w/CVZYfs6ReN+cKfhnnYg 9zgA== 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:in-reply-to :mime-version:user-agent:date:message-id:from:references:cc:to :subject; bh=WIsmC/9ZxHlIRyls3NiZ84pZwbH5VFbQnC/W/AstNRM=; b=uVRKxYt4dOXEETgvRcV8IlthvKpaaOQ7udJX6RKjwe0wZLKJFCAUmHp1hPQBY0d1mu /wb+shWS4EPyH8C88Fxsch2mw3h4IAf3VgksU9Wg4SJ7FHjQ/DyAA0QKOY1QYC3v7iTX QwQonwk9ZFi1VPMLKR9YIhu1iBTqiL8McONXXGPYRu0/BGksQTAGuNHveT7UdKDC6CyO PNhKXT6pqU1t36Ol7Ytj/0ig8fmTOOklxlsQsh4FOkFsd74L7DpgCIR+E1qkaBpWAzZE sWWRM9X0G/6maUVz6anC7tKlh7G996IjBjW9ubrVBP+LZcnFQXxYcwEmKQZ+LL3IsAOo IYiw== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id cw24si4492041edb.177.2020.07.17.01.31.17; Fri, 17 Jul 2020 01:31:39 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726229AbgGQI3G (ORCPT + 99 others); Fri, 17 Jul 2020 04:29:06 -0400 Received: from szxga04-in.huawei.com ([45.249.212.190]:8315 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725864AbgGQI3F (ORCPT ); Fri, 17 Jul 2020 04:29:05 -0400 Received: from DGGEMS414-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 29A5AA7FFEC80B765914; Fri, 17 Jul 2020 16:29:03 +0800 (CST) Received: from [127.0.0.1] (10.174.178.16) by DGGEMS414-HUB.china.huawei.com (10.3.19.214) with Microsoft SMTP Server id 14.3.487.0; Fri, 17 Jul 2020 16:28:54 +0800 Subject: Re: [PATCH] [SCSI] libsas: add missing newline when printing 'enable' by sysfs To: John Garry , , CC: , , References: <1594971374-40210-1-git-send-email-wangxiongfeng2@huawei.com> <648c18d0-cc0a-f444-e774-e0938f697e90@huawei.com> From: Xiongfeng Wang Message-ID: <6381e401-53d3-3693-03ea-f709e95a3ec8@huawei.com> Date: Fri, 17 Jul 2020 16:28:53 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 MIME-Version: 1.0 In-Reply-To: <648c18d0-cc0a-f444-e774-e0938f697e90@huawei.com> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit X-Originating-IP: [10.174.178.16] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi John, On 2020/7/17 15:54, John Garry wrote: > On 17/07/2020 08:36, Xiongfeng Wang wrote: > > Hi, > > I think "scsi: scsi_transport_sas: " would be a better subject prefix, as this > is not libsas code. > >> When I cat sysfs file 'enable' below 'sas_phy', it displays as follows. >> It's better to add a newline for easy reading. >> >> [root@localhost ~]# cat >> /sys/devices/pci0000:00/0000:00:0d.0/0000:0f:00.0/host3/phy-3:2/sas_phy/phy-3:2/enable >> >> 1[root@localhost ~]# >> >> Signed-off-by: Xiongfeng Wang > > Apart from above, > Reviewed-by: John Garry Thanks for your review. I will send another version. Thanks, Xiongfeng > >> --- >>   drivers/scsi/scsi_transport_sas.c | 2 +- >>   1 file changed, 1 insertion(+), 1 deletion(-) >> >> diff --git a/drivers/scsi/scsi_transport_sas.c >> b/drivers/scsi/scsi_transport_sas.c >> index 182fd25..e443dee 100644 >> --- a/drivers/scsi/scsi_transport_sas.c >> +++ b/drivers/scsi/scsi_transport_sas.c >> @@ -563,7 +563,7 @@ static ssize_t do_sas_phy_enable(struct device *dev, >>   { >>       struct sas_phy *phy = transport_class_to_phy(dev); >>   -    return snprintf(buf, 20, "%d", phy->enabled); >> +    return snprintf(buf, 20, "%d\n", phy->enabled); >>   } >>     static DEVICE_ATTR(enable, S_IRUGO | S_IWUSR, show_sas_phy_enable, >> > > > .