Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753830AbdIHJbG (ORCPT ); Fri, 8 Sep 2017 05:31:06 -0400 Received: from mail-wm0-f54.google.com ([74.125.82.54]:46748 "EHLO mail-wm0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752434AbdIHJbE (ORCPT ); Fri, 8 Sep 2017 05:31:04 -0400 X-Google-Smtp-Source: AOwi7QDnU3vt6c9czV27DQv3r0+p7XdU8tNQze2xusQtNS1mpyXHIbNjjHQwZFZdUEvMCkifgAs6cg== Subject: Re: [PATCH V2 06/13] thermal/drivers/hisi: Remove pointless lock To: Eduardo Valentin Cc: rui.zhang@intel.com, linux-pm@vger.kernel.org, kevin.wangtao@linaro.org, leo.yan@linaro.org, linux-kernel@vger.kernel.org References: <1504554972-2624-1-git-send-email-daniel.lezcano@linaro.org> <1504554972-2624-6-git-send-email-daniel.lezcano@linaro.org> <20170908031641.GD2755@localhost.localdomain> From: Daniel Lezcano Message-ID: <51bcc9ba-513f-ea7f-6780-6c3c703f63ab@linaro.org> Date: Fri, 8 Sep 2017 11:31:00 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: <20170908031641.GD2755@localhost.localdomain> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 855 Lines: 20 On 08/09/2017 05:16, Eduardo Valentin wrote: > On Mon, Sep 04, 2017 at 09:56:05PM +0200, Daniel Lezcano wrote: >> The threaded interrupt inspect the sensors structure to look in the temp >> threshold field, but this field is read-only in all the code, except in the >> probe function before the threaded interrupt is set. In other words there >> is not race window in the threaded interrupt when reading the field value. > > > Sure? Not even if you have a userspace process read the zone temp via > sysfs and the polling workqueue reading the temp too? They are both read-only operations. There is no write-read race. -- Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog