From patchwork Tue Oct 25 12:39:30 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "yekai (A)" X-Patchwork-Id: 10753 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp985130wru; Tue, 25 Oct 2022 05:50:00 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5YvvUzd66OZXYVlUa4LR7YJuRed0WqkNUMXLd8HNJSE+Aukh2aWuvJLpS5owW4QW1fsEJs X-Received: by 2002:a17:90b:1c82:b0:1ee:eb41:b141 with SMTP id oo2-20020a17090b1c8200b001eeeb41b141mr45945210pjb.143.1666702200214; Tue, 25 Oct 2022 05:50:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666702200; cv=none; d=google.com; s=arc-20160816; b=TJqodiHI5DTgXih/EXyKKPdzUcY6CzEaQ+AJ//ERDu5BvYjOA7FfJnSMqbGm5hAxXM vybt6rQorZ2nvcCIwbFrpCXlBjsRWXMDDneWdqLjCoMX/wH5JgNS1ZhRDAMz+xhQWway wDv2fc7q0AEh8btlaB0nTLMkj0xfqNtxdK3qU2aKiYUbs+bodws/CcZmX7wC7rntH/Cb R5EAx4EIgKhc9vBPT5KmCI+10GqyByT/z+4pDH2sybj+Knh7fNNyO5KyRbYqRNz3OPUo /W3RROEu4PenNn5VBAIidPLLzj6eTZWXSWigonkFk48D9tac7D7nEddHlAAD63yZCBS8 tn2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:to:from; bh=TnVBRfFRADiZwr+rjiCqW6rqnKA1UGqiut+nUrzHa0Y=; b=wdXfSkyj8KBFODo8qvpAol3zTBHswAqpfu/vTIZSrAkVTsiKDTFxL1W+RecfM/j6MN rBFiqUTOmuoPm2GJbfv+4CbWkZzwQ4t0c5X5ldvQYfUggqUmOJJfgZLGyUcB3ZGYfbZj qlyx14F31005dY2HseWi1RN74F6wCN1S+mOaL4TPzXZ83cVxWUQkD9lClM8NT2UWoUBL FkTHmYR+7pYJQXeDNSbE94eusPuZvM9FurZl2L/qVX8fh+6Yxxx/Nn7wsWEhPdA1x32w G6Nb3/uqI+H/10Afv07LPwV9rqhPKB17nnJSlITX35MCgcDuI0cZjUXTolCZuVi2c61w bFiQ== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e8-20020a635448000000b0046ecd36adbasi3002772pgm.635.2022.10.25.05.49.46; Tue, 25 Oct 2022 05:50: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; 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=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232333AbiJYMr7 (ORCPT + 99 others); Tue, 25 Oct 2022 08:47:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43820 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232286AbiJYMrm (ORCPT ); Tue, 25 Oct 2022 08:47:42 -0400 Received: from szxga08-in.huawei.com (szxga08-in.huawei.com [45.249.212.255]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0480519299B for ; Tue, 25 Oct 2022 05:45:25 -0700 (PDT) Received: from dggpeml500021.china.huawei.com (unknown [172.30.72.54]) by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4MxWkP6L7Gz15Lxv; Tue, 25 Oct 2022 20:40:29 +0800 (CST) Received: from dggpeml100012.china.huawei.com (7.185.36.121) by dggpeml500021.china.huawei.com (7.185.36.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Tue, 25 Oct 2022 20:45:21 +0800 Received: from huawei.com (10.67.165.24) by dggpeml100012.china.huawei.com (7.185.36.121) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Tue, 25 Oct 2022 20:45:21 +0800 From: Kai Ye To: , , , , , , Subject: [PATCH v9 2/3] Documentation: add a isolation strategy sysfs node for uacce Date: Tue, 25 Oct 2022 12:39:30 +0000 Message-ID: <20221025123931.42161-3-yekai13@huawei.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20221025123931.42161-1-yekai13@huawei.com> References: <20221025123931.42161-1-yekai13@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.67.165.24] X-ClientProxiedBy: dggems702-chm.china.huawei.com (10.3.19.179) To dggpeml100012.china.huawei.com (7.185.36.121) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747663926336489657?= X-GMAIL-MSGID: =?utf-8?q?1747663926336489657?= Update documentation describing sysfs node that could help to configure isolation strategy for users in the user space. And describing sysfs node that could read the device isolated state. Signed-off-by: Kai Ye --- Documentation/ABI/testing/sysfs-driver-uacce | 27 ++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/Documentation/ABI/testing/sysfs-driver-uacce b/Documentation/ABI/testing/sysfs-driver-uacce index 08f2591138af..50737c897ba3 100644 --- a/Documentation/ABI/testing/sysfs-driver-uacce +++ b/Documentation/ABI/testing/sysfs-driver-uacce @@ -19,6 +19,33 @@ Contact: linux-accelerators@lists.ozlabs.org Description: Available instances left of the device Return -ENODEV if uacce_ops get_available_instances is not provided +What: /sys/class/uacce//isolate_strategy +Date: Oct 2022 +KernelVersion: 6.1 +Contact: linux-accelerators@lists.ozlabs.org +Description: (RW) Configure the frequency size for the hardware error + isolation strategy. This unit is the number of times. Number + of occurrences in a period, also means threshold. If the number + of device pci AER error exceeds the threshold in a time window, + the device is isolated. This size is a configured integer value. + The default is 0. The maximum value is 65535. + + In the hisilicon accelerator engine, first we will + time-stamp every slot AER error. Then check the AER error log + when the device AER error occurred. if the device slot AER error + count exceeds the preset the number of times in one hour, the + isolated state will be set to true. So the device will be + isolated. And the AER error log that exceed one hour will be + cleared. + +What: /sys/class/uacce//isolate +Date: Oct 2022 +KernelVersion: 6.1 +Contact: linux-accelerators@lists.ozlabs.org +Description: (R) A sysfs node that read the device isolated state. The value 1 + means the device is unavailable. The 0 means the device is + available. + What: /sys/class/uacce//algorithms Date: Feb 2020 KernelVersion: 5.7