Lines Matching full:huawei
3 * Huawei WMI laptop extras driver
24 * Huawei WMI GUIDs
82 // Huawei |M| key
126 .ident = "Huawei MACH-WX9",
128 DMI_MATCH(DMI_SYS_VENDOR, "HUAWEI"),
135 .ident = "Huawei MateBook X",
137 DMI_MATCH(DMI_SYS_VENDOR, "HUAWEI"),
138 DMI_MATCH(DMI_PRODUCT_NAME, "HUAWEI MateBook X")
147 static int huawei_wmi_call(struct huawei_wmi *huawei, in huawei_wmi_call() argument
152 mutex_lock(&huawei->wmi_lock); in huawei_wmi_call()
154 mutex_unlock(&huawei->wmi_lock); in huawei_wmi_call()
156 dev_err(huawei->dev, "Failed to evaluate wmi method\n"); in huawei_wmi_call()
173 struct huawei_wmi *huawei = huawei_wmi; in huawei_wmi_cmd() local
187 err = huawei_wmi_call(huawei, &in, &out); in huawei_wmi_cmd()
207 dev_err(huawei->dev, "Bad buffer length, got %d\n", obj->buffer.length); in huawei_wmi_cmd()
218 dev_err(huawei->dev, "Bad package count, got %d\n", obj->package.count); in huawei_wmi_cmd()
225 dev_err(huawei->dev, "Bad package element type, got %d\n", obj->type); in huawei_wmi_cmd()
234 dev_err(huawei->dev, "Unexpected obj type, got: %d\n", obj->type); in huawei_wmi_cmd()
307 struct huawei_wmi *huawei = dev_get_drvdata(dev); in huawei_wmi_leds_setup() local
309 huawei->cdev.name = "platform::micmute"; in huawei_wmi_leds_setup()
310 huawei->cdev.max_brightness = 1; in huawei_wmi_leds_setup()
311 huawei->cdev.brightness_set_blocking = &huawei_wmi_micmute_led_set; in huawei_wmi_leds_setup()
312 huawei->cdev.default_trigger = "audio-micmute"; in huawei_wmi_leds_setup()
313 huawei->cdev.dev = dev; in huawei_wmi_leds_setup()
314 huawei->cdev.flags = LED_CORE_SUSPENDRESUME; in huawei_wmi_leds_setup()
316 devm_led_classdev_register(dev, &huawei->cdev); in huawei_wmi_leds_setup()
497 .name = "Huawei Battery Extension"
502 struct huawei_wmi *huawei = dev_get_drvdata(dev); in huawei_wmi_battery_setup() local
504 huawei->battery_available = true; in huawei_wmi_battery_setup()
506 huawei->battery_available = false; in huawei_wmi_battery_setup()
516 struct huawei_wmi *huawei = dev_get_drvdata(dev); in huawei_wmi_battery_exit() local
518 if (huawei->battery_available) { in huawei_wmi_battery_exit()
589 struct huawei_wmi *huawei = dev_get_drvdata(dev); in huawei_wmi_fn_lock_setup() local
591 huawei->fn_lock_available = true; in huawei_wmi_fn_lock_setup()
593 huawei->fn_lock_available = false; in huawei_wmi_fn_lock_setup()
602 struct huawei_wmi *huawei = dev_get_drvdata(dev); in huawei_wmi_fn_lock_exit() local
604 if (huawei->fn_lock_available) in huawei_wmi_fn_lock_exit()
613 struct huawei_wmi *huawei = m->private; in huawei_wmi_debugfs_call_dump() local
635 huawei_wmi_debugfs_call_dump(m, huawei, &obj->package.elements[i]); in huawei_wmi_debugfs_call_dump()
642 dev_err(huawei->dev, "Unexpected obj type, got %d\n", obj->type); in huawei_wmi_debugfs_call_dump()
649 struct huawei_wmi *huawei = m->private; in huawei_wmi_debugfs_call_show() local
656 in.pointer = &huawei->debug.arg; in huawei_wmi_debugfs_call_show()
658 err = huawei_wmi_call(huawei, &in, &out); in huawei_wmi_debugfs_call_show()
668 huawei_wmi_debugfs_call_dump(m, huawei, obj); in huawei_wmi_debugfs_call_show()
679 struct huawei_wmi *huawei = dev_get_drvdata(dev); in huawei_wmi_debugfs_setup() local
681 huawei->debug.root = debugfs_create_dir("huawei-wmi", NULL); in huawei_wmi_debugfs_setup()
683 debugfs_create_x64("arg", 0644, huawei->debug.root, in huawei_wmi_debugfs_setup()
684 &huawei->debug.arg); in huawei_wmi_debugfs_setup()
686 huawei->debug.root, huawei, &huawei_wmi_debugfs_call_fops); in huawei_wmi_debugfs_setup()
691 struct huawei_wmi *huawei = dev_get_drvdata(dev); in huawei_wmi_debugfs_exit() local
693 debugfs_remove_recursive(huawei->debug.root); in huawei_wmi_debugfs_exit()
757 idev->name = "Huawei WMI hotkeys"; in huawei_wmi_input_setup()
782 /* Huawei driver */
842 .name = "huawei-wmi",
868 pdev = platform_device_register_simple("huawei-wmi", PLATFORM_DEVID_NONE, NULL, 0); in huawei_wmi_init()
899 MODULE_DESCRIPTION("Huawei WMI laptop extras driver");