Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752510AbdFUOW3 (ORCPT ); Wed, 21 Jun 2017 10:22:29 -0400 Received: from lelnx193.ext.ti.com ([198.47.27.77]:54903 "EHLO lelnx193.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751711AbdFUOW2 (ORCPT ); Wed, 21 Jun 2017 10:22:28 -0400 Date: Wed, 21 Jun 2017 09:22:15 -0500 From: Bin Liu To: Greg Kroah-Hartman CC: , , "Gustavo A. R. Silva" Subject: Re: [PATCH] usb: musb: compress return logic into one line Message-ID: <20170621142215.GA6187@uda0271908> Mail-Followup-To: Bin Liu , Greg Kroah-Hartman , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, "Gustavo A. R. Silva" References: <20170620202427.GA9078@embeddedgus> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <20170620202427.GA9078@embeddedgus> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1420 Lines: 47 Hi Greg, On Tue, Jun 20, 2017 at 03:24:27PM -0500, Gustavo A. R. Silva wrote: > Simplify return logic to avoid unnecessary variable assignment. > > Signed-off-by: Gustavo A. R. Silva My tree is already closed for v4.13. if you want to pick it up directly, here is my Acked-by, or I will take it for v4.14. Acked-by: Bin Liu Regards, -Bin. > --- > drivers/usb/musb/musb_host.c | 6 ++---- > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/drivers/usb/musb/musb_host.c b/drivers/usb/musb/musb_host.c > index dbe617a..76decb8 100644 > --- a/drivers/usb/musb/musb_host.c > +++ b/drivers/usb/musb/musb_host.c > @@ -1540,7 +1540,7 @@ static int musb_rx_dma_iso_cppi41(struct dma_controller *dma, > struct dma_channel *channel = hw_ep->rx_channel; > void __iomem *epio = hw_ep->regs; > dma_addr_t *buf; > - u32 length, res; > + u32 length; > u16 val; > > buf = (void *)urb->iso_frame_desc[qh->iso_idx].offset + > @@ -1552,10 +1552,8 @@ static int musb_rx_dma_iso_cppi41(struct dma_controller *dma, > val |= MUSB_RXCSR_DMAENAB; > musb_writew(hw_ep->regs, MUSB_RXCSR, val); > > - res = dma->channel_program(channel, qh->maxpacket, 0, > + return dma->channel_program(channel, qh->maxpacket, 0, > (u32)buf, length); > - > - return res; > } > #else > static inline int musb_rx_dma_iso_cppi41(struct dma_controller *dma, > -- > 2.5.0 >