Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753397Ab0KEDAQ (ORCPT ); Thu, 4 Nov 2010 23:00:16 -0400 Received: from imr4.ericy.com ([198.24.6.8]:52799 "EHLO imr4.ericy.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753047Ab0KEDAO (ORCPT ); Thu, 4 Nov 2010 23:00:14 -0400 Date: Thu, 4 Nov 2010 19:59:33 -0700 From: Guenter Roeck To: Henrik Rydberg CC: Jean Delvare , "linux-kernel@vger.kernel.org" , "lm-sensors@lm-sensors.org" Subject: Re: [lm-sensors] [PATCH 6/8] hwmon: applesmc: Dynamic creation of fan files Message-ID: <20101105025933.GE28308@ericsson.com> References: <1288511434-5662-1-git-send-email-rydberg@euromail.se> <1288511434-5662-7-git-send-email-rydberg@euromail.se> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <1288511434-5662-7-git-send-email-rydberg@euromail.se> User-Agent: Mutt/1.5.20 (2009-06-14) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1058 Lines: 35 On Sun, Oct 31, 2010 at 03:50:32AM -0400, Henrik Rydberg wrote: > With the dynamic temperature group in place, the setup of fans > can be simplified. This patch sets up the fans dynamically, removing > a hundred lines of code. > > Signed-off-by: Henrik Rydberg Hi Henrik, just one minor comment. > --- > drivers/hwmon/applesmc.c | 188 +++++++++++----------------------------------- > 1 files changed, 43 insertions(+), 145 deletions(-) > > diff --git a/drivers/hwmon/applesmc.c b/drivers/hwmon/applesmc.c > index abbff0b..4ba20ec 100644 > --- a/drivers/hwmon/applesmc.c > +++ b/drivers/hwmon/applesmc.c [ ... ] > static int applesmc_init_smcreg_try(void) > { > struct applesmc_registers *s = &smcreg; > + u8 tmp[4]; Why tmp[4] if you only read one byte ? Guenter -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/