Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp4778305pxu; Wed, 21 Oct 2020 05:18:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwZ2KROvLDA4tWL2j1ZOfbqVq0m+ejwBMfl4/MZZLmgji9AoALSD+1xU6NmCfLTfaiZHckg X-Received: by 2002:a05:6402:3089:: with SMTP id de9mr2887017edb.368.1603282700138; Wed, 21 Oct 2020 05:18:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603282700; cv=none; d=google.com; s=arc-20160816; b=vsd3dNEfXCZEQqKpo2ZmpqAfwFAESq10wrWCfDKhx6xcMqoTIuS+lSz1ayw0X6CrxP 4O/w4jkVn1tKMhpYl7DpwqKMIMPyeAEjkiKPqzpJ9M1Y81n7kjJ0zxSzLzQNeDCRibvf XWrL/VtfuHB3ZLIBOZpnA5Bqt2+mrACmj3KaKWCsjrodwxU4hlzN6T/RFUruGrHrny0/ pu3chKbMxCKBYLomFf0YPThjsnibz3h0hVu5wBOyPlb8kMrJ5uzWOgvD4DsPQ0Yc8YUC sgS0yf6g3X6DNU1IPz4UA9povBuoH6/OVsWcdxxBYakS3YN+tuNRbyO8yXOZdYVVazp8 qU4A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:to:from; bh=4wupcXhByJRTUy7Vz/YtH73qcStJleNdJBMY4eaqjSs=; b=wj/2oeuMemAivja8S0KqgkF5oALOrJKZ+aXxjTy3JUVW2loixIFm04+4QT+C8qWTbe VePRxT9qtZLrr+gIXl1q/N4AzU2qwy8Jyv2NtgjJ40n2VdzuQSOXl9tPADLV2E7SKs2Y No0i13h7WU4+NjUilefOjhZTbQYj4f3p0SgpCuhezlg8UlLScklRlRqKaiiY6NwkmIz6 krNRIxm/qghjQQ3OINlKavYdgruZ10tTReYgBK4+NFNcYpiBCS5Rpf7VQVag8izYfyty juNRovzSIiuo0vr0lfygsZlJTzwBTHp3ldYs9bp3HEq7RviGzB3LONmK2EbKXMsWj1oB VcwQ== 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 r11si1221735edy.18.2020.10.21.05.17.57; Wed, 21 Oct 2020 05:18:20 -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 S2411521AbgJUDEy (ORCPT + 99 others); Tue, 20 Oct 2020 23:04:54 -0400 Received: from szxga07-in.huawei.com ([45.249.212.35]:37502 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2406694AbgJUDEy (ORCPT ); Tue, 20 Oct 2020 23:04:54 -0400 Received: from DGGEMS404-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id A26D780450BD7FB833D0; Wed, 21 Oct 2020 11:04:51 +0800 (CST) Received: from localhost.localdomain (10.69.192.56) by DGGEMS404-HUB.china.huawei.com (10.3.19.204) with Microsoft SMTP Server id 14.3.487.0; Wed, 21 Oct 2020 11:04:46 +0800 From: Tian Tao To: , , , , , , Subject: [PATCH] thermal: replace spin_lock_irqsave by spin_lock in hard IRQ Date: Wed, 21 Oct 2020 11:05:30 +0800 Message-ID: <1603249530-25218-1-git-send-email-tiantao6@hisilicon.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.69.192.56] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The code has been in a irq-disabled context since it is hard IRQ. There is no necessity to do it again. Signed-off-by: Tian Tao --- drivers/thermal/rcar_thermal.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/thermal/rcar_thermal.c b/drivers/thermal/rcar_thermal.c index 5c2a13b..6ae757d 100644 --- a/drivers/thermal/rcar_thermal.c +++ b/drivers/thermal/rcar_thermal.c @@ -409,16 +409,15 @@ static irqreturn_t rcar_thermal_irq(int irq, void *data) { struct rcar_thermal_common *common = data; struct rcar_thermal_priv *priv; - unsigned long flags; u32 status, mask; - spin_lock_irqsave(&common->lock, flags); + spin_lock(&common->lock); mask = rcar_thermal_common_read(common, INTMSK); status = rcar_thermal_common_read(common, STR); rcar_thermal_common_write(common, STR, 0x000F0F0F & mask); - spin_unlock_irqrestore(&common->lock, flags); + spin_unlock(&common->lock); status = status & ~mask; -- 2.7.4