Received: by 2002:ac0:98c7:0:0:0:0:0 with SMTP id g7-v6csp4930837imd; Tue, 30 Oct 2018 09:26:09 -0700 (PDT) X-Google-Smtp-Source: AJdET5f+UBl9khcLD7lju8re3if131qCt2OEN0UPDEa8bWcYwL+G8WED4f8M7wGvzBIPRV+S2WEL X-Received: by 2002:a17:902:6a4:: with SMTP id 33-v6mr1717945plh.325.1540916769458; Tue, 30 Oct 2018 09:26:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1540916769; cv=none; d=google.com; s=arc-20160816; b=ouBqK1wiKK/wZ17tsY1GSZtwbB5os8ZJFuUR1BN32yk6KHJJxzWURe20iEcqunUctA 6WlJf2hfVYiju6P7+HST9/CTVGXHp27fHJOIrmztvgPA+TmuwyBB9G7D+g3SaKuLEfTD 2nnbxPu9L7lhegCO+4f8ZhbSOc3Uj5RuaOLX7Lf4XGsA4iZSGgtQWayC1QWfxifwp1/0 QRPRH6e1qxQ1fNVrU4vRykQWvxkcS+OVLujdPk5G/JjAgUw47pxRkz38TyZaZeTcmxOl wmkPplVluWAnh9K0+K/+JfwXrTHHINfhTSFHLr5ulsx+UMFTYFHAjtz4S2PAIlzeiZ/q t4xg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=Sr8B7QSzrVwjRN0pvEw15ZDeRF0j8NquITusa0V0SFE=; b=vYgb3OqYLZG1s2Y3+He3YjYZJls/TtzJXgKAp1pa5kVsHqdu9A1PeXkJ6s1l99+YY2 6O5ADa/gFuvXIio4Zp47UgM8u0gepqPt6lm85/WfaohZ8lnOfzzTdqZFNV3G5Glw+eQ0 UIeZDgvrwiHIUTwtp7ffqHciT6WLZhHs1LvPpv3h1d1GTUbgN+PKpN6lRlIThKUBNCM1 oRyXI3IAOD1G4QzC2EmrBFAfDX31kzu3u73j5SxejVg9NmyQwLYClDVxUpGhLByy23tv MoyQyNVT+SC9eZelzs/Nu7ttH073sozPnxGCudhUA1uwmjLJZiS3z8Un6hDY/tMih7na ewrw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hO9G5QWZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v69si9047446pgd.284.2018.10.30.09.25.52; Tue, 30 Oct 2018 09:26:09 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hO9G5QWZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727323AbeJaBQf (ORCPT + 99 others); Tue, 30 Oct 2018 21:16:35 -0400 Received: from mail-wr1-f67.google.com ([209.85.221.67]:46855 "EHLO mail-wr1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726249AbeJaBQe (ORCPT ); Tue, 30 Oct 2018 21:16:34 -0400 Received: by mail-wr1-f67.google.com with SMTP id 74-v6so5072316wrb.13 for ; Tue, 30 Oct 2018 09:22:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=Sr8B7QSzrVwjRN0pvEw15ZDeRF0j8NquITusa0V0SFE=; b=hO9G5QWZv6kaF14JxG6OC83FkTnCmOejz5U3Hbh1rcXSjgTxqCDAJmGU6ugz1f5UFN 4IQd6+UTzrFWXgXkJQnH55uBw8uzA9jBY70maYRQ8E+WW01WRH+DbLlEbudrGCCQpxhL vZ+/MMZAp+wv7JeZzdHpsESWWSjCH0GWMK2+Q= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=Sr8B7QSzrVwjRN0pvEw15ZDeRF0j8NquITusa0V0SFE=; b=NtRhupzprTTWNLAu4ey+h4auG+awwIJvUa4tHQEqOvKba5iYOv8qv1m5tckv+xbpwz V65o6nz3WYF1l/PvKahHKpg4zHq0Xf8dyjYs5MzHMU/V2bfYUbuEOPl7WJZ4rMtosFEW EBOQeHR20+UqlvqkYQ2hRn2KtvFon43KK7ZfFvehyflgEMN5MyjN9sBEswQtcbPfyB2C GLl/HlEKK8VYeNaHNP8Ne0gN1MS0NXV0Sfk7lsW1cY34ss6XiS+ADuekPyz1uM7H+kSA ILfcYrnyZrPkrWFMmGvc5oiR7ZyqfdD8jrnVD8PVPOtcBRMTwcC6zJdSINq1HFQ1juQw qQPA== X-Gm-Message-State: AGRZ1gIKOoOQZdsSBzzXzo09W9H+r3lOW4Ujl/3gpuIqKQOdeIUpDH6q VRL9ZD/oTeoGUpT2L9bMd7HRDci3LBU= X-Received: by 2002:adf:f501:: with SMTP id q1-v6mr3566080wro.63.1540916544773; Tue, 30 Oct 2018 09:22:24 -0700 (PDT) Received: from [192.168.0.40] (12.152.88.92.rev.sfr.net. [92.88.152.12]) by smtp.googlemail.com with ESMTPSA id l140-v6sm32827675wmb.24.2018.10.30.09.22.23 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 30 Oct 2018 09:22:23 -0700 (PDT) Subject: Re: [PATCH 2/2] thermal: broadcom: constify thermal_zone_of_device_ops structure To: Julia Lawall , Markus Mayer Cc: kernel-janitors@vger.kernel.org, bcm-kernel-feedback-list@broadcom.com, Zhang Rui , Eduardo Valentin , Brian Norris , Gregory Fong , Florian Fainelli , linux-pm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org References: <1540912500-21941-1-git-send-email-Julia.Lawall@lip6.fr> <1540912500-21941-3-git-send-email-Julia.Lawall@lip6.fr> From: Daniel Lezcano Message-ID: Date: Tue, 30 Oct 2018 17:22:22 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 MIME-Version: 1.0 In-Reply-To: <1540912500-21941-3-git-send-email-Julia.Lawall@lip6.fr> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 30/10/2018 16:15, Julia Lawall wrote: > The thermal_zone_of_device_ops structure can be const as it is only > passed as the last argument of thermal_zone_of_sensor_register > and the corresponding parameter is declared as const. > > Done with the help of Coccinelle. > > Signed-off-by: Julia Lawall Reviewed-by: Daniel Lezcano > --- > > Unrelated to this change, is there a reason not to use > devm_thermal_zone_of_sensor_register? Agree, it would make sense to use the devm* version. > drivers/thermal/broadcom/brcmstb_thermal.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff -u -p a/drivers/thermal/broadcom/brcmstb_thermal.c b/drivers/thermal/broadcom/brcmstb_thermal.c > --- a/drivers/thermal/broadcom/brcmstb_thermal.c > +++ b/drivers/thermal/broadcom/brcmstb_thermal.c > @@ -299,7 +299,7 @@ static int brcmstb_set_trips(void *data, > return 0; > } > > -static struct thermal_zone_of_device_ops of_ops = { > +static const struct thermal_zone_of_device_ops of_ops = { > .get_temp = brcmstb_get_temp, > .set_trips = brcmstb_set_trips, > }; > -- Linaro.org │ Open source software for ARM SoCs Follow Linaro: Facebook | Twitter | Blog