Return-Path: Subject: Re: [PATCH 3/3] HID: Enable Sixaxis controller over Bluetooth From: Marcel Holtmann To: Jiri Kosina Cc: Bastien Nocera , Michael Poole , "Gunn, Brian" , Ping , linux-kernel@vger.kernel.org, BlueZ development In-Reply-To: References: <1264783166.29532.5302.camel@localhost.localdomain> <87iqakifm8.fsf@troilus.org> <1264860663.29532.7887.camel@localhost.localdomain> <87bpg7glf7.fsf@troilus.org> <1265190440.32444.8417.camel@localhost.localdomain> Content-Type: text/plain; charset="UTF-8" Date: Wed, 03 Feb 2010 06:17:30 -0800 Message-ID: <1265206650.31341.113.camel@localhost.localdomain> Mime-Version: 1.0 Sender: linux-bluetooth-owner@vger.kernel.org List-ID: Hi Jiri, > Now that hid_output_raw_report works, port the PS3 Sixaxis > Bluetooth quirk from user-space, into kernel-space. > > Signed-off-by: Bastien Nocera > Signed-off-by: Jiri Kosina Acked-by: Marcel Holtmann > - ret = sony_set_operational(hdev); > + if (hdev->bus == BUS_USB) > + ret = sony_set_operational(hdev); > + else if (hdev->bus == BUS_BLUETOOTH) > + ret = sony_set_operational_bt(hdev); > + else > + ret = 0; > + I would do sony_set_operational_usb() and sony_set_operational_bt() and also turn this into a switch statement for better readability. Regards Marcel