linux/drivers/input/misc/apanel.c

// SPDX-License-Identifier: GPL-2.0-only
/*
 *  Fujitsu Lifebook Application Panel button drive
 *
 *  Copyright (C) 2007 Stephen Hemminger <[email protected]>
 *  Copyright (C) 2001-2003 Jochen Eisinger <[email protected]>
 *
 * Many Fujitsu Lifebook laptops have a small panel of buttons that are
 * accessible via the i2c/smbus interface. This driver polls those
 * buttons and generates input events.
 *
 * For more details see:
 *	http://apanel.sourceforge.net/tech.php
 */

#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/ioport.h>
#include <linux/io.h>
#include <linux/input.h>
#include <linux/i2c.h>
#include <linux/leds.h>

#define APANEL_NAME
#define APANEL

/* How often we poll keys - msecs */
#define POLL_INTERVAL_DEFAULT

/* Magic constants in BIOS that tell about buttons */
enum apanel_devid {};

enum apanel_chip {};

/* Result of BIOS snooping/probing -- what features are supported */
static enum apanel_chip device_chip[APANEL_DEV_MAX];

#define MAX_PANEL_KEYS

struct apanel {};

static const unsigned short apanel_keymap[MAX_PANEL_KEYS] =;

static void report_key(struct input_dev *input, unsigned keycode)
{}

/* Poll for key changes
 *
 * Read Application keys via SMI
 *  A (0x4), B (0x8), Internet (0x2), Email (0x1).
 *
 * CD keys:
 * Forward (0x100), Rewind (0x200), Stop (0x400), Pause (0x800)
 */
static void apanel_poll(struct input_dev *idev)
{}

static int mail_led_set(struct led_classdev *led,
			 enum led_brightness value)
{}

static int apanel_probe(struct i2c_client *client)
{}

static void apanel_shutdown(struct i2c_client *client)
{}

static const struct i2c_device_id apanel_id[] =;
MODULE_DEVICE_TABLE(i2c, apanel_id);

static struct i2c_driver apanel_driver =;

/* Scan the system ROM for the signature "FJKEYINF" */
static __init const void __iomem *bios_signature(const void __iomem *bios)
{}

static int __init apanel_init(void)
{}
module_init();

static void __exit apanel_cleanup(void)
{}
module_exit(apanel_cleanup);

MODULE_AUTHOR();
MODULE_DESCRIPTION();
MODULE_LICENSE();

MODULE_ALIAS();
MODULE_ALIAS();