Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752331AbdI1IxX (ORCPT ); Thu, 28 Sep 2017 04:53:23 -0400 Received: from mail-eopbgr10084.outbound.protection.outlook.com ([40.107.1.84]:27520 "EHLO EUR02-HE1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751592AbdI1IxT (ORCPT ); Thu, 28 Sep 2017 04:53:19 -0400 From: Oleksandr Shamray To: Geert Uytterhoeven CC: Greg KH , Arnd Bergmann , "linux-kernel@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "devicetree@vger.kernel.org" , "openbmc@lists.ozlabs.org" , Joel Stanley , Jiri Pirko , Tobias Klauser , "linux-serial@vger.kernel.org" , "mec@shout.net" , Vadim Pasternak , system-sw-low-level , Rob Herring , "openocd-devel-owner@lists.sourceforge.net" , "linux-api@vger.kernel.org" , "David S. Miller" , "Mauro Carvalho Chehab" , linux-spi , Mark Brown Subject: RE: [patch v9 0/4] JTAG driver introduction Thread-Topic: [patch v9 0/4] JTAG driver introduction Thread-Index: AQHTMru4M5azt7XbqEuLkdSxxS/sN6LKA2cAgAAE/MA= Date: Thu, 28 Sep 2017 08:53:12 +0000 Message-ID: References: <1505985932-27568-1-git-send-email-oleksandrs@mellanox.com> In-Reply-To: Accept-Language: en-US, uk-UA Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=oleksandrs@mellanox.com; x-originating-ip: [80.90.224.13] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;HE1PR05MB3339;6:q+k/swSyvnXMeIADVfddUZ4/QfGRNAJI6qPB0CJ0I1OjU6p82DZm7/vOSHUzBJsUsXxtcNCmKWNUigc977ldy4l1rC0Hou/rok49BXphXP0LbtcYZNpLaNoLxT4+NaHdSCDZcMM1B2BLbRYQQigSepww3O2kCSSgX5HgkTXEu5kEjK+R4I0J4j1VEHCdp9cZjry+fyBkUV7AZZUdDVLgrdqkb4ALvLybuR5ptQ69j33AuCBAsHHNxA9buf2/j2C+9G0VI7+UGUErYnMZ6JegrYyJTLjbMJ2iB1XrBQKaGZMJoCVesukXsDZ5e7QZrziifssW1RFz2Fg1iYbzWWcvyQ==;5:ClwoVo+Fk+rAlj2RvFhpZbaZsuDNiVbgp7fgs6CnzzkV/Oh//r39zG6QNMsNgfk0LoE+sqvySpMdYt9K2b0xwnL7qCPatl8LyRCNH07PZMAbddU/oBM8fqsYsYLC7hI2Uj/hRv/vIhrbiNytJX7DGw==;24:6LRVj4bt+W3GL5mjMPHnEpIIrfwBHwVxoEJ3nQ8cLhfXrjGlZEyo/XQJZvouI+tQgmIHbaKKrRb658/7w8wM0Di0qyT8MoqIvp2epQwSwjI=;7:HuJvL1dSsp07gbzfpDyapcaFWIOPplqDMGWThQvVCREjAd7HK/CWtGnnxH23kGAkDVlz3RUnf9N/BFf0pOZ7sm2YN6W+LtrLMHX6qxitS5BkKxw+pZy/WAEV64Il07X0GUSEG8vQhgH3B6BAoHkUiTDu9PC9wiy63L2IudefHLwnyRWLpAnWa5nMrTeED0pKO9Lm0PogzB+nR+aVHVufPTN0Hmai0ZhDuwCmEeRqKxg= x-ms-office365-filtering-correlation-id: dee184af-35ab-403f-a408-08d5064e59c3 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(22001)(2017030254152)(48565401081)(2017052603199)(201703131423075)(201703031133081)(201702281549075);SRVR:HE1PR05MB3339; x-ms-traffictypediagnostic: HE1PR05MB3339: x-exchange-antispam-report-test: UriScan:(143289334528602)(9452136761055)(189930954265078)(65623756079841)(258649278758335)(42262312472803)(45079756050767); x-microsoft-antispam-prvs: x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(2401047)(8121501046)(5005006)(93006095)(93001095)(10201501046)(3002001)(100000703101)(100105400095)(6055026)(6041248)(20161123558100)(20161123555025)(20161123560025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123564025)(20161123562025)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095);SRVR:HE1PR05MB3339;BCL:0;PCL:0;RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);SRVR:HE1PR05MB3339; x-forefront-prvs: 0444EB1997 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(6009001)(376002)(346002)(39860400002)(13464003)(24454002)(199003)(189002)(377454003)(55016002)(101416001)(14454004)(7736002)(6246003)(105586002)(7696004)(305945005)(97736004)(106356001)(5250100002)(966005)(3660700001)(6306002)(86362001)(45080400002)(9686003)(3280700002)(2950100002)(6506006)(53546010)(99286003)(189998001)(5660300001)(478600001)(2900100001)(53936002)(8676002)(81156014)(316002)(25786009)(54356999)(50986999)(76176999)(8936002)(81166006)(7416002)(33656002)(68736007)(54906003)(66066001)(6916009)(74316002)(3846002)(6436002)(2906002)(229853002)(4326008)(102836003)(6116002);DIR:OUT;SFP:1101;SCL:1;SRVR:HE1PR05MB3339;H:AM4PR0501MB2194.eurprd05.prod.outlook.com;FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-originalarrivaltime: 28 Sep 2017 08:53:12.4284 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR05MB3339 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by nfs id v8S8rSUj005109 Content-Length: 3060 Lines: 70 > -----Original Message----- > From: geert.uytterhoeven@gmail.com [mailto:geert.uytterhoeven@gmail.com] > On Behalf Of Geert Uytterhoeven > Sent: Thursday, September 28, 2017 11:33 AM > To: Oleksandr Shamray > Cc: Greg KH ; Arnd Bergmann > ; linux-kernel@vger.kernel.org; linux-arm- > kernel@lists.infradead.org; devicetree@vger.kernel.org; > openbmc@lists.ozlabs.org; Joel Stanley ; Jiri Pirko > ; Tobias Klauser ; linux- > serial@vger.kernel.org; mec@shout.net; Vadim Pasternak > ; system-sw-low-level level@mellanox.com>; Rob Herring ; openocd-devel- > owner@lists.sourceforge.net; linux-api@vger.kernel.org; David S. Miller > ; Mauro Carvalho Chehab ; > linux-spi ; Mark Brown > Subject: Re: [patch v9 0/4] JTAG driver introduction > > Hi Oleksandr, > > [My attention was drawn by > https://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flwn.net > %2FArticles%2F734440%2F&data=02%7C01%7Coleksandrs%40mellanox.com%7 > C97b8ba88686a42daaace08d5064b92eb%7Ca652971c7d2e4d9ba6a4d149256f > 461b%7C0%7C0%7C636421844026854216&sdata=TeHD4a3%2FBN6a5XG3Jizf5 > pmsyJHJjzkEzkpnqsXC6S0%3D&reserved=0] > [CC linux-spi, which was never included, while linux-serial was] > > On Thu, Sep 21, 2017 at 11:25 AM, Oleksandr Shamray > wrote: > > When a need raise up to use JTAG interface for system's devices > > programming or CPU debugging, usually the user layer application > > implements jtag protocol by bit-bang or using a proprietary connection > > to vendor hardware. > > This method can be slow and not generic. > > [..] > > > > Initial version provides the system calls set for: > > - SIR (Scan Instruction Register, IEEE 1149.1 Data Register scan); > > - SDR (Scan Data Register, IEEE 1149.1 Instruction Register scan); > > - RUNTEST (Forces the IEEE 1149.1 bus to a run state for a specified > > number of clocks. > > > > SoC which are not equipped with JTAG master interface, can be built on > > top of JTAG core driver infrastructure, by applying bit-banging of > > TDI, TDO, TCK and TMS pins within the hardware specific driver. > > Or by using an SPI master? > I think it depends on how flexible the SPI interface is. If you can set it to transfer from 1 to n bits at a time, and you control the TMS line in software, you should be able to use it. If the SPI interface can only transfer a multiple of 8 bits at a time, then in general it would not be suitable for JTAG. > Gr{oetje,eeting}s, > > Geert > > -- > Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux- > m68k.org > > In personal conversations with technical people, I call myself a hacker. But > when I'm talking to journalists I just say "programmer" or something like that. > -- Linus Torvalds