Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp317297rwb; Thu, 11 Aug 2022 01:58:10 -0700 (PDT) X-Google-Smtp-Source: AA6agR6wGOWM9A6lKpbFHdxc9dY71xJ51YQSMF15qiq9vrky2cWbbbRtV4PHTIcPbQpFExAg3NLr X-Received: by 2002:a17:907:7609:b0:730:d70a:1efc with SMTP id jx9-20020a170907760900b00730d70a1efcmr23260289ejc.766.1660208290678; Thu, 11 Aug 2022 01:58:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660208290; cv=none; d=google.com; s=arc-20160816; b=x/jX2Y403Ml968hXyYnSrMoO1Nn8BGs7L/ob7W4pb5aC3UY7FxCVsJo+WpKLVoC1IU rCIDlV8qcANt9RNgvNE4agua9bB6LU2oFTcYXrZYw2D9fPf7sw7uPu5bsGpSzZgL3jR+ gzAK45Dz1jJeuVWBe+mYVj5oqtuA3EVPa6sv4/3B/nExcgOFrMj3o3X1gYL8s2CGvw7/ 7vj73Uk5MbOEyEvHpiPjHj1ubNsZt9MbooiuLyQ//XMpB1Ae/pOmO+zu7nP2Jy50dPf9 TVDKUF0j3aBxlrxPCojhobQB/cqgoEvJMH7GvM1sUVxQCCv7hEXawBV0YJdVXqiRVplv Ymzg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=XGli2sqy7pyGO8D22lOArVMZl7h2yHXlWEY/lzM8Z/U=; b=uI8s+hYhR/6Wke5Xdgbwxu7oVehQYkL6qCueBPbuQHq8/GQwoPwHAMQTJK6fSouFFb bjK5gCLni996HeuYC/7xXUTAdnCkJrcynu5EgXOJWNkLIEBD2y1suWlA5FoAyHpkN43y 9ui843Q+YmX6sAVUWGibig+0rOJlChecAJkvTGcyjDsMZYKpKKc473yDlsoboiOwIEAG BHqbzoMDX8da+L2xTh2NRdeQw7JYD3VIorVKnBt8HP+7N9IhJUTcXXX79xW1u3u0Jofd TkVwdH9bcA5l02g1z1rMBo895YiycxXIqHwggyAHfYkRwKj05ZjFc+NxdSEuejfOMSpV D0zg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=0ly7D1f2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g2-20020a1709067c4200b007317d093e6esi5729415ejp.822.2022.08.11.01.57.45; Thu, 11 Aug 2022 01:58:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=0ly7D1f2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234340AbiHKIV2 (ORCPT + 99 others); Thu, 11 Aug 2022 04:21:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56464 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232987AbiHKIV0 (ORCPT ); Thu, 11 Aug 2022 04:21:26 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DEEDA4B0D2; Thu, 11 Aug 2022 01:21:25 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 8DEF7B81EAD; Thu, 11 Aug 2022 08:21:24 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B7DE0C433D6; Thu, 11 Aug 2022 08:21:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660206083; bh=YdAqCSEiuaimqjtzakAUs0wmafOpgYzAjMzlOl9rbug=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=0ly7D1f2c/aXgEW+njjbL8ouCrq3ETCt+6iB510jhlHXO04ATG306ObAwjaT96XCh tJHB5MtMaDBUewX/czZL88LPwmiqLgt/ZAGHMvncJcBTUlQb+s12zzcI6wRJUpLldj lSVz5VRIdffJP8dFlekfl2dkbJwC9WdFGTk68KKc= Date: Thu, 11 Aug 2022 10:21:20 +0200 From: Greg KH To: Zhou jie Cc: johan@kernel.org, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, kernel@nfschina.com Subject: Re: [PATCH] usb/serial:Modify the return value to void Message-ID: References: <20220811070358.5472-1-zhoujie@nfschina.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220811070358.5472-1-zhoujie@nfschina.com> X-Spam-Status: No, score=-7.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Aug 11, 2022 at 03:03:58PM +0800, Zhou jie wrote: > Modify the return value to void,The return value is not used elsewhere. > > Signed-off-by: Zhou jie > --- > drivers/usb/serial/mos7720.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/usb/serial/mos7720.c b/drivers/usb/serial/mos7720.c > index 1e12b5f30dcc..ddb3a2d0f819 100644 > --- a/drivers/usb/serial/mos7720.c > +++ b/drivers/usb/serial/mos7720.c > @@ -239,13 +239,12 @@ static int read_mos_reg(struct usb_serial *serial, unsigned int serial_portnum, > > #ifdef CONFIG_USB_SERIAL_MOS7715_PARPORT > > -static inline int mos7715_change_mode(struct mos7715_parport *mos_parport, > +static inline void mos7715_change_mode(struct mos7715_parport *mos_parport, > enum mos7715_pp_modes mode) > { > mos_parport->shadowECR = mode; > write_mos_reg(mos_parport->serial, dummy, MOS7720_ECR, > mos_parport->shadowECR); > - return 0; Why not check the return value of write_mos_reg() and properly handle the error that can give you instead of ignoring it? thanks, greg k-h