Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758501AbZIQM6R (ORCPT ); Thu, 17 Sep 2009 08:58:17 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1758239AbZIQM6Q (ORCPT ); Thu, 17 Sep 2009 08:58:16 -0400 Received: from mail-ew0-f227.google.com ([209.85.219.227]:39907 "EHLO mail-ew0-f227.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755812AbZIQM6M (ORCPT ); Thu, 17 Sep 2009 08:58:12 -0400 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=Txs+EGEhoWvJPwNQRKFsLPBJZerAzBguAsV9XdEickAS0V7eduajhmuWIpgRNJTZay x6CczmSBECnmDrjjNtaRauSbJrQ9D28tFq1Bw+avJw+QbDlpZO+7YlNiN0/YOENRhM9G xKM22cpyToeHuQjYCl/bx6f2kKN4lABoPLP54= MIME-Version: 1.0 In-Reply-To: <7eb6a4d80909170549k7a19eb01s8975fe2c5f230cee@mail.gmail.com> References: <7eb6a4d80909170549k7a19eb01s8975fe2c5f230cee@mail.gmail.com> Date: Thu, 17 Sep 2009 14:52:29 +0200 Message-ID: <7eb6a4d80909170552na322914x23b65d60bb56e20d@mail.gmail.com> Subject: New ark3116 driver - how to get included into kernel? From: Bart Hartgers To: linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, gregkh@suse.de Cc: Ondrej Zary , ark3116_driver@auctionant.de Content-Type: multipart/mixed; boundary=00504502ca0efa28bb0473c57cea Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 40057 Lines: 616 --00504502ca0efa28bb0473c57cea Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable (Sorry for sending an HTML-ized version of this mail before) Hi All, I managed to write an improved ark3116 driver after I figured out that it is just an 16450 UART with some USB glue logic. The attached files can be compiled outside the kernel tree, and work for 2.6.31. However, I would like this driver to (eventually) end up in the kernel tree. In order to get there, who should I sent patches against what? I've contributed code to the kernel before, but not in the last 5 or so years, so I am a bit out of touch. Compared to the old ark3116 driver this one offers the following improvemen= ts: =C2=A0- cts/rts handshake support =C2=A0- break signalling =C2=A0- line error detection Since it is a big step from the previous driver, it made little sense to modify that one, so I created new driver, named ark316new. Also this means that both could coexist if the new one doesn't work for someone. This driver also includes support for an ark3116-based IrDA dongle, tested by Ondrej Zary. Thanks in advance for any input/help. Groeten, Bart >> >> I also tried to include the IrDA fixes for the old ark3116.c driver >> that were posted on this list recently, but I could not test if >> these work, since I don't have the proper hardware. 2009/8/31 Bart Hartgers > > 2009/8/29 Ondrej Zary : > > On Sunday 23 August 2009 14:46:16 Bart Hartgers wrote: > >> Hi All, > >> > >> I managed to write an improved ark3116 driver after I figured out that > >> it is just an 16450 UART with some USB glue logic. > >> > >> Compared to the old ark3116 driver it offers the following improvement= s: > >> - cts/rts handshake support > >> - break signalling > >> - line error detection > >> > >> Since it is a big step from the previous driver, it made little sense > >> to modify that one, so I created new driver, named ark316new. Also > >> this means that both could coexist if the new one doesn't work for > >> someone. > >> > >> I have no datasheet, so the driver is entirely based on reverse > >> engineering, and some testing by others would be a good idea. > >> > >> I also tried to include the IrDA fixes for the old ark3116.c driver > >> that were posted on this list recently, but I could not test if > >> these work, since I don't have the proper hardware. > >> > >> Because of this, I would appreciate reports of both success and > >> failure in using this driver. > > > > Tested the driver today with that Gembird UIR-22. > > > > It did not compile neither in 2.6.30.1 nor in 2.6.31-rc8 with the follo= wing > > error: > > > > ark3116new.c:790: error: unknown field shutdown specified in initialize= r > > ark3116new/ark3116new.c:790: warning: initialization from incompatible = pointer > > type > > > > Commenting that line produced a module that worked: > > usb 1-1: new full speed USB device using uhci_hcd and address 2 > > usb 1-1: configuration #0 chosen from 1 choice > > usb 1-1: config 0 descriptor?? > > usbcore: registered new interface driver usbserial > > usbserial: USB Serial Driver core > > USB Serial support registered for ARK3116 RS232/IrDA > > ark3116new 1-1:0.0: ARK3116 RS232/IrDA converter detected > > usb 1-1: ark3116new using IrDA mode > > usb 1-1: ARK3116 RS232/IrDA converter now attached to ttyUSB0 > > usbcore: registered new interface driver ark3116new > > ark3116new:v0.1:USB ARK3116 serial/IrDA driver > > usb 1-1: ark3116new don't know how to do software flow control > > NET: Registered protocol family 23 > > > > Ran "irattach /dev/ttyUSB0 -s" and then "obexftp -i -l" to list files o= n Nokia > > 6230i. It worked fine and file transfer too. So the IrDA mode works. > > > > When I unplugged the device, irattach remained running and some error m= essage > > was written to console every few seconds (sorry, I haven't recorded it)= . > > Killing irattach then resulted in oops. But this might be expected as t= he > > shutdown function was commented out. > > > Hi Ondrej, > > Thanks for testing this! > > I later discovered that there is a change with respect to > shutdown-functionality between 2.6.28 (on which I made the driver) and > 2.6.31. I have to update the driver to 2.6.current anyway. > > > I think that this driver should replace current ark3116 driver. Having = two > > drivers for the same hardware is a bad thing. > > I agree. However, given the experimental nature of the driver, I would > prefer some more testing. Then again, the original driver is lacks > some features, and making ark3116new default would increase its > exposure ;-). > > Groeten, > Bart > > > > > -- > > Ondrej Zary > > > > > > -- > Bart Hartgers - New e-mail: bart.hartgers@gmail.com -- Bart Hartgers - New e-mail: bart.hartgers@gmail.com -- Bart Hartgers - New e-mail: bart.hartgers@gmail.com --00504502ca0efa28bb0473c57cea Content-Type: text/plain; charset=US-ASCII; name="Makefile.txt" Content-Disposition: attachment; filename="Makefile.txt" Content-Transfer-Encoding: base64 X-Attachment-Id: f_fzphxt841 b2JqLW0gICAgOj0gYXJrMzExNm5ldy5vCgpLRElSICAgIDo9IC9saWIvbW9kdWxlcy8kKHNoZWxs IHVuYW1lIC1yKS9idWlsZApLTUlTQyAgIDo9IC9saWIvbW9kdWxlcy8kKHNoZWxsIHVuYW1lIC1y KS9rZXJuZWwvZHJpdmVycy91c2Ivc2VyaWFsClBXRCAgICA6PSAkKHNoZWxsIHB3ZCkKCkVYVFJB X0NGTEFHUyArPSAtSS91c3Ivc3JjL2xpbnV4L2RyaXZlcnMvdXNiL3NlcmlhbCAtSS91c3Ivc3Jj L2xpbnV4L2luY2x1ZGUvbGludXgvCgptb2R1bGVzOgoJJChNQUtFKSAtQyAkKEtESVIpIFNVQkRJ UlM9JChQV0QpICQoRVhUUkFfQ0ZMQUdTKSBtb2R1bGVzCgppbnN0YWxsOiBtb2R1bGVzCglpbnN0 YWxsIC1kICQoS01JU0MpCglpbnN0YWxsIC1tIDY0NCAtYyBhcmszMTE2bmV3LmtvICQoS01JU0Mp Cgkvc2Jpbi9kZXBtb2QgLWEKCmNsZWFuOgoJcm0gLWYgKi5tb2QuYyAqLm1vZCAqLm8gKi5rbyAu Ki5jbWQKCXJtIC1yZiAkKFBXRCkvLnRtcF92ZXJzaW9ucwoJCg== --00504502ca0efa28bb0473c57cea Content-Type: text/x-csrc; charset=US-ASCII; name="ark3116new.c" Content-Disposition: attachment; filename="ark3116new.c" Content-Transfer-Encoding: base64 X-Attachment-Id: f_fzphv9xw0 LyogIC0qLSBldmFsOiBjX3NldF9zdHlsZSgibGludXgiKSAtKi0gKi8KLyogCiAqIERyaXZlciBm b3IgdGhlIGFya21pY3JvIDMxMTYgdXNiMnNlcmlhbCBjb252ZXJ0b3IgY2hpcC4KICogCiAqIChD KSBDb3B5cmlnaHQgMjAwOSBieSBCYXJ0IEhhcnRnZXJzIChiYXJ0LmhhcnRnZXJzK2FyazMxMTZA Z21haWwuY29tKQogKiAKICogU3VwcG9ydHMgZnVsbCBtb2RlbSBzdGF0dXMgbGluZXMsIGJyZWFr LCBoYXJkd2FyZSBmbG93IGNvbnRyb2wuIERvZXMgbm90CiAqIHN1cHBvcnQgc29mdHdhcmUgZmxv dyBjb250cm9sLCBzaW5jZSBJIGRvIG5vdCBrbm93IGhvdyB0byBlbmFibGUgaXQgaW4gaHcuCiAq IAogKiBUaGlzIGRyaXZlciBpcyBhIG5ldyBpbXBsZW1lbnRhdGlvbi4gSSBpbml0aWFsbH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QjoKICogU2V0IHRvIDB4MDEgZm9yIElyREEsIDB4MDAgZm9yIFJTMjMy LCBhdCBpbml0LgogKgogKiBSZWdpc3RlciBDOgogKiBTZXQgdG8gMDAgZm9yIElyREEsIGF0IGlu aXQuCiAqIAogKiBSZWdpc3RlciBEOgogKiBTZXQgdG8gMHg0MSBmb3IgSXJEQSwgYXQgaW5pdC4g CiAqIAogKiBSZWdpc3RlciBFOgogKiBTb21la2luZCBvZiBiYXVkcmF0ZSBvdmVycmlkZS4gVGhl IHdpbmRvd3MgZHJpdmVyIHNlZW1zIHRvIHNldAogKiB0aGlzIHRvIDB4MDAgZm9yIG5vcm1hbCBi YXVkcmF0ZXMsIDB4MDEgZm9yIDQ2MDgwMCwgMHgwMiBmb3IgOTIxNjAwLgogKiBTaW5jZSA0NjA4 MDAgYW5kIDkyMTYwMCBjYW5ub3QgYmUgb2J0YWluZWQgYnkgZGl2aWRpbmcgM01IeiBieSBhbiBp bnRlZ2VyLAogKiBpdCBjb3VsZCBiZSBzb21la2luZCBvZiBzdWJkaXZpc29yIHRoaW5neS4KICog SG93ZXZlcixpdCBkb2VzIG5vdCBzZWVtIHRvIGRvIGFueXRoaW5nOiBzZWxlY3RpbmcgOTIxNjAw IChkaXZpc29yIDMsIAogKiByZWcgRT0yKSwgc3RpbGwgZ2V0cyAxIE1Iei4gSSBhbHNvIGNoZWNr ZWQgaWYgcmVnaXN0ZXJzIDksIEMgb3IgRiB3b3VsZCAKICogd29yaywgYnV0IHRoZXkgZG9uJ3Qu CiAqIAogKiBSZWdpc3RlciBGOiB1bmtub3duCiAqLwo= --00504502ca0efa28bb0473c57cea-- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/