From patchwork Fri Aug 27 08:21:11 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rui Miguel Silva X-Patchwork-Id: 503380 Delivered-To: patch@linaro.org Received: by 2002:a02:6f15:0:0:0:0:0 with SMTP id x21csp1039846jab; Fri, 27 Aug 2021 01:21:46 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxZnQdJ1Frr4QIRr0HQUJfjZGKfgGDrau5AAAgH+G+kxN8WUIWeqJ2bmkV1RGhIiLhB7RMN X-Received: by 2002:a05:6402:c05:: with SMTP id co5mr9020868edb.41.1630052506258; Fri, 27 Aug 2021 01:21:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1630052506; cv=none; d=google.com; s=arc-20160816; b=EeDw+qKYPtntH43b3e59ZYSBdXY6MzYRbeY+eWX9N8VB6PrTNIW61czy/oreTpEYK1 /Ww4GVm49j5WCcRbkfMURz+gcObJpV6giDU0nkul9rf5oopniO5BCFC1On3JPtfRpasr 61PJXwEsPOtP6B7SyFuThP+gIEfANzsjC9aby9/ikIlz1d3Rpdn8v68f8lX3FBaiQ9a8 5vCPfrZ8jtQshyiPcSkO8PZ2wZ2QCdHKV7kBSvm0LzaW7UsK7GnvGCmgh/Ne0N3mbxbh 3zg34PG6MLlvjsaVfXV73Ha94RZVDDPao80fasigbKnsLxrdWEN42VIXRAQeJeeLdKkn CMWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=UgrjwbZBiK8ATFB/HhkR7RlMrnctExRtLTvENDbdq94=; b=tdh7ZEbFLgxUn5aMVz0eUp5M4gGsz2vOOfD1bMDFpzDWnZhaVtPvzmTXmYr8KmBF/O YCYi6j63XYUUZ6eg87t84r8BvPsyOiQjf58OMKVz+ukbTl7U0XltY+6eYQnwlshqtqBw OkfusPYrOSCE52f2oJlakERoJD/UpkGEYx4uB6NaipbPxlOM5jO5R6YUBlNRleXXti3F QolTpILmEQAcJYKTa9ZXK2dgxt5I5fBpzvANFBOr5J8/HBiMCRPxkT4irLz/S9r2hZl/ 3m5YH56kmCfWhoqTJJirGeAHX2AkMSMKij5evQir5ynMmkpZJa1EP85WIseNvO7JjFTW iTcA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RKKrGWkE; spf=pass (google.com: domain of linux-usb-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-usb-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n2si6333491edi.195.2021.08.27.01.21.46; Fri, 27 Aug 2021 01:21:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-usb-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=@linaro.org header.s=google header.b=RKKrGWkE; spf=pass (google.com: domain of linux-usb-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-usb-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244505AbhH0IWd (ORCPT + 4 others); Fri, 27 Aug 2021 04:22:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49272 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244565AbhH0IWc (ORCPT ); Fri, 27 Aug 2021 04:22:32 -0400 Received: from mail-wr1-x42c.google.com (mail-wr1-x42c.google.com [IPv6:2a00:1450:4864:20::42c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0E10BC061757 for ; Fri, 27 Aug 2021 01:21:44 -0700 (PDT) Received: by mail-wr1-x42c.google.com with SMTP id h13so9193338wrp.1 for ; Fri, 27 Aug 2021 01:21:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=UgrjwbZBiK8ATFB/HhkR7RlMrnctExRtLTvENDbdq94=; b=RKKrGWkEGecrJkuT7pHn3g3572bO/OIINDgDLRYDRubxiecV5Kps43ZPr+7WsMplk0 mOe28MTwXtol21sEbr+E13nrk8VcG1Hnc7iroJ1zoSJgr9aSv1ykvTMSlpEumta3wY5Q UuHjjbtqIcBXjJg5OqJoMt2IShGZqt+4sqKsV4SB+KcgsT2GAb6Pzhyhgvdby3iib+vm o9H0p/yC1E6UQonTfK3wGUT1dP8DUWXYeXZZqEkf79oXrs0PDUf6w9Onaa75Ee1hpSAC ScPnYGApn4P00fDpmolCrAb1l87jfUzL3LKki961NamH5xJX5hLJGoK9XGU/uWQmUStO EKLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=UgrjwbZBiK8ATFB/HhkR7RlMrnctExRtLTvENDbdq94=; b=Z1zRjeFy/w/dfEXFzY9RR7yStiRatJFFIFqZdvW9MxxyHho/NLzs65jq4yVeklpDZf mxvsCrhooFMxoWdvv7ab/j2B7bGzl15zxHc6IveS5nZwEI7NRdsqNoCt7tBDRqdenOVk CYI0sKhQebUsyedXFvF3+rkdPI+i4VIgm6iEFykHGQFLY04gNHElT1rSFsMdlM1uDEWh FT3IDLf6PQVxZyVVuxayKN1qSfUAf8f8tAXuSGaEbLwqpgAq9qlYhyD0sUz+mm5cX0+c VxTfTyfGslkFuVLz3E0s61eY7dTIUkAVbPxLxQ0iSs4IcXo33MkSGXFwrEZV8Cn8mcZr H8SQ== X-Gm-Message-State: AOAM533cSRCD8g+BMro1lWK7kQPLDbrQiF9nHjoTXo5DVO8DHNQFQLFS g8KXcbgi5VeA08QneR0SVT3rsQ== X-Received: by 2002:a05:6000:184e:: with SMTP id c14mr8732287wri.186.1630052502683; Fri, 27 Aug 2021 01:21:42 -0700 (PDT) Received: from arch-thunder.local (a109-49-46-234.cpe.netcabo.pt. [109.49.46.234]) by smtp.gmail.com with ESMTPSA id y1sm5177725wmq.43.2021.08.27.01.21.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 27 Aug 2021 01:21:42 -0700 (PDT) From: Rui Miguel Silva To: Greg Kroah-Hartman , Dietmar Eggemann Cc: linux-usb@vger.kernel.org, Rui Miguel Silva Subject: [PATCH 4/5] usb: isp1760: use the right irq status bit Date: Fri, 27 Aug 2021 09:21:11 +0100 Message-Id: <20210827082112.4061086-5-rui.silva@linaro.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20210827082112.4061086-1-rui.silva@linaro.org> References: <20210827082112.4061086-1-rui.silva@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org Instead of using the fields enum values to check interrupts trigged, use the correct bit values. Reported-by: Dietmar Eggemann Signed-off-by: Rui Miguel Silva --- drivers/usb/isp1760/isp1760-udc.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) -- 2.33.0 diff --git a/drivers/usb/isp1760/isp1760-udc.c b/drivers/usb/isp1760/isp1760-udc.c index a78da59d6417..5cafd23345ca 100644 --- a/drivers/usb/isp1760/isp1760-udc.c +++ b/drivers/usb/isp1760/isp1760-udc.c @@ -1363,7 +1363,7 @@ static irqreturn_t isp1760_udc_irq(int irq, void *dev) status = isp1760_udc_irq_get_status(udc); - if (status & DC_IEVBUS) { + if (status & ISP176x_DC_IEVBUS) { dev_dbg(udc->isp->dev, "%s(VBUS)\n", __func__); /* The VBUS interrupt is only triggered when VBUS appears. */ spin_lock(&udc->lock); @@ -1371,7 +1371,7 @@ static irqreturn_t isp1760_udc_irq(int irq, void *dev) spin_unlock(&udc->lock); } - if (status & DC_IEBRST) { + if (status & ISP176x_DC_IEBRST) { dev_dbg(udc->isp->dev, "%s(BRST)\n", __func__); isp1760_udc_reset(udc); @@ -1391,18 +1391,18 @@ static irqreturn_t isp1760_udc_irq(int irq, void *dev) } } - if (status & DC_IEP0SETUP) { + if (status & ISP176x_DC_IEP0SETUP) { dev_dbg(udc->isp->dev, "%s(EP0SETUP)\n", __func__); isp1760_ep0_setup(udc); } - if (status & DC_IERESM) { + if (status & ISP176x_DC_IERESM) { dev_dbg(udc->isp->dev, "%s(RESM)\n", __func__); isp1760_udc_resume(udc); } - if (status & DC_IESUSP) { + if (status & ISP176x_DC_IESUSP) { dev_dbg(udc->isp->dev, "%s(SUSP)\n", __func__); spin_lock(&udc->lock); @@ -1413,7 +1413,7 @@ static irqreturn_t isp1760_udc_irq(int irq, void *dev) spin_unlock(&udc->lock); } - if (status & DC_IEHS_STA) { + if (status & ISP176x_DC_IEHS_STA) { dev_dbg(udc->isp->dev, "%s(HS_STA)\n", __func__); udc->gadget.speed = USB_SPEED_HIGH; }