Received: by 2002:a25:868d:0:0:0:0:0 with SMTP id z13csp548613ybk; Fri, 15 May 2020 07:32:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzyjd8oGhr4vGouKSqwWs+E1mWBxizMZkKjAtLs2mNktjHa8fhAKFbSTXIQDJ7Bf0YnzpVN X-Received: by 2002:a17:906:7256:: with SMTP id n22mr2964442ejk.31.1589553169628; Fri, 15 May 2020 07:32:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1589553169; cv=none; d=google.com; s=arc-20160816; b=rLhL/U40nwiFbQ2Dx2RkPkwf7AkoziLzFR9sgy4fecuGqaW1DnTKl+EgyVNdKHW5Tt 93rzlKk/8lLC0UGy5FOYyZdE21drPme92WzsFVdFKoclrGHRrtix1IBFYrkb+Q8AhlGP 4nuYc4oQ0X21o3GO/cE7HZq9vG9PZT/2Bc8xd6rpGWp0HrcnY8iXNxm2YjY08ollU13Z 2EbbGk+auHtNKoagM8pppV40NrB43bYql5E10iI274sna9hYhxxak8ci9nUqqZNlRV+J UYYZi+e4noF4TKwMZfp0yRcGbhROT4pDucfPhHQJSA0Zzk1SdHYU2dkvX1wcJ5K02V5k uqdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version; bh=sB61sr2V2fLhAUqSA7RU8JnpQZ7Y26BcnaBq4DpN0eY=; b=J1fOPCj9gkPMC1QKo7smOCrVwI0aziZKambEhxXhnapY2vQqeSR1ZW9NRoPy6Vhcix aFvKoCiVDqqUZIO70V8xz4jBLRLatZwvcCYBa0PFtN9g2IbNR7JmbWvjHWsFgwwdqmd7 smanbz0KL/CZxJToHtCDhWjdhlcmNFbaDYYY4vQV+qUvfqGq5n885LC5MgoAqKT7m9q1 tg2nF2zY9xDuCwDALQr3OQeQ+/G42QhMN/R9VN80ERoc4lElqvnNb5KYUldNYV+3I/Zs KE1nwTHwbZsIbTHoejpNbh+T+Wxrs6JV2cA1xrY1+1U+3b7+IopcbPaa/mqWDEZdLhOa G+AA== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id 91si1365654eda.514.2020.05.15.07.32.25; Fri, 15 May 2020 07:32:49 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726304AbgEOOap (ORCPT + 99 others); Fri, 15 May 2020 10:30:45 -0400 Received: from mout.kundenserver.de ([212.227.126.134]:50191 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726160AbgEOOao (ORCPT ); Fri, 15 May 2020 10:30:44 -0400 Received: from mail-qk1-f170.google.com ([209.85.222.170]) by mrelayeu.kundenserver.de (mreue010 [212.227.15.129]) with ESMTPSA (Nemesis) id 1Mzydy-1jBtXI2Xgs-00x30o; Fri, 15 May 2020 16:30:42 +0200 Received: by mail-qk1-f170.google.com with SMTP id g185so2686971qke.7; Fri, 15 May 2020 07:30:42 -0700 (PDT) X-Gm-Message-State: AOAM531OacSyEhjr9MnZhauVdXCmOp2RQ//M8wvrjfb3P6Y8XgeWoeJ5 OYPXhkPxkfmVJdTbSDGfwALqh9F/u69gJ5uLeio= X-Received: by 2002:ae9:ed95:: with SMTP id c143mr3652955qkg.394.1589553041352; Fri, 15 May 2020 07:30:41 -0700 (PDT) MIME-Version: 1.0 References: <20200515105537.4876-3-vadivel.muruganx.ramuthevar@linux.intel.com> <202005152142.AWvx4xc5%lkp@intel.com> In-Reply-To: From: Arnd Bergmann Date: Fri, 15 May 2020 16:30:24 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v7 2/2] mtd: rawnand: Add NAND controller support on Intel LGM SoC To: Andy Shevchenko Cc: kbuild test robot , "Ramuthevar,Vadivel MuruganX" , Linux Kernel Mailing List , "open list:MEMORY TECHNOLOGY..." , devicetree , kbuild-all@lists.01.org, Miquel Raynal , Richard Weinberger , Vignesh R , Brendan Higgins , Thomas Gleixner , Boris Brezillon , Anders Roxell , masonccyang@mxic.com.tw Content-Type: text/plain; charset="UTF-8" X-Provags-ID: V03:K1:fyohI0+hw5ytppZoJZd/XmCfZsfVnsd6n3zCOrkbrMezdv5+tyv X1oZ3f8TWbSVCNojpAAANE3s9hgV+BHNP6LkVn4/ajz1awkSkBB7fedgKs+pvRHGmEspvOQ jIGR32OYo7AlhTB7FgCuUi80L3JUzvCcl+jMKYwZQ6cmhfpfv3ShlvuZJfHT5Byb82ei67p M+8eac3TrEcNMivY2Nepg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:Dytqvl0/TSg=:Yo6IWW/ehKu/h4tnfwlLhl RTdaJMBmzma5uU2CHUAkNAZehZJ7HWaQvpUdyYFWBqRmBGLhPklkjexn5yi22aFSwLUsNmNoX 45+joPlil9ynwS7gQN1zx3Z/fxUKGCVbwte8Dp5Hmw0W3DrGUP9XRKHzQ7ryJ031Iu44CLvLH AC4EdILA++cw0ohjiIgMiDHCjUkWXLlhAwolpN/cqEYA9YHFhZG9NiI1k7LeeaHPIb5PE1wsy 5nZxc4/BRJq1myYyh5pcUmdnOuPQa0vhBGBWnAC66+txIjIWUeAO1J/weZpxfOe0k++qj4FLF Y4Vc/YHongNN99E15v2FuD1R1FIQe+T6Hw2JyUIbdb/k4iqULYquhWmcgzwNa+wLf/8rAJOrt hPAd+uAySAIJ/O2i9iG8dkMHoKARFjP20RxkPHvXC5Myz7mjJn5zQ/pFH8KTQbAJm5b6TdOVJ uUrASJLNxT+UEl8SV4OPMPY5ohHWgFkKH/eiUTeelpUOFJbnAudfYe5mazl3xV+zwCDBdxCYg z24uWO/HjqNvxlak7DEbTkqMGb1SddlgBLkFNBn/XnVcZ+KrnulS2TzWEZTAtUbwmfbiBpI/v pKBIZdSvaPK42Lwa8BWGl92uJAUfCeqios+EidpExdk5sYRkP5zk7I+Ymy+QjbH46LWTjDSq2 Mfo+T3ldOq0fkMvFwKqxLN3m4LydJclbM9VL5VK4BvgePjZ2VsmEZb7q9jABFJVkxAZbbcoeH Qc8HhilEedCS5g0FJzupglyuhoZ6+ejXfzQlQ5dj1VJzeDCX8TCvC3iOCek2VcS+QH6nMzXzF kmbzD3NbT9kuiC5eZLloP6axx0+u84iQ7UxRwAi75vBOkEjIFk= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, May 15, 2020 at 4:25 PM Andy Shevchenko wrote: > > On Fri, May 15, 2020 at 4:48 PM kbuild test robot wrote: > > > sparse warnings: (new ones prefixed by >>) > > > > >> drivers/mtd/nand/raw/intel-nand-controller.c:441:24: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected unsigned int val @@ got restricted __be32 [assignedunsigned int val @@ > > >> drivers/mtd/nand/raw/intel-nand-controller.c:441:24: sparse: expected unsigned int val > > >> drivers/mtd/nand/raw/intel-nand-controller.c:441:24: sparse: got restricted __be32 [assigned] [usertype] reg > > drivers/mtd/nand/raw/intel-nand-controller.c:444:24: sparse: sparse: incorrect type in argument 1 (different base types) @@ expected unsigned int val @@ got restricted __be32 [assignedunsigned int val @@ > > drivers/mtd/nand/raw/intel-nand-controller.c:444:24: sparse: expected unsigned int val > > drivers/mtd/nand/raw/intel-nand-controller.c:444:24: sparse: got restricted __be32 [assigned] [usertype] reg > > > > 440 reg = cpu_to_be32(*pdata++); > > > 441 writel(reg, ebu_host->hsnand + HSNAND_CMSG_0); > > 442 > > 443 reg = cpu_to_be32(*pdata); > > 444 writel(reg, ebu_host->hsnand + HSNAND_CMSG_1); > > On BE: > cpu_to_be32 -> no-op > writel() -> converts reg to LE > > On LE: > cpu_to_be32 -> converts to BE > writel() -> no-op (in terms of conversion) > > Seems to me that the proper API (if above is intended) should be swab32(). > But something tells me that above is broken (or my understanding is wrong). iowrite_be32() is the correct way to store word into a big-endian mmio register, if that is the intention here. Arnd