Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp584937ybz; Wed, 29 Apr 2020 05:53:44 -0700 (PDT) X-Google-Smtp-Source: APiQypKqSYo5KSdTIPpWBIr8ImwCBJZpKpkAumd5arpX6J0coiZTcMrdf3wPRCbxNeIuJt2X0W9o X-Received: by 2002:a17:906:f13:: with SMTP id z19mr2429619eji.380.1588164824297; Wed, 29 Apr 2020 05:53:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588164824; cv=none; d=google.com; s=arc-20160816; b=0M9zVs3tUcO/W71epi4WYOgxua1lx7+zKvN/z/sEvWiickwNDTKrwUki7F833jbVp7 MwWwirl5hWbyqs0PKynMreqj5nj3i8RKSq1UYs1gfBBxaXhx5W3xgwr/LbjtjG2c/xVn EgNnpUlqh4tPIVdclLSmJFfsQ54fq0fFJiSqLocZOyQtaiBGTJOG85ZFFbqERjjATBF+ 4K7nA9MIn4YZ5csvt4BZRziktsHyOGBW/cHe5Q9UNGx+m8qA/s4krOLfOWxd0L8b5/GQ aL1F0Zj+3l0/h0UtiOpN+c3n4N3bzhdvoI19zxhOQL1MdBS1uQat+eQB9I99kRVihVl/ yYZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=ivnBh7cQnPKDXZ1BNPEaQBz6cm3V7dV+dAs3gYipJoE=; b=QSR0Z+TrmVohUzlag6kwPgAbrB2bX+3kJuY2yOW16i+jJEPpP9iUgAoTh8zdQJPsFE SwI4TozaSockFcI4/pP8bclfDJ9Wv9G9vP26cEOUAN9Zm1gsLfDfoCRjTDIcBujfaVBe bMtIV5j75U548Fjjac8eVRUEnWDVktr6Q5qjw0egfon7FfgY1DfjzLYiTFpMRbYTDN3B f+JtPqV5OCZG7KJqF4eNBXqlBNRYNsex4+/enwIgRkN25DptnWOhXHampneEKYCpZ3Lb Z5O9aJMnRJIconRWvVPbt0Dq2hG1GEGuuWgMGxnPqRsMJAwGi3hnBBGx54L8ErFVfyrj KUog== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=eMecHkiJ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u1si3606720ejt.47.2020.04.29.05.53.19; Wed, 29 Apr 2020 05:53:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=eMecHkiJ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727068AbgD2Mt2 (ORCPT + 99 others); Wed, 29 Apr 2020 08:49:28 -0400 Received: from mail.kernel.org ([198.145.29.99]:47730 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726599AbgD2Mt1 (ORCPT ); Wed, 29 Apr 2020 08:49:27 -0400 Received: from Mani-XPS-13-9360 (unknown [157.46.25.26]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id E45F42085B; Wed, 29 Apr 2020 12:49:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1588164567; bh=5/wUlfpAFr+xk1jHyr+vgbwi2/B7/efoDXjCT+3aLqI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=eMecHkiJKNNyePhQP3DvfOk7uu5YZDOt0LgHqh0CtMnlxIELsjmyJeEsCjdb5ShOU mEMFFBGsIvXgRq4JdccWJqSq2uIChJq8rYu86j0VxWSPmItZpJDWIc8gYt8Ojt0RBu aWkLhBEj6bhnIbh/lMVzg7vk5PA7Ap948+JakX58= Date: Wed, 29 Apr 2020 18:19:18 +0530 From: Manivannan Sadhasivam To: Linus Walleij Cc: Johan Hovold , Greg KH , linux-usb , "linux-kernel@vger.kernel.org" , patong.mxl@gmail.com, "open list:GPIO SUBSYSTEM" Subject: Re: [PATCH 2/2] usb: serial: xr_serial: Add gpiochip support Message-ID: <20200429124918.GC6443@Mani-XPS-13-9360> References: <20200428195651.6793-1-mani@kernel.org> <20200428195651.6793-3-mani@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Linus, On Wed, Apr 29, 2020 at 02:12:24PM +0200, Linus Walleij wrote: > On Tue, Apr 28, 2020 at 9:57 PM wrote: > > > From: Manivannan Sadhasivam > > > > Add gpiochip support for Maxlinear/Exar USB to serial converter > > for controlling the available gpios. > > > > Cc: Linus Walleij > > Cc: linux-gpio@vger.kernel.org > > Signed-off-by: Manivannan Sadhasivam > > That's a nice and clean GPIO driver. Thanks for the compliments :) > > I would change this: > > port_priv->gc.label = "xr_gpios"; > > to something that is device-unique, like "xr-gpios-" > which makes it easy to locate the GPIOs on a specific serial converter > for lab use. However the USB serial maintainers know better what > to use here. Whatever makes a USB-to-serial unique from a TTY > point of view is probably fine with me too. > > My idea is that people might want to know which USB cable > this is sitting on, so I have this USB cable and from this label > I can always figure out which GPIO device it is. > Sounds reasonable. I can postfix the PID as below: port_priv->gc.label = devm_kasprintf(port->dev, GFP_KERNEL, "XR%04x", port_priv->idProduct); So this will become, "XR1410". > Either way, it is not a super-big issue so: > Reviewed-by: Linus Walleij > > Is this a off-the-shelf product that can be bought or is it mainly > integrated on boards? > Both I believe, though I have only used it integrated in dev boards. But a quick googling gives me below, https://www.digikey.in/product-detail/en/maxlinear-inc/XR21V1410IL-0C-EB/1016-1425-ND/2636664 Thanks, Mani > I'm asking because I'm looking for a neat USB-to-serial adapter > with some GPIOs (2 is enough) that can be used for reset and > power cycling of lab boards using one simple piece of equipment. > > Yours, > Linus Walleij