Use backwards-compatible battery name only for first tablet

Attaching multiple wireless tablets to a system will cause a kernel
crash when both power supply nodes try to use the same name. The 3.17
kernel adds a unique suffix to the end of every device, but we can't
do that here if we want to be backwards compatible. Instead, we use the
suffix-less name only if it has not already been registered and use the
new behavior otherwise.

Fixes SF bug #248

Signed-off-by: Jason Gerecke <killertofu@gmail.com>
Synchronize 'wacom_wireless_work' for 2.6.38 to match 3.7

Signed-off-by: Jason Gerecke <killertofu@gmail.com>
backport: Input: wacom - put a flag when the led are initialized

This solves a bug with the wireless receiver:
- at plug, the wireless receiver does not know which Wacom device it is
  connected to, so it does not actually creates all the LEDs
- when the tablet connects, wacom->wacom_wac.features.type is set to the
  proper device so that wacom_wac can understand the packets
- when the receiver is unplugged, it detects that a LED should have been
  created (based on wacom->wacom_wac.features.type) and tries to remove
  it: crash when removing the sysfs group.

Side effect, we can now safely call several times wacom_destroy_leds().

Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Acked-by: Ping Cheng <pingc@wacom.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Jason Gerecke <killertofu@gmail.com>