From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755349AbbKRI1u (ORCPT ); Wed, 18 Nov 2015 03:27:50 -0500 Received: from mail-wm0-f67.google.com ([74.125.82.67]:36825 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752098AbbKRI1t (ORCPT ); Wed, 18 Nov 2015 03:27:49 -0500 Date: Wed, 18 Nov 2015 09:27:44 +0100 From: Dave Penkler To: Andy Shevchenko Cc: Greg Kroah-Hartman , peter.chen@freescale.com, teuniz@gmail.com, USB , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH v4 5/5] Add ioctls to enable and disable local controls on an instrument Message-ID: <20151118082744.GB1776@slacky> References: <20151115183438.GA1585@slacky> <20151115184004.GE1592@slacky> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Nov 15, 2015 at 10:10:35PM +0200, Andy Shevchenko wrote: > On Sun, Nov 15, 2015 at 8:40 PM, Dave Penkler wrote: > > These ioctls provide support for the USBTMC-USB488 control requests > > for REN_CONTROL, GO_TO_LOCAL and LOCAL_LOCKOUT > > > > + > > + dev = &data->intf->dev; > > Could be assigned above. > ok > > + wValue = (val) ? 1 : 0; > > Redundant parens. > ok > > + rv = -EIO; > > Hmm??? Does usb_control_msg() return a proper error code? If it does, > perhaps better to propagate it. > You are right. > > + rv = -EIO; > > + goto exit; > > > + } else { > > Redundant else. > OK > Thanks, -Dave