Received: by 2002:a05:6358:e9c4:b0:b2:91dc:71ab with SMTP id hc4csp4263203rwb; Sun, 7 Aug 2022 19:43:46 -0700 (PDT) X-Google-Smtp-Source: AA6agR7F3Lwn3ysE9DZXEjjjN18DwtdISnqI5HSaeZ17WmNaoeI88C+FtpXN+zfc9ji24AWX0I5N X-Received: by 2002:a17:906:93f0:b0:730:6b07:102d with SMTP id yl16-20020a17090693f000b007306b07102dmr12273644ejb.237.1659926626708; Sun, 07 Aug 2022 19:43:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659926626; cv=none; d=google.com; s=arc-20160816; b=Us//78k7YMRjZmvQCzDOHPcIEre3+uf2ovnqsSdcVI9OsV/bBhevrVJ8wXoKunSCnE RLZZOK1yRTV3Sxgt7VTdMWpqHcRLqN+g0/AUYK19gk+/uLLokY0r9sVuND9hnvhIBRwz gtVEDV0DOtoRW/J2ilBprAAH1y/EOu+MW2DRKaC2b0TbfECnjIl6Z+CP0jwvIZGMZyk9 7I1rzoVkMVgFqDmK1AcwTRw/3WWVRJPNxo0/5qSf7IrY7xeesi8d+2tNV5A1MZbY5XmH sranAi8OBTiMzvneXG9x6G481vmPwnbmHYqGrdrAuzB/IZnoorUP3u1tQSWTFjyD1iyz UiKw== 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 :message-id:date:subject:cc:to:from; bh=Sv8Wzi+masdUxvhF8UrU9lHJdOXvXkCg1mQD23uY2QE=; b=X5QLMeZYjS1Gq/FmWzHtPKHFv13ZW8Q5lhe9Qa6rmnh61tFhDsfeY9/VFSwCY2E+aa ppbAUA3970clWHltyZ6PQquV+6GQwWHmmbAs/JjDh8vtTRlEg6ikw39qCXqS0O8uVFuX QuKTkzer3/qeLxWKQDtaDToKvSkHl01k82b8wPd+GFYHRQEBCEOvRK39YZOduVsd1kty G92CvaQwUNda9VQ0a1bJdS/ZSSe9BxtByZNxPD3wDbA496zgZpvpAZ2Rd4TzxmdOorYn sYYdBIIlFRFXbBmjK8/KMCqtiGtPHtX9qnL1CVHkKFIQbkSGsWxm6IZ427Po42rWzzQj r63g== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i7-20020a50c3c7000000b0043e42b0f87asi5302094edf.306.2022.08.07.19.43.22; Sun, 07 Aug 2022 19:43:46 -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; 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=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236056AbiHHBKC (ORCPT + 99 others); Sun, 7 Aug 2022 21:10:02 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49154 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229462AbiHHBKA (ORCPT ); Sun, 7 Aug 2022 21:10:00 -0400 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5827410A8; Sun, 7 Aug 2022 18:09:57 -0700 (PDT) Received: from dggpemm500021.china.huawei.com (unknown [172.30.72.54]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4M1J1y3P1kzjXXM; Mon, 8 Aug 2022 09:06:46 +0800 (CST) Received: from dggpemm500001.china.huawei.com (7.185.36.107) by dggpemm500021.china.huawei.com (7.185.36.109) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Mon, 8 Aug 2022 09:09:55 +0800 Received: from localhost.localdomain.localdomain (10.175.113.25) by dggpemm500001.china.huawei.com (7.185.36.107) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Mon, 8 Aug 2022 09:09:54 +0800 From: Kefeng Wang To: Mathieu Poirier , Julien Massot , Bjorn Andersson , CC: Geert Uytterhoeven , , , Kefeng Wang , kernel test robot Subject: [PATCH] remoteproc: rcar_rproc: silince address space sparse warning Date: Mon, 8 Aug 2022 09:16:09 +0800 Message-ID: <20220808011610.188119-1-wangkefeng.wang@huawei.com> X-Mailer: git-send-email 2.35.3 MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.113.25] X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To dggpemm500001.china.huawei.com (7.185.36.107) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, 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 Fix sparse warnings, drivers/remoteproc/st_remoteproc.c:98:12: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected void *va @@ got void [noderef] __iomem * @@ drivers/remoteproc/st_remoteproc.c:98:12: sparse: expected void *va drivers/remoteproc/st_remoteproc.c:98:12: sparse: got void [noderef] __iomem * ... drivers/remoteproc/st_remoteproc.c:114:20: sparse: expected void volatile [noderef] __iomem *io_addr drivers/remoteproc/st_remoteproc.c:114:20: sparse: got void *va Add __iomem to io address space 'va' to fix it. Reported-by: kernel test robot Signed-off-by: Kefeng Wang --- note: the commit d803336abdbc "(ARM: mm: kill unused runtime hook arch_iounmap())" won't introduce the warning, but lkp report issue to me many times, let's fix it. drivers/remoteproc/rcar_rproc.c | 2 +- include/linux/remoteproc.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/remoteproc/rcar_rproc.c b/drivers/remoteproc/rcar_rproc.c index aa86154109c7..e3363a4cde0a 100644 --- a/drivers/remoteproc/rcar_rproc.c +++ b/drivers/remoteproc/rcar_rproc.c @@ -22,7 +22,7 @@ static int rcar_rproc_mem_alloc(struct rproc *rproc, struct rproc_mem_entry *mem) { struct device *dev = &rproc->dev; - void *va; + void __iomem *va; dev_dbg(dev, "map memory: %pa+%zx\n", &mem->dma, mem->len); va = ioremap_wc(mem->dma, mem->len); diff --git a/include/linux/remoteproc.h b/include/linux/remoteproc.h index 7c943f0a2fc4..c0c950cf7d72 100644 --- a/include/linux/remoteproc.h +++ b/include/linux/remoteproc.h @@ -330,7 +330,7 @@ struct rproc; * @alloc: specific memory allocator function */ struct rproc_mem_entry { - void *va; + void __iomem *va; bool is_iomem; dma_addr_t dma; size_t len; -- 2.35.3