Re: [PATCH] hwmon: add GP2A002 proximity/ambient sensor

From: Jaswinder Singh Rajput
Date: Fri Jun 26 2009 - 05:19:39 EST


On Fri, 2009-06-26 at 17:39 +0900, Minkyu Kang wrote:
> The GP2A002 is a I2C interfaced Sensor for Proximity/Ambient
> This patch adds support the GP2A002 sensor
>
> Signed-off-by: Minkyu Kang <mk7.kang@xxxxxxxxxxx>
> Signed-off-by: Suchang Woo <suchang.woo@xxxxxxxxxxx>
> ---
> drivers/hwmon/Kconfig | 7 +
> drivers/hwmon/Makefile | 1 +
> drivers/hwmon/gp2ap002.c | 471 ++++++++++++++++++++++++++++++++++++++++++++++
> include/linux/gp2ap002.h | 21 ++
> 4 files changed, 500 insertions(+), 0 deletions(-)
> create mode 100644 drivers/hwmon/gp2ap002.c
> create mode 100644 include/linux/gp2ap002.h
>

> diff --git a/include/linux/gp2ap002.h b/include/linux/gp2ap002.h
> new file mode 100644
> index 0000000..b6a950b
> --- /dev/null
> +++ b/include/linux/gp2ap002.h
> @@ -0,0 +1,21 @@
> +/*
> + * Copyright (C) 2009 Samsung Electronics
> + * Minkyu Kang <mk7.kang@xxxxxxxxxxx>
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License version 2 as
> + * published by the Free Software Foundation.
> + */
> +
> +#ifndef __GP2AP002_H_
> +#define __GP2AP002_H_
> +
> +struct gp2ap002_platform_data {
> + int (*get_adc)(void);
> + void (*power_enable)(int);
> + int vo_gpio;
> + int prox_mode;
> + int enable;
> +};
> +
> +#endif

I am curious what is the use of include/linux/gp2ap002.h, it only have
gp2ap002_platform_data structure which you can keep in your source file
the only file which is using it.

Thanks,
--
JSR

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/