// SPDX-License-Identifier: GPL-2.0-or-later /* * Force feedback support for Mayflash game controller adapters. * * These devices are manufactured by Mayflash but identify themselves * using the vendor ID of DragonRise Inc. * * Tested with: * 0079:1801 "DragonRise Inc. Mayflash PS3 Game Controller Adapter" * 0079:1803 "DragonRise Inc. Mayflash Wireless Sensor DolphinBar" * 0079:1843 "DragonRise Inc. Mayflash GameCube Game Controller Adapter" * 0079:1844 "DragonRise Inc. Mayflash GameCube Game Controller Adapter (v04)" * * The following adapters probably work too, but need to be tested: * 0079:1800 "DragonRise Inc. Mayflash WIIU Game Controller Adapter" * * Copyright (c) 2016-2017 Marcel Hasler <[email protected]> */ /* */ #include <linux/input.h> #include <linux/slab.h> #include <linux/hid.h> #include <linux/module.h> #include "hid-ids.h" struct mf_device { … }; static int mf_play(struct input_dev *dev, void *data, struct ff_effect *effect) { … } static int mf_init(struct hid_device *hid) { … } static int mf_probe(struct hid_device *hid, const struct hid_device_id *id) { … } static const struct hid_device_id mf_devices[] = …; MODULE_DEVICE_TABLE(hid, mf_devices); static struct hid_driver mf_driver = …; module_hid_driver(…) …; MODULE_DESCRIPTION(…) …; MODULE_LICENSE(…) …;