Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp1503644pxa; Sun, 16 Aug 2020 00:25:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxDFWwEkq3xrmziXl3fld4dwMeLvU1vO+pgGEYXgBAGEklIrISYFWbnxPIGcbc2x9qbiqwL X-Received: by 2002:a05:6402:2379:: with SMTP id a25mr9756263eda.180.1597562739758; Sun, 16 Aug 2020 00:25:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597562739; cv=none; d=google.com; s=arc-20160816; b=u1CQhq4nVtH5zOaPiyyGQp3jG88zMnbharo19l1+SN9QrD4cl9c5Q7roVPY2nabSGb 4To5HGf8iq7bVf1JaeZpoVGNV0YLSwttLVvkwmMZ8JkY4QNPSJ1bo1WeWkIM+bIT7tq/ gzyAv+otmMQbFyHDmWUr/IsE32oxwMyAtsRl/iT7CyWLMvxkdvB1ZQyY0/iwI3SxAlbx IY88gjrpk/pk4cdgN4JXwsuqVnjdGyfSJbv89M6c/jzwyf9NQpA79WrT+tJ51i5qiG/k 55Q0A3tSTJUsmSuNJvWOu3nE0dEAy+7ds+ANx5mPVK7L7JZr7LN1yI5vmsk1KlBBkJ4S 0b+Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from; bh=Qd58ZYEUA3lDdccMP/Q8wMNKd0c5wFjrmRhfhuKybZI=; b=pmM5Gq7MKJ+MxpNkbWuEQ/D6IggjQujH0KH8O05EgaINP7Kc+UUVB6svLTtqqWsl4j k+bJ7yaJr49UxrVHRbfPCnk/Wj836GAEDOGkIj2HyVjkMr3D0SfdGKxNZFwM7dtLasD9 cOZ9LMfV1TwKv2qqFmWc/qtNYyTsuS0e4WxM/LPUHtXkA01VTsAsr87UW6hwtqxo94Bv 88UgZWl8nGCh4yFi/EF2EOb9CXSeNkR0Jsew8HPSODKWrC5m+sanZitaPqi4jAwaU+aD /huGxueyuZl9y/TY4rRjlWvjwPussKL/RqdIwyQb9YGrUig74gR60BGyLFe/CHcFXtMf l9RQ== 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 a13si8461792edv.545.2020.08.16.00.25.17; Sun, 16 Aug 2020 00:25: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 S1729552AbgHPBoX (ORCPT + 99 others); Sat, 15 Aug 2020 21:44:23 -0400 Received: from szxga07-in.huawei.com ([45.249.212.35]:33844 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729388AbgHPBoR (ORCPT ); Sat, 15 Aug 2020 21:44:17 -0400 Received: from DGGEMS411-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 204008EB390444B5516F; Sat, 15 Aug 2020 17:58:34 +0800 (CST) Received: from localhost.localdomain (10.69.192.56) by DGGEMS411-HUB.china.huawei.com (10.3.19.211) with Microsoft SMTP Server id 14.3.487.0; Sat, 15 Aug 2020 17:58:23 +0800 From: Yang Shen To: , CC: , , , Subject: [PATCH v5 03/10] crypto: hisilicon/qm - fix print frequence in hisi_qp_send Date: Sat, 15 Aug 2020 17:56:10 +0800 Message-ID: <1597485377-2678-4-git-send-email-shenyang39@huawei.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1597485377-2678-1-git-send-email-shenyang39@huawei.com> References: <1597485377-2678-1-git-send-email-shenyang39@huawei.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.69.192.56] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Requests will be sent continuously as resetting, which will cause 'printk' flooding. Using 'dev_info_ratelimited' can solve this problem well. Fixes: b67202e8ed30("crypto: hisilicon/qm - add state machine for QM") Signed-off-by: Yang Shen Reviewed-by: Zhou Wang --- drivers/crypto/hisilicon/qm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/crypto/hisilicon/qm.c b/drivers/crypto/hisilicon/qm.c index 1e49931..95a1b6c 100644 --- a/drivers/crypto/hisilicon/qm.c +++ b/drivers/crypto/hisilicon/qm.c @@ -1984,7 +1984,7 @@ int hisi_qp_send(struct hisi_qp *qp, const void *msg) if (unlikely(atomic_read(&qp->qp_status.flags) == QP_STOP || atomic_read(&qp->qm->status.flags) == QM_STOP || qp->is_resetting)) { - dev_info(&qp->qm->pdev->dev, "QP is stopped or resetting\n"); + dev_info_ratelimited(&qp->qm->pdev->dev, "QP is stopped or resetting\n"); return -EAGAIN; } -- 2.7.4