From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932517AbbIVIaz (ORCPT ); Tue, 22 Sep 2015 04:30:55 -0400 Received: from metis.ext.pengutronix.de ([92.198.50.35]:45138 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756786AbbIVIax (ORCPT ); Tue, 22 Sep 2015 04:30:53 -0400 Date: Tue, 22 Sep 2015 10:30:42 +0200 From: Sascha Hauer To: Daniel Kurtz Cc: linux-pm@vger.kernel.org, Zhang Rui , Eduardo Valentin , Mark Rutland , "open list:OPEN FIRMWARE AND..." , "linux-kernel@vger.kernel.org" , Rob Herring , linux-mediatek@lists.infradead.org, Sasha Hauer , Matthias Brugger , "linux-arm-kernel@lists.infradead.org" Subject: Re: [PATCH 2/3] thermal: Add Mediatek thermal controller support Message-ID: <20150922083042.GK7858@pengutronix.de> References: <1441006446-4558-1-git-send-email-s.hauer@pengutronix.de> <1441006446-4558-3-git-send-email-s.hauer@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Sent-From: Pengutronix Hildesheim X-URL: http://www.pengutronix.de/ X-IRC: #ptxdist @freenode X-Accept-Language: de,en X-Accept-Content-Type: text/plain X-Uptime: 10:30:06 up 2 days, 21:59, 53 users, load average: 0.00, 0.07, 0.12 User-Agent: Mutt/1.5.21 (2010-09-15) X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::c0 X-SA-Exim-Mail-From: sha@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Sep 22, 2015 at 03:30:47PM +0800, Daniel Kurtz wrote: > On Mon, Sep 14, 2015 at 3:32 PM, Daniel Kurtz wrote: > > > > Hi Sascha, > > > > On Mon, Aug 31, 2015 at 3:34 PM, Sascha Hauer wrote: > > > This adds support for the Mediatek thermal controller found on MT8173 > > > and likely other SoCs. > > > The controller is a bit special. It does not have its own ADC, instead > > > it controls the on-SoC AUXADC via AHB bus accesses. For this reason > > > we need the physical address of the AUXADC. Also it controls a mux > > > using AHB bus accesses, so we need the APMIXEDSYS physical address aswell. > > > > > > Signed-off-by: Sascha Hauer > > > Reviewed-by: Daniel Kurtz > > > > [snip...] > > > > > +static int mtk_read_temp(void *data, long *temp) > > > +{ > > > + struct mtk_thermal_bank *bank = data; > > > + > > > + mtk_thermal_get_bank(bank); > > > + > > > + *temp = mtk_thermal_bank_temperature(bank); > > > + > > > + mtk_thermal_put_bank(bank); > > > + > > > + return 0; > > > +} > > > + > > > +static const struct thermal_zone_of_device_ops mtk_thermal_ops = { > > > + .get_temp = mtk_read_temp, > > > > On v4.3-rc1, this now causes a compile warning, since the prototype > > for get_temp was changed to: > > > > int (*get_temp)(void *, int *); > > > > by: > > commit 17e8351a77397e8a83727eb17e3a3e9b8ab5257a > > thermal: consistently use int for temperatures > > It is actually a little worse than a warning. This actually causes a > crash on boot. > Sascha, can you send out a rebased patch set on v4.3-rc1? Yes, I'll send out a new version tomorrow. I am currently quite busy with another project. Sascha -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |