From: Benjamin Tissoires Date: Thu, 8 Jan 2015 19:37:12 +0000 (-0500) Subject: HID: logitech-hidpp: store the name of the device in struct hidpp X-Git-Tag: fixes-v4.0-rc1~153^2^5~2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=005b3f574a0a53f476a62da5c861c1c9bf8177b7;p=pandora-kernel.git HID: logitech-hidpp: store the name of the device in struct hidpp If a disconnect occurs while getting the actual name of the device (which can take several HID transactions), the name of the device will be the hid name, provided by the Unifying Receiver. This means that in some cases, the user space will see a different name that what it usually sees when there is no disconnect. We should store the name of the device in the struct hidpp. That way, if a disconnect occurs while we are accessing the name, hidpp_connect_event() can fail, and the input node is not created. The input node will be created only if we have a connection which lasts long enough to retrieve all the requested information: name, protocol, and specific configuration. Reviewed-by: Peter Wu Tested-by: Peter Wu Signed-off-by: Benjamin Tissoires Signed-off-by: Jiri Kosina --- Reading git-diff-tree failed