Am Mittwoch, 15. Juni 2011, 01:45:56 schrieb David Herrmann:
quoted hunk ↗ jump to hunk
@@ -319,7 +340,12 @@ static int wiimote_hid_probe(struct hid_device *hdev,
atomic_set(&wdata->ready, 1);
hid_info(hdev, "New device registered\n");
+
+ /* by default set led1 after device initialization */
+ spin_lock(&wdata->state.lock);
spin_lock_irq() or you might deadlock.
quoted hunk ↗ jump to hunk
wiiproto_req_leds(wdata, WIIPROTO_FLAG_LED1);
+ spin_unlock(&wdata->state.lock);
+
return 0;
Regards
Oliver