Source
MODULE_DESCRIPTION("Glue between LIS3LV02Dx and HP ACPI BIOS and support for disk protection LED.");
/*
* hp_accel.c - Interface between LIS3LV02DL driver and HP ACPI BIOS
*
* Copyright (C) 2007-2008 Yan Burman
* Copyright (C) 2008 Eric Piel
* Copyright (C) 2008-2009 Pavel Machek
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/* Delayed LEDs infrastructure ------------------------------------ */
/* Special LED class that can defer work */
struct delayed_led_classdev {
struct led_classdev led_classdev;
struct work_struct work;
enum led_brightness new_brightness;
unsigned int led; /* For driver */
void (*set_brightness)(struct delayed_led_classdev *data, enum led_brightness value);
};
static inline void delayed_set_status_worker(struct work_struct *work)
{
struct delayed_led_classdev *data =
container_of(work, struct delayed_led_classdev, work);