Received: by 2002:a05:6520:4211:b029:f4:110d:56bc with SMTP id o17csp2112761lkv; Thu, 20 May 2021 03:42:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzMLW+klPOSi9B1MP6rj/QaA6FJZscR4Gr9AY3Xbh6dfXPes5ILeHMHmx7bwY8/sRq5bBNP X-Received: by 2002:a5d:8188:: with SMTP id u8mr4882138ion.163.1621507367274; Thu, 20 May 2021 03:42:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621507367; cv=none; d=google.com; s=arc-20160816; b=akMBMhdp3CwTE5/Gs+kGHjnigfNFFbI7nnSCSdhhEcM8z6/aMSWaCNpJYBarBvTATL DFh3vtp8a8Egq3KF1WIF49Ph49bWq9hMC6AWzy+1kENR4e6gzAMmHQFwDfTVJGbIgNsC b3YApnwBukyXTGqoxVGqt0BiA0Qzx89xmJLLShkRrTI4Pvq7dy9/S5OjTKsnwP/1m711 eo9kJ+czDqXrQBDCsfD1V4HudS1Fklttm3DjIlEI/J+dZOx2sjqBZ2LlMtUvnonuACXF IXsp5XihpoBw8+8Ia/0WJj5EbY42HgSRY0ipbjeZzNQtgglhEmxdQCN5u5EM4dAVRSZN 4acw== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=t1pj4UeG9T1sx1nXDBCSWlUdUMiZUz9cniaiZXBvw8g=; b=dT4IDjZHurVIF9hdt7sbyeWkJv4scXrZKogtHJYMBnYhm0Y1VsJ1v9SCdei7ZUDu1f WAH0BY/FPo7uZF/tHwZCKJHnF/13DZ0HAc8v4j85QqUe68kIAd4iuz99dqJwqeAFQSU2 litFISJjFSeWov7n+riyptF8oH6BzKpo/4ZkelH48Yw3NoTo2C1cNpUKj6scTJorWsC+ JpM8vbbv68OhTxV3HAEl/iOmEJ9gTuwOlFOZSyk6XCz5XNFfd6GplKxTftNPurbREkPW bngyxkZEkjNw9TRHjRUvIgfNX0jLQUeY4CWNV03pmovd6VjP4iwkAdPAxZb4YJaimrsG 4tCQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=G9HeI948; 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=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q15si330387jar.110.2021.05.20.03.42.11; Thu, 20 May 2021 03:42:47 -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=@linuxfoundation.org header.s=korg header.b=G9HeI948; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236698AbhETKmL (ORCPT + 99 others); Thu, 20 May 2021 06:42:11 -0400 Received: from mail.kernel.org ([198.145.29.99]:55848 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236558AbhETK0i (ORCPT ); Thu, 20 May 2021 06:26:38 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 36D5E61C1A; Thu, 20 May 2021 09:50:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1621504217; bh=+TE8acqv6xCpV22VvyuVSpnEz7qAgjuLyllQU6XRa1Q=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=G9HeI948QJux7xTISG51Y6Xe//ywCGyX+6Qe63Du2EtG5kwIgojwm3Zr+nGC/OabX XBqWAYLce8ZYuEo8d1lErdIeOi0847DlFWfY95E+27NbQ/yjZp21LO8moKi7tIaG/l 9+nVQPHd3KVdRtec/9TOt+CBNmJDxffX3lCWO7NM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Andy Shevchenko , Sasha Levin Subject: [PATCH 4.14 146/323] usb: gadget: pch_udc: Replace cpu_to_le32() by lower_32_bits() Date: Thu, 20 May 2021 11:20:38 +0200 Message-Id: <20210520092125.102560587@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210520092120.115153432@linuxfoundation.org> References: <20210520092120.115153432@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Andy Shevchenko [ Upstream commit 91356fed6afd1c83bf0d3df1fc336d54e38f0458 ] Either way ~0 will be in the correct byte order, hence replace cpu_to_le32() by lower_32_bits(). Moreover, it makes sparse happy, otherwise it complains: .../pch_udc.c:1813:27: warning: incorrect type in assignment (different base types) .../pch_udc.c:1813:27: expected unsigned int [usertype] dataptr .../pch_udc.c:1813:27: got restricted __le32 [usertype] Fixes: f646cf94520e ("USB device driver of Topcliff PCH") Signed-off-by: Andy Shevchenko Link: https://lore.kernel.org/r/20210323153626.54908-1-andriy.shevchenko@linux.intel.com Signed-off-by: Greg Kroah-Hartman Signed-off-by: Sasha Levin --- drivers/usb/gadget/udc/pch_udc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/gadget/udc/pch_udc.c b/drivers/usb/gadget/udc/pch_udc.c index 8d3cbca9f926..e9c2f67a8b10 100644 --- a/drivers/usb/gadget/udc/pch_udc.c +++ b/drivers/usb/gadget/udc/pch_udc.c @@ -1786,7 +1786,7 @@ static struct usb_request *pch_udc_alloc_request(struct usb_ep *usbep, } /* prevent from using desc. - set HOST BUSY */ dma_desc->status |= PCH_UDC_BS_HST_BSY; - dma_desc->dataptr = cpu_to_le32(DMA_ADDR_INVALID); + dma_desc->dataptr = lower_32_bits(DMA_ADDR_INVALID); req->td_data = dma_desc; req->td_data_last = dma_desc; req->chain_len = 1; -- 2.30.2