Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp2160948rwb; Mon, 19 Sep 2022 00:01:00 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6qde37cTyC/iCOzkSmyncF5Ujc3GfegbXxQSdTzSf3GsbWZNGPhj4F1CAJ1UYUS+9+sMYo X-Received: by 2002:a17:90b:3d91:b0:202:dc14:16c0 with SMTP id pq17-20020a17090b3d9100b00202dc1416c0mr30244496pjb.44.1663570860532; Mon, 19 Sep 2022 00:01:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663570860; cv=none; d=google.com; s=arc-20160816; b=hV0uKOhk/CiC4Z/5kL5NRAmUPGnHoFhTb6xjsQ12BVsjc+YlibFL0FSLnYDXvdryWG AsUToBchQI2LdymwotZ9nwlOEgTyluxfbSsmqJ9H2Co/2cVLZvn0ZiB+IozIuMzX+8xT gIhLiQqh/qLvIYe1Nl8ryW8QSR0UY3IFOoUkOvSoHBMLiP4kfZtoi/OW9wgnVw6T6HTw VjpUtXMwk3X7ea9I56NnYCWYrenDXNt8cqV8Ogz6Je/TBO4svR3XLuZeJ3XtY3Q/518C /g/quDB4slb9Ehm+9A2+K5p5uaeBzo8AOWtuQ0sAoLz8+GRxX6yP/NaUUUMipE4JhjNW NNqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:dlp-filter:cms-type :content-transfer-encoding:mime-version:in-reply-to:message-id :subject:cc:to:from:date:dkim-signature:dkim-filter; bh=FtAqeLE9eLSYZ70k5z3LQzvAizj5vQGBIwHoZe7dClI=; b=DidTcnoVsUmG5Xf+nhHlRTPIgRfV0xnAxCe6C/Od/5Y5VuW+pyztSYL60zajWVM9rR IX/NecsBP/EMAhHtmCqK3nyqX181/svGHLUtmNzZrkoa8+cfZuV4b1mioedm58GfrQEX SRotDWmsJRN0vHQy6WCrT738tBCvmepICt8IvsAVl2yGFkMrYuG59BzXByVyifrIGxKy NrN+4p9eUtCruC81+v8gsto2zxBSrK1bgma+/au/k97pz0oZxQ2Pa4FvGhq0PnLIIwwY /cYmhXidLE69nxFven6D4t7gtZc28zJKhJ+ZcR5qhsmI1gxYbRbTM0Cf0fP2QQ8kkMGT m/kQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=gWVRqtQl; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a4-20020a63e844000000b0042c011b9ad5si30613021pgk.871.2022.09.19.00.00.48; Mon, 19 Sep 2022 00:01:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=gWVRqtQl; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229698AbiISGoa (ORCPT + 99 others); Mon, 19 Sep 2022 02:44:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50688 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229453AbiISGo0 (ORCPT ); Mon, 19 Sep 2022 02:44:26 -0400 Received: from mailout2.samsung.com (mailout2.samsung.com [203.254.224.25]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 537B51C92F for ; Sun, 18 Sep 2022 23:44:22 -0700 (PDT) Received: from epcas1p3.samsung.com (unknown [182.195.41.47]) by mailout2.samsung.com (KnoxPortal) with ESMTP id 20220919064417epoutp02c8f71b8095449c3fb13a688f154fe664~WL-i09-qI0895008950epoutp02Y for ; Mon, 19 Sep 2022 06:44:17 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.samsung.com 20220919064417epoutp02c8f71b8095449c3fb13a688f154fe664~WL-i09-qI0895008950epoutp02Y DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1663569857; bh=FtAqeLE9eLSYZ70k5z3LQzvAizj5vQGBIwHoZe7dClI=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=gWVRqtQl8/w+8m4D4gZesjWaxaB10LgQFq0dJP0gBoVPPBNPKxK3njuB1wHJJETrh 52QRvNPTJi+QanLrndthmdJl/mAr3Y2inxa61NLOr50CROLk9BAWzFrGq8krH7vtSI M6GLpG3T4qr3LIzykDNZtyQ8Mu1gHnA5Q7cWjbB8= Received: from epsnrtp1.localdomain (unknown [182.195.42.162]) by epcas1p1.samsung.com (KnoxPortal) with ESMTP id 20220919064417epcas1p18ecb172d874ed47868bdfedf8d7c92f2~WL-iWJPkb1812318123epcas1p1p; Mon, 19 Sep 2022 06:44:17 +0000 (GMT) Received: from epsmges1p4.samsung.com (unknown [182.195.36.132]) by epsnrtp1.localdomain (Postfix) with ESMTP id 4MWFX00yYgz4x9Q7; Mon, 19 Sep 2022 06:44:16 +0000 (GMT) Received: from epcas1p4.samsung.com ( [182.195.41.48]) by epsmges1p4.samsung.com (Symantec Messaging Gateway) with SMTP id E5.4A.07691.FBF08236; Mon, 19 Sep 2022 15:44:16 +0900 (KST) Received: from epsmtrp2.samsung.com (unknown [182.195.40.14]) by epcas1p2.samsung.com (KnoxPortal) with ESMTPA id 20220919064415epcas1p2f9dc0241afb4b9d413bb2244d6608dce~WL-hH5CrD0346003460epcas1p2V; Mon, 19 Sep 2022 06:44:15 +0000 (GMT) Received: from epsmgms1p2.samsung.com (unknown [182.195.42.42]) by epsmtrp2.samsung.com (KnoxPortal) with ESMTP id 20220919064415epsmtrp2f8b8ef36f7d75e48e84cfc870d57e7bf~WL-hHBmo50522905229epsmtrp2F; Mon, 19 Sep 2022 06:44:15 +0000 (GMT) X-AuditID: b6c32a38-8d6dba8000021e0b-4b-63280fbfe6b2 Received: from epsmtip1.samsung.com ( [182.195.34.30]) by epsmgms1p2.samsung.com (Symantec Messaging Gateway) with SMTP id F2.6A.18644.FBF08236; Mon, 19 Sep 2022 15:44:15 +0900 (KST) Received: from jiho-chu04.tn.corp.samsungelectronics.net (unknown [10.113.112.236]) by epsmtip1.samsung.com (KnoxPortal) with ESMTPA id 20220919064415epsmtip13662b953a5833c00edddb3a6739ed64b~WL-g0yUSF2542525425epsmtip1O; Mon, 19 Sep 2022 06:44:15 +0000 (GMT) Date: Mon, 19 Sep 2022 15:44:15 +0900 From: Jiho Chu To: Greg KH Cc: arnd@arndb.de, ogabbay@kernel.org, krzysztof.kozlowski@linaro.org, broonie@kernel.org, linux-kernel@vger.kernel.org, yelini.jeong@samsung.com, myungjoo.ham@samsung.com Subject: Re: [PATCH v2 07/13] trinity: Add sysfs module Message-Id: <20220919154415.23457c66c2e2a76d02267af2@samsung.com> In-Reply-To: X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.30; i686-pc-mingw32) Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprFJsWRmVeSWpSXmKPExsWy7bCmge4Bfo1kg/ddzBZ/Jx1jt5j68Amb RfPi9WwW77t3M1vsfb2V3eLyrjlsFrcbV7BZ7Ov5yGjxfNp1FgdOj9+/JjF6bFrVyeZx59oe No/9c9ewe/RtWcXo8XmTXABbVLZNRmpiSmqRQmpecn5KZl66rZJ3cLxzvKmZgaGuoaWFuZJC XmJuqq2Si0+ArltmDtBVSgpliTmlQKGAxOJiJX07m6L80pJUhYz84hJbpdSClJwC0wK94sTc 4tK8dL281BIrQwMDI1OgwoTsj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vZrbY+3oru8XlXXPYLG43rmCz2NfzkdHi+bTrLA6cHr9/TWL02LSqk83jzrU9 bB77565h9+jbsorR4/MmuQC2KC6blNSczLLUIn27BK6MV9N+sBZMFKqY8OYWcwNjP18XIyeH hICJxPW721m7GLk4hAR2MEqcPXiKGSIhIbHp3nIgmwPIFpY4fLgYoqaNSWLT1UdgNSwCqhIH Wg+xgthsQPbMGWvYQWwRAQ2Jl0dvsYDYzALrGSX2L1MHsYUFzCWunV0EVs8r4Cjx7lEDI4jN KaAp8frYQiaIBQ8YJX7d7meCOMJC4m7PClaQI3gFBCX+7hCGmKkl8fAXzHx5ie1v5zBPYBSc hVA1C0nVLCRVCxiZVzFKphYU56bnFhsWGOWllusVJ+YWl+al6yXn525iBEeIltYOxj2rPugd YmTiYDzEKMHBrCTCq+qpkizEm5JYWZValB9fVJqTWnyIUZqDRUmc90LXyXghgfTEktTs1NSC 1CKYLBMHp1QDU7BT7XrGliPhyxiSTp7Yas71mv+G6DzXvw9Uv+hvTO/bvmnGr/tzHT6J/JAV +9t6MGDh46pZH/+zSyScdZI4vWuDtktIxTpB1WkGu9UylvUJS7mI93P8vbNis2noySV+yZ/v mM5Y78h8fmb292DvawuWN/lOa3FbP3PZlvc2QRfyjMvV9j2SMGkqCMqwSLzAwWpvcXOdQN0D xraeBRPrJn5/4TZ/51WvS+8akzgTUhv1C73Tb3PdyjjrH7JadNummB8Sx1VulukIZ75zLpyf 97wg9e7npaGmmqcaGLY1X5pQrWQr35D16AgH872sFVcUP59YYej4pDftTYr34Y5lGeG8dyeY PGGYWfm3/9unf0osxRmJhlrMRcWJAP19p9L/AgAA X-CMS-MailID: 20220919064415epcas1p2f9dc0241afb4b9d413bb2244d6608dce X-Msg-Generator: CA Content-Type: text/plain; charset="utf-8" X-Sendblock-Type: SVC_REQ_APPROVE CMS-TYPE: 101P DLP-Filter: Pass X-CFilter-Loop: Reflected X-CMS-RootMailID: 20220917072357epcas1p485a1cdcb71cc01274db1c8d00aec197c References: <20220917072356.2255620-1-jiho.chu@samsung.com> <20220917072356.2255620-8-jiho.chu@samsung.com> X-Spam-Status: No, score=-8.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_MED,SPF_HELO_PASS,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, 18 Sep 2022 12:33:06 +0200 Greg KH wrote: > On Sat, Sep 17, 2022 at 04:23:50PM +0900, Jiho Chu wrote: > > This patch includes sysfs interfaces. > > > > sysfs interface provides NPU's internal statistics, status and control > > attribes. > > > > The sysfs information provided by the Trinity are: > > - IDU version > > - profiling result > > - allocated debugfs buffer > > > > The control attributes are including: > > - initialize profile operation > > - NPU control (suspend/resume/stop) > > > > Signed-off-by: Jiho Chu > > Signed-off-by: Yelin Jeong > > Signed-off-by: Dongju Chae > > Signed-off-by: MyungJoo Ham > > --- > > .../ABI/testing/sysfs-driver-trinity | 55 ++ > > drivers/misc/trinity/Makefile | 1 + > > drivers/misc/trinity/trinity_sysfs.c | 667 ++++++++++++++++++ > > 3 files changed, 723 insertions(+) > > create mode 100644 Documentation/ABI/testing/sysfs-driver-trinity > > create mode 100644 drivers/misc/trinity/trinity_sysfs.c > > > > diff --git a/Documentation/ABI/testing/sysfs-driver-trinity b/Documentation/ABI/testing/sysfs-driver-trinity > > new file mode 100644 > > index 000000000000..754e6f36a1dc > > --- /dev/null > > +++ b/Documentation/ABI/testing/sysfs-driver-trinity > > @@ -0,0 +1,55 @@ > > +What: /sys/devices/platform/trinity/*.triv2/debug/debugfs_max > > +Date: July 2022 > > +KernelVersion: 5.19-rc8 > > +Contact: Jiho Chu > > +Description: Shows current allocated debugfs entry size. > > + Note that, Writing max entry size allocates NPU's hardware > > + memory for debugfs entries. > > Why are debugfs things being mentioned in sysfs entries? > > That's not needed, nor is it allowed, sorry. > > Please put all debugfs stuff in debugfs. > > Also, sysfs is "one value per file", you violate that in lots of ways > with this patch. Please fix all of that, and use the sysfs_emit() calls > instead of snprintf() for your sysfs show calls. > > thanks, > > greg k-h > Thanks for checking. I'll fix sysfs entries. Best regards, Jiho Chu