Lines Matching defs:hdev

94 	struct hid_device *hdev;
192 ret = hid_hw_output_report(priv->hdev, priv->buffer, MAX_REPORT_LENGTH);
730 static int kraken3_raw_event(struct hid_device *hdev, struct hid_report *report, u8 *data, int size)
732 struct kraken3_data *priv = hid_get_drvdata(hdev);
753 hid_err_once(hdev,
800 static int kraken3_init_device(struct hid_device *hdev)
802 struct kraken3_data *priv = hid_get_drvdata(hdev);
818 static int kraken3_get_fw_ver(struct hid_device *hdev)
820 struct kraken3_data *priv = hid_get_drvdata(hdev);
837 static int __maybe_unused kraken3_reset_resume(struct hid_device *hdev)
841 ret = kraken3_init_device(hdev);
843 hid_err(hdev, "req init (reset_resume) failed with %d\n", ret);
867 dev_name(&priv->hdev->dev));
873 static int kraken3_probe(struct hid_device *hdev, const struct hid_device_id *id)
879 priv = devm_kzalloc(&hdev->dev, sizeof(*priv), GFP_KERNEL);
883 priv->hdev = hdev;
884 hid_set_drvdata(hdev, priv);
893 ret = hid_parse(hdev);
895 hid_err(hdev, "hid parse failed with %d\n", ret);
900 ret = hid_hw_start(hdev, HID_CONNECT_HIDRAW);
902 hid_err(hdev, "hid hw start failed with %d\n", ret);
906 ret = hid_hw_open(hdev);
908 hid_err(hdev, "hid hw open failed with %d\n", ret);
912 switch (hdev->product) {
935 priv->buffer = devm_kzalloc(&hdev->dev, MAX_REPORT_LENGTH, GFP_KERNEL);
947 hid_device_io_start(hdev);
948 ret = kraken3_init_device(hdev);
950 hid_err(hdev, "device init failed with %d\n", ret);
954 ret = kraken3_get_fw_ver(hdev);
956 hid_warn(hdev, "fw version request failed with %d\n", ret);
958 priv->hwmon_dev = hwmon_device_register_with_info(&hdev->dev, device_name, priv,
962 hid_err(hdev, "hwmon registration failed with %d\n", ret);
971 hid_hw_close(hdev);
973 hid_hw_stop(hdev);
977 static void kraken3_remove(struct hid_device *hdev)
979 struct kraken3_data *priv = hid_get_drvdata(hdev);
984 hid_hw_close(hdev);
985 hid_hw_stop(hdev);