There goes the two small patches [1][2] that adds support for KT-LINK interface [3] that is based on FTDI's FT2232H chip and contains RS232 port that can be used in FreeBSD with uftdi driver when VID/PID is recognised. Patches only adds VID/PID definition of the KT-LINK device. [1] http://files.tomek.cedro.info/stuff/freebsd/freebsd-uftdi-ktlink-uftdi-tcedro.patch [2] http://files.tomek.cedro.info/stuff/freebsd/freebsd-uftdi-ktlink-usbdevs-tcedro.patch [3] http://shop.kristech.pl/p/24/257/kt-link-.html Fix: Patch attached with submission follows:
On Saturday 09 February 2013 16:59:43 CeDeROM wrote: > Hello Hans :-) > > Can you please review my patch that adds detection od KT-LINK device > for uftdi driver? > > Can you please confirm on what should I do to make HP pendrive > detctable - it was about quirk defaults.. > > Should I send patches like that with send-pr? Is that okay or there is > another way? > > Thank you :-) > Tomek Cedro Have you tested your patch? Are you sure this driver uses the kernel uftdi driver and not libftdi? Does your application work without your patch? --HPS
On Sun, Feb 10, 2013 at 11:00 AM, Hans Petter Selasky <hselasky@c2i.net> wrote: > Have you tested your patch? Are you sure this driver uses the kernel uftdi > driver and not libftdi? > > Does your application work without your patch? Hello Hans :-) UFTDI driver is used to access RS232 channel(s) of FT2232H chip inside KT-LINK with /dev/cuaUn device. KT-LINK has two channels - one for RS232 port and second for JTAG/SWD/(...). Applications using libftdi and libusb use the JTAG port of the KT-LINK interface. Still it is possible to use RS232 channel as a serial console with Minicom. My patch adds support for KT-LINK interface in uftdi serial console driver to be used as /dev/cuaUn. UTFDI driver creates two nodes for both channels (i.e. /dev/cuaU3 and /dev/cuaU4). Yes I have tested my patch - it is working well with Minicom and different devices as serial port usb dongle. Still I can use both RS232 channel and JTAG channel at the same time with one KT-LINK interface: <= TESTING STARTS => DMESG: ugen1.6: <Kristech> at usbus1 uftdi0: <KT-LINK> on usbus1 uftdi1: <KT-LINK> on usbus1 => UrJTAG / LIBFTDI: % ./jtag UrJTAG 0.10 # Copyright (C) 2002, 2003 ETC s.r.o. Copyright (C) 2007, 2008, 2009 Kolja Waschk and the respective authors UrJTAG is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. There is absolutely no warranty for UrJTAG. warning: UrJTAG may damage your hardware! Type "quit" to exit, "help" for help. jtag> cable kt-link Connected to libftdi driver. nSRST pin state is high... KT-LINK JTAG Mode Initialization OK! jtag> detect jtag> freq 100000 Setting TCK frequency to 100000 Hz jtag> detect IR length: 9 Chain length: 2 Device Id: 00111011101000000000010001110111 (0x3BA00477) Unknown manufacturer! (01000111011) (/tmp/openocd/target/share/urjtag/MANUFACTURERS) Device Id: 00000110010000010100000001000001 (0x06414041) Unknown manufacturer! (00000100000) (/tmp/openocd/target/share/urjtag/MANUFACTURERS) => MINICOM/UFTDI: Welcome to minicom 2.6.1 OPTIONS: I18n Compiled on Oct 14 2012, 07:52:31. Port /dev/cuaU4 Press CTRL-A Z for help on special keys aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa <= TESTING ENDS No Minicom does not work with KT-LINK without my patch because system does not recognize this device as FTDI chip that can be used with UFTDI driver. My patch adds necessary identification numbers, no other modifications. ! The only remark is that I can connect to /dev/cuaU3 when this channel is already used by LibFTDI, which breaks funcion of the JTAG channel/application if active, but I guess this is some kind of non-blocking feature of the FreeBSD..? Still it is possible to use JTAG channel with LibFTDI and RS232 channel with UFTDI driver independently. Also When I shutdown Minicom operating at JTAG channel I can again initialize the JTAG channel on the LibFTDI applications and use it with no problem. Best regards :-) Tomek -- CeDeROM, SQ7MHZ, http://www.tomek.cedro.info
Author: hselasky Date: Wed Feb 13 08:28:27 2013 New Revision: 246753 URL: http://svnweb.freebsd.org/changeset/base/246753 Log: Add new USB ID to FTDI driver. MFC after: 1 week PR: kern/175893 Submitted by: Tomek Modified: head/sys/dev/usb/serial/uftdi.c head/sys/dev/usb/usbdevs Modified: head/sys/dev/usb/serial/uftdi.c ============================================================================== --- head/sys/dev/usb/serial/uftdi.c Wed Feb 13 08:20:29 2013 (r246752) +++ head/sys/dev/usb/serial/uftdi.c Wed Feb 13 08:28:27 2013 (r246753) @@ -378,6 +378,7 @@ static const STRUCT_USB_HOST_ID uftdi_de UFTDI_DEV(FTDI, IPLUS2, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, IRTRANS, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, KBS, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, KTLINK, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, LENZ_LIUSB, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, LK202, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, LK204, UFTDI_TYPE_8U232AM), Modified: head/sys/dev/usb/usbdevs ============================================================================== --- head/sys/dev/usb/usbdevs Wed Feb 13 08:20:29 2013 (r246752) +++ head/sys/dev/usb/usbdevs Wed Feb 13 08:28:27 2013 (r246753) @@ -1717,6 +1717,7 @@ product FTDI 232H 0x6014 FTDI compatibl product FTDI SERIAL_2232D 0x9e90 FT2232D Dual port Serial product FTDI SERIAL_4232H 0x6011 FT4232H Quad port Serial product FTDI BEAGLEBONE 0xa6d0 BeagleBone +product FTDI KTLINK 0xbbe2 KT-LINK Embedded Hackers Multitool product FTDI TURTELIZER2 0xbdc8 egnite Turtelizer 2 JTAG/RS232 Adapter /* Gude Analog- und Digitalsysteme products also uses FTDI's id: */ product FTDI TACTRIX_OPENPORT_13M 0xcc48 OpenPort 1.3 Mitsubishi _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
Author: hselasky Date: Thu Feb 28 16:43:41 2013 New Revision: 247474 URL: http://svnweb.freebsd.org/changeset/base/247474 Log: MFC r246753: Add new USB ID to FTDI driver. PR: kern/175893 Modified: stable/9/sys/dev/usb/serial/uftdi.c stable/9/sys/dev/usb/usbdevs Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/usb/serial/uftdi.c ============================================================================== --- stable/9/sys/dev/usb/serial/uftdi.c Thu Feb 28 16:39:44 2013 (r247473) +++ stable/9/sys/dev/usb/serial/uftdi.c Thu Feb 28 16:43:41 2013 (r247474) @@ -378,6 +378,7 @@ static const STRUCT_USB_HOST_ID uftdi_de UFTDI_DEV(FTDI, IPLUS2, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, IRTRANS, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, KBS, UFTDI_TYPE_8U232AM), + UFTDI_DEV(FTDI, KTLINK, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, LENZ_LIUSB, UFTDI_TYPE_AUTO), UFTDI_DEV(FTDI, LK202, UFTDI_TYPE_8U232AM), UFTDI_DEV(FTDI, LK204, UFTDI_TYPE_8U232AM), Modified: stable/9/sys/dev/usb/usbdevs ============================================================================== --- stable/9/sys/dev/usb/usbdevs Thu Feb 28 16:39:44 2013 (r247473) +++ stable/9/sys/dev/usb/usbdevs Thu Feb 28 16:43:41 2013 (r247474) @@ -1713,6 +1713,7 @@ product FTDI 232H 0x6014 FTDI compatibl product FTDI SERIAL_2232D 0x9e90 FT2232D Dual port Serial product FTDI SERIAL_4232H 0x6011 FT4232H Quad port Serial product FTDI BEAGLEBONE 0xa6d0 BeagleBone +product FTDI KTLINK 0xbbe2 KT-LINK Embedded Hackers Multitool product FTDI TURTELIZER2 0xbdc8 egnite Turtelizer 2 JTAG/RS232 Adapter /* Gude Analog- und Digitalsysteme products also uses FTDI's id: */ product FTDI TACTRIX_OPENPORT_13M 0xcc48 OpenPort 1.3 Mitsubishi _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
Responsible Changed From-To: freebsd-bugs->freebsd-usb reclassify.
For bugs matching the following criteria: Status: In Progress Changed: (is less than) 2014-06-01 Reset to default assignee and clear in-progress tags. Mail being skipped
A commit references this bug: Author: ian Date: Sun Mar 4 17:30:16 UTC 2018 New revision: 330385 URL: https://svnweb.freebsd.org/changeset/base/330385 Log: Flag the first interface on a KTLINK FTDI-based jtag+uart device as being the jtag port, so that a tty is not created for it. This is based on information in the PR and from the vendor website. When the PR was first opened we had no facility for flagging the jtag ports. I stumbled across the still-open PR with the idea of closing it, and noticed that this wee update was needed. PR: 175893 Changes: head/sys/dev/usb/serial/uftdi.c
A commit references this bug: Author: ian Date: Sun Mar 25 00:50:27 UTC 2018 New revision: 331509 URL: https://svnweb.freebsd.org/changeset/base/331509 Log: MFC r330385: Flag the first interface on a KTLINK FTDI-based jtag+uart device as being the jtag port, so that a tty is not created for it. This is based on information in the PR and from the vendor website. When the PR was first opened we had no facility for flagging the jtag ports. I stumbled across the still-open PR with the idea of closing it, and noticed that this wee update was needed. PR: 175893 Changes: _U stable/11/ stable/11/sys/dev/usb/serial/uftdi.c