linux/drivers/platform/x86/dell/dell-wmi-base.c

// SPDX-License-Identifier: GPL-2.0-or-later
/*
 * Dell WMI hotkeys
 *
 * Copyright (C) 2008 Red Hat <[email protected]>
 * Copyright (C) 2014-2015 Pali Rohár <[email protected]>
 *
 * Portions based on wistron_btns.c:
 * Copyright (C) 2005 Miloslav Trmac <[email protected]>
 * Copyright (C) 2005 Bernhard Rosenkraenzer <[email protected]>
 * Copyright (C) 2005 Dmitry Torokhov <[email protected]>
 */

#define pr_fmt(fmt)

#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/init.h>
#include <linux/slab.h>
#include <linux/types.h>
#include <linux/input.h>
#include <linux/input/sparse-keymap.h>
#include <linux/acpi.h>
#include <linux/string.h>
#include <linux/dmi.h>
#include <linux/wmi.h>
#include <acpi/video.h>
#include "dell-smbios.h"
#include "dell-wmi-descriptor.h"
#include "dell-wmi-privacy.h"

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

#define DELL_EVENT_GUID

static bool wmi_requires_smbios_request;

struct dell_wmi_priv {};

static int __init dmi_matched(const struct dmi_system_id *dmi)
{}

static const struct dmi_system_id dell_wmi_smbios_list[] __initconst =;

/*
 * Keymap for WMI events of type 0x0000
 *
 * Certain keys are flagged as KE_IGNORE. All of these are either
 * notifications (rather than requests for change) or are also sent
 * via the keyboard controller so should not be sent again.
 */
static const struct key_entry dell_wmi_keymap_type_0000[] =;

struct dell_bios_keymap_entry {};

struct dell_bios_hotkey_table {};

struct dell_dmi_results {};

/* Uninitialized entries here are KEY_RESERVED == 0. */
static const u16 bios_to_linux_keycode[256] =;

/*
 * Keymap for WMI events of type 0x0010
 *
 * These are applied if the 0xB2 DMI hotkey table is present and doesn't
 * override them.
 */
static const struct key_entry dell_wmi_keymap_type_0010[] =;

/*
 * Keymap for WMI events of type 0x0011
 */
static const struct key_entry dell_wmi_keymap_type_0011[] =;

/*
 * Keymap for WMI events of type 0x0012
 * They are events with extended data
 */
static const struct key_entry dell_wmi_keymap_type_0012[] =;

static void dell_wmi_switch_event(struct input_dev **subdev,
				  const char *devname,
				  int switchid,
				  int value)
{}

static int dell_wmi_process_key(struct wmi_device *wdev, int type, int code, u16 *buffer, int remaining)
{}

static void dell_wmi_notify(struct wmi_device *wdev,
			    union acpi_object *obj)
{}

static bool have_scancode(u32 scancode, const struct key_entry *keymap, int len)
{}

static void handle_dmi_entry(const struct dmi_header *dm, void *opaque)
{}

static int dell_wmi_input_setup(struct wmi_device *wdev)
{}

static void dell_wmi_input_destroy(struct wmi_device *wdev)
{}

/*
 * According to Dell SMBIOS documentation:
 *
 * 17  3  Application Program Registration
 *
 *     cbArg1 Application ID 1 = 0x00010000
 *     cbArg2 Application ID 2
 *            QUICKSET/DCP = 0x51534554 "QSET"
 *            ALS Driver   = 0x416c7353 "AlsS"
 *            Latitude ON  = 0x4c6f6e52 "LonR"
 *     cbArg3 Application version or revision number
 *     cbArg4 0 = Unregister application
 *            1 = Register application
 *     cbRes1 Standard return codes (0, -1, -2)
 */

static int dell_wmi_events_set_enabled(bool enable)
{}

static int dell_wmi_probe(struct wmi_device *wdev, const void *context)
{}

static void dell_wmi_remove(struct wmi_device *wdev)
{}
static const struct wmi_device_id dell_wmi_id_table[] =;

static struct wmi_driver dell_wmi_driver =;

static int __init dell_wmi_init(void)
{}
late_initcall(dell_wmi_init);

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

MODULE_DEVICE_TABLE(wmi, dell_wmi_id_table);