Prev: [RFC][PATCH 10/11] LEDS module of the device driver for DA9052 (Resend)
Next: [PATCH 3/3] Added sysfs interface to pcrypt.
From: Mark Brown on 14 Jul 2010 06:30 On Wed, Jul 14, 2010 at 10:44:10AM +0100, Dajun Chen wrote: > +#ifndef _BAT_H > +#define _BAT_H This is likely to run into namespace conflicts with other stuff - including the chip name should fix that. > + > +#define DA9052_CHG_MEASUREMENT_FAIL -154 As has been pointed out with all your other patches please you standard Linux error codes rather than making up your own. This applies to pretty much all kernel code. > +/* STATIC CONFIGURATION */ > +#define SW_TEMP_CONTROL_EN 0 > +#define MONITORING_INTERVAL 500 > +#define SW_BAT_TEMP_THRESHOLD 60 > +#define SW_JUNC_TEMP_THRESHOLD 120 This all needs to be platform data rather than #defines in the header - the kernel contains code for a very wide range of boards so editing the header file per-board isn't going to work and the valeus you pick may be actively harmful if they fail to correspond to the actual battery properties. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ |